Skip to content

Commit 5878046

Browse files
authored
Merge pull request #7 from thomaskf/master
Update the workflow to fix the errors and make the packages.
2 parents 750008e + 2eaabf7 commit 5878046

File tree

3 files changed

+38
-9
lines changed

3 files changed

+38
-9
lines changed

.github/workflows/ci.yaml

Lines changed: 19 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -49,17 +49,19 @@ jobs:
4949
run: |
5050
mkdir build
5151
cd build
52-
cmake .. -DIQTREE_FLAGS=static -DCMAKE_C_COMPILER=$(which gcc-${{ matrix.gcc-version }}) -DCMAKE_CXX_COMPILER=$(which g++-${{ matrix.gcc-version }})
52+
cmake .. -DCMAKE_POLICY_VERSION_MINIMUM=3.5 -DIQTREE_FLAGS=static -DCMAKE_C_COMPILER=$(which gcc-${{ matrix.gcc-version }}) -DCMAKE_CXX_COMPILER=$(which g++-${{ matrix.gcc-version }})
5353
make -j
54+
make package
5455
file iqtree3 | grep x86-64
56+
file iqtree*.tar.gz | grep gzip
5557
5658
- name: Upload Built Binary
5759
# Only upload for one of the gcc & cmake tests
5860
if: ${{ matrix.upload }}
5961
uses: actions/upload-artifact@v4
6062
with:
6163
name: Linux x86-64
62-
path: build/iqtree3
64+
path: build/iqtree*.tar.gz
6365
if-no-files-found: error
6466

6567
build-linux-aarch64:
@@ -83,13 +85,15 @@ jobs:
8385
cd build
8486
cmake .. -DIQTREE_FLAGS=static
8587
make -j
88+
make package
8689
file iqtree3 | grep aarch64
90+
file iqtree*.tar.gz | grep gzip
8791
8892
- name: Upload Built Binary
8993
uses: actions/upload-artifact@v4
9094
with:
9195
name: Linux AArch64
92-
path: build/iqtree3
96+
path: build/iqtree*.tar.gz
9397
if-no-files-found: error
9498

9599
build-macos-x86_64:
@@ -113,14 +117,16 @@ jobs:
113117
export CPPFLAGS="-I/usr/local/opt/libomp/include"
114118
export CXXFLAGS="-I/usr/local/opt/libomp/include"
115119
cmake .. -DCMAKE_C_COMPILER=clang -DCMAKE_CXX_COMPILER=clang++
116-
gmake -j
120+
make -j
121+
make package
117122
file iqtree3 | grep x86_64
123+
file iqtree*.zip | grep Zip
118124
119125
- name: Upload Built Binary
120126
uses: actions/upload-artifact@v4
121127
with:
122128
name: Mac x86-64
123-
path: build/iqtree3
129+
path: build/iqtree*.zip
124130
if-no-files-found: error
125131

126132
build-macos-arm:
@@ -144,14 +150,16 @@ jobs:
144150
export CPPFLAGS="-I/opt/homebrew/opt/libomp/include"
145151
export CXXFLAGS="-I/opt/homebrew/opt/libomp/include"
146152
cmake .. -DCMAKE_C_COMPILER=clang -DCMAKE_CXX_COMPILER=clang++
147-
gmake -j
153+
make -j
154+
make package
148155
file iqtree3 | grep arm64
156+
file iqtree*.zip | grep Zip
149157
150158
- name: Upload Built Binary
151159
uses: actions/upload-artifact@v4
152160
with:
153161
name: Mac Arm
154-
path: build/iqtree3
162+
path: build/iqtree*.zip
155163
if-no-files-found: error
156164

157165
compile-mac-universal:
@@ -219,8 +227,10 @@ jobs:
219227
-DCMAKE_MAKE_PROGRAM=mingw32-make ^
220228
-DBoost_INCLUDE_DIR=${{steps.install-boost.outputs.BOOST_ROOT}}/include ^
221229
-DBoost_LIBRARY_DIRS=${{steps.install-boost.outputs.BOOST_ROOT}}/lib ^
230+
-DCMAKE_POLICY_VERSION_MINIMUM=3.5 ^
222231
-DIQTREE_FLAGS="cpp14" ..
223232
make -j
233+
make package
224234
env:
225235
BOOST_ROOT: ${{ steps.install-boost.outputs.BOOST_ROOT }}
226236

@@ -229,10 +239,11 @@ jobs:
229239
run: |
230240
cd build
231241
file iqtree3.exe | grep x86-64
242+
file iqtree*.zip
232243
233244
- name: Upload Built Binary
234245
uses: actions/upload-artifact@v4
235246
with:
236247
name: Windows x86-64
237-
path: build/iqtree3.exe
248+
path: build/iqtree*.zip
238249
if-no-files-found: error

CMakeLists.txt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -73,7 +73,7 @@
7373
#
7474
#
7575

76-
cmake_minimum_required(VERSION 3.5 FATAL_ERROR) # Lowest version tested in CI (on linux x86_64)
76+
cmake_minimum_required(VERSION 3.5) # Lowest version tested in CI (on linux x86_64)
7777
set(CMAKE_LEGACY_CYGWIN_WIN32 0)
7878

7979
set(GCC_MIN_VERSION "9") # minimum GCC version that is tested in CI

test_scripts/make_universal.sh

Lines changed: 18 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,18 @@
1+
#!/bin/bash
2+
if [ $# -eq 0 ];
3+
then
4+
echo "Syntax: $0 [intel.zip] [arm.zip]"
5+
exit
6+
fi
7+
8+
intelname=`basename $1 .zip`
9+
armname=`basename $2 .zip`
10+
universalname=`basename $1 -intel.zip`
11+
12+
unzip $1
13+
unzip $2
14+
mkdir $universalname
15+
mkdir $universalname/bin
16+
cp $intelname/*.* $universalname
17+
lipo -create -output $universalname/bin/iqtree3 $intelname/bin/iqtree3 $armname/bin/iqtree3
18+
zip -vr $universalname.zip $universalname -x "*.DS_Store"

0 commit comments

Comments
 (0)