From dd0facd722b8d84f2f2df606837cdbce98415158 Mon Sep 17 00:00:00 2001 From: Kim Kulling Date: Sun, 24 Jan 2021 18:14:00 +0100 Subject: [PATCH 1/3] Delete appveyor.yml --- appveyor.yml | 81 ---------------------------------------------------- 1 file changed, 81 deletions(-) delete mode 100644 appveyor.yml diff --git a/appveyor.yml b/appveyor.yml deleted file mode 100644 index 4fb79dd69..000000000 --- a/appveyor.yml +++ /dev/null @@ -1,81 +0,0 @@ -# AppVeyor file -# http://www.appveyor.com/docs/appveyor-yml - -# clone directory -clone_folder: c:\projects\assimp - -clone_depth: 1 - -# branches to build -branches: - # whitelist - only: - - master - -matrix: - fast_finish: true - -image: - - Visual Studio 2013 - #- Visual Studio 2015 - #- Visual Studio 2017 - - Visual Studio 2019 - #- MinGW - -platform: - - Win32 - - x64 - -configuration: Release - -install: - - set PATH=C:\Ruby24-x64\bin;%PATH% - - set CMAKE_DEFINES -DASSIMP_WERROR=ON - - if [%COMPILER%]==[MinGW] set PATH=C:\MinGW\bin;%PATH% - - if "%APPVEYOR_BUILD_WORKER_IMAGE%"=="Visual Studio 2013" set CMAKE_GENERATOR_NAME=Visual Studio 12 2013 - - if "%APPVEYOR_BUILD_WORKER_IMAGE%"=="Visual Studio 2015" set CMAKE_GENERATOR_NAME=Visual Studio 14 2015 - - if "%APPVEYOR_BUILD_WORKER_IMAGE%"=="Visual Studio 2017" set CMAKE_GENERATOR_NAME=Visual Studio 15 2017 - - if "%APPVEYOR_BUILD_WORKER_IMAGE%"=="Visual Studio 2019" set CMAKE_GENERATOR_NAME=Visual Studio 16 2019 - - cmake %CMAKE_DEFINES% -G "%CMAKE_GENERATOR_NAME%" -A %platform% . - # Rename sh.exe as sh.exe in PATH interferes with MinGW - if "%APPVEYOR_BUILD_WORKER_IMAGE%"=="Visual Studio 2015" set CMAKE_GENERATOR_NAME=Visual Studio 14 2015 - - - rename "C:\Program Files\Git\usr\bin\sh.exe" "sh2.exe" - - set PATH=%PATH%;"C:\\Program Files (x86)\\Inno Setup 5" - - ps: Invoke-WebRequest -Uri https://download.microsoft.com/download/5/7/b/57b2947c-7221-4f33-b35e-2fc78cb10df4/vc_redist.x64.exe -OutFile .\packaging\windows-innosetup\vc_redist.x64.exe - - ps: Invoke-WebRequest -Uri https://download.microsoft.com/download/1/d/8/1d8137db-b5bb-4925-8c5d-927424a2e4de/vc_redist.x86.exe -OutFile .\packaging\windows-innosetup\vc_redist.x86.exe - -cache: - - code\assimp.dir\%CONFIGURATION% - - contrib\zlib\zlibstatic.dir\%CONFIGURATION% - - contrib\zlib\zlib.dir\%CONFIGURATION% - - tools\assimp_cmd\assimp_cmd.dir\%CONFIGURATION% - - tools\assimp_view\assimp_viewer.dir\%CONFIGURATION% - - test\unit.dir\%CONFIGURATION% - - bin\.mtime_cache - -before_build: - - echo NUMBER_OF_PROCESSORS=%NUMBER_OF_PROCESSORS% - - ruby scripts\AppVeyor\mtime_cache -g scripts\AppVeyor\cacheglobs.txt -c bin\.mtime_cache\cache.json - -build_script: - cmake --build . --config Release -- /maxcpucount:2 - -after_build: - - if "%APPVEYOR_BUILD_WORKER_IMAGE%"=="Visual Studio 2017" ( - if "%platform%"=="x64" ( - iscc packaging\windows-innosetup\script_x64.iss - ) else ( - iscc packaging\windows-innosetup\script_x86.iss - ) - ) - - 7z a assimp.7z bin\%CONFIGURATION%\* lib\%CONFIGURATION%\* - -test_script: - - cmd: bin\%CONFIGURATION%\unit.exe --gtest_output=xml:testout.xml - -on_finish: - - ps: (new-object net.webclient).UploadFile("https://ci.appveyor.com/api/testresults/junit/$($env:APPVEYOR_JOB_ID)", (Resolve-Path .\testout.xml)) - -artifacts: - - path: assimp.7z - name: assimp_lib From 7a706be9206ed4f2b238e99e4dfb8c330e01dfd9 Mon Sep 17 00:00:00 2001 From: Kim Kulling Date: Sun, 24 Jan 2021 18:14:36 +0100 Subject: [PATCH 2/3] Delete cacheglobs.txt --- scripts/AppVeyor/cacheglobs.txt | 4 ---- 1 file changed, 4 deletions(-) delete mode 100644 scripts/AppVeyor/cacheglobs.txt diff --git a/scripts/AppVeyor/cacheglobs.txt b/scripts/AppVeyor/cacheglobs.txt deleted file mode 100644 index 0f5f04a4a..000000000 --- a/scripts/AppVeyor/cacheglobs.txt +++ /dev/null @@ -1,4 +0,0 @@ -code/*.{%{cpp}} -contrib/**/*.{%{cpp}} -include/**/*.{%{cpp}} -test/**/*.{%{cpp}} From e18261953d511468f2edec16aa7f1db068653bac Mon Sep 17 00:00:00 2001 From: Kim Kulling Date: Sun, 24 Jan 2021 18:14:43 +0100 Subject: [PATCH 3/3] Delete mtime_cache --- scripts/AppVeyor/mtime_cache | 177 ----------------------------------- 1 file changed, 177 deletions(-) delete mode 100644 scripts/AppVeyor/mtime_cache diff --git a/scripts/AppVeyor/mtime_cache b/scripts/AppVeyor/mtime_cache deleted file mode 100644 index e296e3658..000000000 --- a/scripts/AppVeyor/mtime_cache +++ /dev/null @@ -1,177 +0,0 @@ -#!/usr/bin/env ruby - -# -# mtime_cache -# Copyright (c) 2016 Borislav Stanimirov -# -# Permission is hereby granted, free of charge, to any person obtaining a copy -# of this software and associated documentation files (the "Software"), to -# deal in the Software without restriction, including without limitation the -# rights to use, copy, modify, merge, publish, distribute, sublicense, and/or -# sell copies of the Software, and to permit persons to whom the Software is -# furnished to do so, subject to the following conditions: -# -# The above copyright notice and this permission notice shall be included in -# all copies or substantial portions of the Software. -# -# THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR -# IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, -# FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE -# AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER -# LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING -# FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS -# IN THE SOFTWARE. -# - -require 'digest/md5' -require 'json' -require 'fileutils' - -VERSION = "1.0.2" - -VERSION_TEXT = "mtime_cache v#{VERSION}" - -USAGE = <] [-g globfile] [-d] [-q|V] [-c cache] -ENDUSAGE - -HELP = < '.mtime_cache.json', :globs => [] } - -ARGV.each do |arg| - case arg - when '-g', '--globfile' then param_arg = :globfile - when '-h', '-?', '--help' then ARGS[:help] = true - when '-v', '--version' then ARGS[:ver] = true - when '-q', '--quiet' then ARGS[:quiet] = true - when '-V', '--verbose' then ARGS[:verbose] = true - when '-d', '--dryrun' then ARGS[:dry] = true - when '-c', '--cache' then param_arg = :cache - else - if param_arg - ARGS[param_arg] = arg - param_arg = nil - else - ARGS[:globs] << arg - end - end -end - -def log(text, level = 0) - return if ARGS[:quiet] - return if level > 0 && !ARGS[:verbose] - puts text -end - -if ARGS[:ver] || ARGS[:help] - log VERSION_TEXT - exit if ARGS[:ver] - log USAGE - log HELP - exit -end - -if ARGS[:globs].empty? && !ARGS[:globfile] - log 'Error: Missing globs' - log USAGE - exit 1 -end - -EXTENSION_PATTERNS = { - :cpp => "c,cc,cpp,cxx,h,hpp,hxx,inl,ipp,inc,ixx" -} - -cache_file = ARGS[:cache] - -cache = {} - -if File.file?(cache_file) - log "Found #{cache_file}" - cache = JSON.parse(File.read(cache_file)) - log "Read #{cache.length} entries" -else - log "#{cache_file} not found. A new one will be created" -end - -globs = ARGS[:globs].map { |g| g % EXTENSION_PATTERNS } - -globfile = ARGS[:globfile] -if globfile - File.open(globfile, 'r').each_line do |line| - line.strip! - next if line.empty? - globs << line % EXTENSION_PATTERNS - end -end - -if globs.empty? - log 'Error: No globs in globfile' - log USAGE - exit 1 -end - -files = {} -num_changed = 0 - -globs.each do |glob| - Dir[glob].each do |file| - next if !File.file?(file) - - mtime = File.mtime(file).to_i - hash = Digest::MD5.hexdigest(File.read(file)) - - cached = cache[file] - - if cached && cached['hash'] == hash && cached['mtime'] < mtime - mtime = cached['mtime'] - - log "mtime_cache: changing mtime of #{file} to #{mtime}", 1 - - File.utime(File.atime(file), Time.at(mtime), file) if !ARGS[:dry] - num_changed += 1 - else - log "mtime_cache: NOT changing mtime of #{file}", 1 - end - - files[file] = { 'mtime' => mtime, 'hash' => hash } - end -end - -log "Changed mtime of #{num_changed} of #{files.length} files" -log "Writing #{cache_file}" - -if !ARGS[:dry] - dirname = File.dirname(cache_file) - unless File.directory?(dirname) - FileUtils.mkdir_p(dirname) - end - File.open(cache_file, 'w').write(JSON.pretty_generate(files)) -end