File tree Expand file tree Collapse file tree 3 files changed +25
-6
lines changed
Expand file tree Collapse file tree 3 files changed +25
-6
lines changed Original file line number Diff line number Diff line change @@ -55,10 +55,10 @@ jobs:
5555 run : |
5656 export PULSAR_DIR=$PWD/pkg/mac/.install
5757 echo "Build with static library"
58- clang++ win-examples/example.cc -o static.out -std=c++11 -I $PULSAR_DIR/include $PULSAR_DIR/lib/libpulsarwithdeps.a -framework SystemConfiguration -framework CoreFoundation
58+ clang++ win-examples/example.cc -o static.out -std=c++11 -arch ${{ matrix.arch }} - I $PULSAR_DIR/include $PULSAR_DIR/lib/libpulsarwithdeps.a -framework SystemConfiguration -framework CoreFoundation
5959 ./static.out
6060 echo "Build with dynamic library"
61- clang++ win-examples/example.cc -o dynamic.out -std=c++11 -I $PULSAR_DIR/include -L $PULSAR_DIR/lib -Wl,-rpath $PULSAR_DIR/lib -lpulsar
61+ clang++ win-examples/example.cc -o dynamic.out -std=c++11 -arch ${{ matrix.arch }} - I $PULSAR_DIR/include -L $PULSAR_DIR/lib -Wl,-rpath $PULSAR_DIR/lib -lpulsar
6262 ./dynamic.out
6363
6464 - name : Zip artifact
Original file line number Diff line number Diff line change @@ -27,6 +27,12 @@ if [[ $# -lt 1 ]]; then
2727fi
2828
2929CMAKE_BUILD_DIRECTORY=$1
30- ./merge_archives.sh $CMAKE_BUILD_DIRECTORY /libpulsarwithdeps.a \
31- $CMAKE_BUILD_DIRECTORY /lib/libpulsar.a \
32- $( find " $CMAKE_BUILD_DIRECTORY /vcpkg_installed" -name " *.a" | grep -v debug)
30+ if [[ $VCPKG_TRIPLET ]]; then
31+ ./merge_archives.sh $CMAKE_BUILD_DIRECTORY /libpulsarwithdeps.a \
32+ $CMAKE_BUILD_DIRECTORY /lib/libpulsar.a \
33+ $( find " $CMAKE_BUILD_DIRECTORY /vcpkg_installed/$VCPKG_TRIPLET " -name " *.a" | grep -v debug)
34+ else
35+ ./merge_archives.sh $CMAKE_BUILD_DIRECTORY /libpulsarwithdeps.a \
36+ $CMAKE_BUILD_DIRECTORY /lib/libpulsar.a \
37+ $( find " $CMAKE_BUILD_DIRECTORY /vcpkg_installed" -name " *.a" | grep -v debug)
38+ fi
Original file line number Diff line number Diff line change 1818# under the License.
1919#
2020
21- set -ex
21+ set -e
2222cd ` dirname $0 ` /../..
2323
24+ if [[ $ARCH == " x86_64" ]]; then
25+ export VCPKG_TRIPLET=x64-osx
26+ elif [[ $ARCH == " arm64" ]]; then
27+ export VCPKG_TRIPLET=arm64-osx
28+ else
29+ echo " Invalid ARCH: $ARCH "
30+ exit 1
31+ fi
32+ CMAKE_OSX_ARCHITECTURES=$ARCH
33+
2434INSTALL_DIR=$PWD /pkg/mac/.install
35+ set -x
2536cmake -B build-osx -DCMAKE_OSX_DEPLOYMENT_TARGET=10.15 \
2637 -DINTEGRATE_VCPKG=ON \
38+ -DVCPKG_TARGET_TRIPLET=$VCPKG_TRIPLET \
39+ -DCMAKE_OSX_ARCHITECTURES=$CMAKE_OSX_ARCHITECTURES \
2740 -DCMAKE_BUILD_TYPE=Release \
2841 -DBUILD_TESTS=OFF \
2942 -DBUILD_PERF_TOOLS=OFF \
You can’t perform that action at this time.
0 commit comments