File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change 1515
1616 strategy :
1717 matrix :
18- arch : [x86, x64 ] # 32-bit and 64-bit
18+ arch : [x86, x86_64 ] # 32-bit and 64-bit
1919
2020 steps :
2121 - uses : actions/checkout@v3
@@ -72,12 +72,12 @@ jobs:
7272 run : |
7373 export VCPKG_ROOT="${{ runner.temp }}/vcpkg"
7474 export PATH="$VCPKG_ROOT:$PATH"
75- ARCH_FLAG=""
76- if [ "${{ matrix.arch }}" = "x86" ]; then
77- ARCH_FLAG="-m32"
75+ ARCH="${{ matrix.arch }}"
76+ if [ "$ARCH" = "x86" ]; then
77+ export CFLAGS="-m32"
78+ export CXXFLAGS="-m32"
7879 fi
79- export CFLAGS="$ARCH_FLAG"
80- export CXXFLAGS="$ARCH_FLAG"
80+ export ARCH
8181 bash ci/dependencies/driver-manager-setup-linux.sh
8282
8383 - name : Build cpp-bigquery-odbc (Skip Tests)
9191 echo "📝 Header FULL_VERSION: $HEADER_VERSION"
9292
9393 if [ "$VERSION" != "$HEADER_VERSION" ]; then
94- echo "❌ Mismatch: tag=$VERSION vs FULL_VERSION=$HEADER_VERSION"
95- exit 1
94+ echo "❌ Mismatch: tag=$VERSION vs FULL_VERSION=$HEADER_VERSION"
95+ exit 1
9696 else
9797 echo "✅ FULL_VERSION matches tag version"
9898 fi
Original file line number Diff line number Diff line change @@ -19,6 +19,17 @@ echo "📦 Version from Git tag: $VERSION"
1919ARCH=" ${ARCH:- x86_64} "
2020echo " 🏗️ Building for architecture: $ARCH "
2121
22+ # Map ARCH to vcpkg triplet
23+ if [[ " $ARCH " == " x86" ]]; then
24+ export VCPKG_TARGET_TRIPLET=" x86-linux"
25+ elif [[ " $ARCH " == " x86_64" ]]; then
26+ export VCPKG_TARGET_TRIPLET=" x64-linux"
27+ else
28+ echo " ❌ Unsupported ARCH=$ARCH "
29+ exit 1
30+ fi
31+ echo " 🎯 Using vcpkg triplet: $VCPKG_TARGET_TRIPLET "
32+
2233# Init helpers
2334source " $( dirname " $0 " ) /../lib/init.sh"
2435source ci/dependencies/iODBC.sh
@@ -28,6 +39,8 @@ source module ci/lib/io.sh
2839# --- CMake configuration ---
2940mapfile -t cmake_args < <( cmake::common_args)
3041mapfile -t vcpkg_args < <( cmake::vcpkg_args)
42+ vcpkg_args+=(-DVCPKG_TARGET_TRIPLET=${VCPKG_TARGET_TRIPLET} )
43+
3144cmake_args+=(
3245 -DCMAKE_POSITION_INDEPENDENT_CODE=ON
3346 -DBUILD_SHARED_LIBS=ON
You can’t perform that action at this time.
0 commit comments