/
.appveyor.yml
80 lines (63 loc) · 3.29 KB
/
.appveyor.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
platform:
- x64
cache:
- C:\msys64\var\cache\pacman\pkg\mingw-w64-x86_64-qt4* -> .appveyor.yml
install:
# Take a look at the environment
- set
- set "PATH=C:\msys64\usr\bin;C:\msys64\mingw64\bin;%PATH%"
- C:\msys64\usr\bin\bash -lc ""
- C:\msys64\usr\bin\bash -lc "pacman --version"
- C:\msys64\usr\bin\bash -lc "pacman -Q"
# Switch from SF to msys2.org (default, much faster)
- C:\msys64\usr\bin\bash -lc "pacman --noconfirm --sync pacman-mirrors"
- C:\msys64\usr\bin\bash -lc "pacman --noconfirm -S autoconf automake bison flex"
- C:\msys64\usr\bin\bash -lc "pacman --noconfirm -S mingw-w64-x86_64-qt4"
# Set compiler (64bit)
- set "CC=/c/msys64/mingw64/bin/gcc.exe"
- set "CXX=/c/msys64/mingw64/bin/g++.exe"
build_script:
## Notes
# * The "exec 0</dev/null" opens a dummy file descriptor to fix error: ./configure: line 560: 0: Bad file descriptor
## Other dependencies
# Download, build and install ADMS
- bash -lc "exec 0</dev/null && wget.exe http://sourceforge.net/projects/mot-adms/files/adms-source/2.3/adms-2.3.4.tar.gz"
- bash -lc "exec 0</dev/null && tar xvfz adms-2.3.4.tar.gz"
- bash -lc "exec 0</dev/null && cd adms-2.3.4/ && ./configure --build=x86_64-w64-mingw32 && make install && cd -"
- bash -lc "exec 0</dev/null && admsXml -h"
## Build Qucs-GUI applications
- bash -lc "exec 0</dev/null && cd $APPVEYOR_BUILD_FOLDER/qucs && ./bootstrap"
- bash -lc "exec 0</dev/null && cd $APPVEYOR_BUILD_FOLDER/qucs && export QTDIR=/c/msys64/mingw64/ && ./configure"
- bash -lc "exec 0</dev/null && cd $APPVEYOR_BUILD_FOLDER/qucs && make install"
- bash -lc "exec 0</dev/null && qucs -v"
## Build Qucs-core
- bash -lc "exec 0</dev/null && cd $APPVEYOR_BUILD_FOLDER/qucs-core && ./bootstrap"
- bash -lc "exec 0</dev/null && cd $APPVEYOR_BUILD_FOLDER/qucs-core && ./configure --disable-dependency-tracking --with-mkadms=`which admsXml`"
- bash -lc "exec 0</dev/null && cd $APPVEYOR_BUILD_FOLDER/qucs-core && make install"
- bash -lc "exec 0</dev/null && qucsator -v"
## Prepare simple redistributable package (no qucs-doc)
# Install to a destination
- bash -lc "exec 0</dev/null && cd $APPVEYOR_BUILD_FOLDER/qucs && make install DESTDIR=/c/qucs-win64"
- bash -lc "exec 0</dev/null && cd $APPVEYOR_BUILD_FOLDER/qucs-core && make install DESTDIR=/c/qucs-win64"
# Copy required libraries, make binaries usable from command line, Windows Explorer
- set QTDIR=c:\msys64\mingw64\
- set QUCSDIR=c:\qucs-win64\usr\local\
- cp %QTDIR%\bin\Qt3Support4.dll %QUCSDIR%\bin
- cp %QTDIR%\bin\QtCore4.dll %QUCSDIR%\bin
- cp %QTDIR%\bin\QtGui4.dll %QUCSDIR%\bin
- cp %QTDIR%\bin\QtNetwork4.dll %QUCSDIR%\bin
- cp %QTDIR%\bin\QtXml4.dll %QUCSDIR%\bin
- cp %QTDIR%\bin\QtSql4.dll %QUCSDIR%\bin
- cp %QTDIR%\bin\QtSvg4.dll %QUCSDIR%\bin
- cp %QTDIR%\bin\QtScript4.dll %QUCSDIR%\bin
- cp %QTDIR%\bin\libstdc++-6.dll %QUCSDIR%\bin
- cp %QTDIR%\bin\libwinpthread-1.dll %QUCSDIR%\bin
- cp %QTDIR%\bin\libpng16-16.dll %QUCSDIR%\bin
# Run from windows cmd
- cd %QUCSDIR%\bin
- qucs.exe -v
- qucsator.exe -v
# TODO
# * one could zip the %QUCSDIR% and use it for testing
# * perhaps it is best we finish the top level 'make dist',
# doing so it is easier to create tarballs, build the binaries from it and distribute both.