Skip to content

Commit 783469e

Browse files
committed
test with linux tar
1 parent d42edc7 commit 783469e

2 files changed

Lines changed: 21 additions & 8 deletions

File tree

.github/workflows/linux-release.yml

Lines changed: 8 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,7 @@ jobs:
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)
@@ -91,8 +91,8 @@ jobs:
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

ci/dependencies/driver-manager-setup-linux.sh

Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -19,6 +19,17 @@ echo "📦 Version from Git tag: $VERSION"
1919
ARCH="${ARCH:-x86_64}"
2020
echo "🏗️ 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
2334
source "$(dirname "$0")/../lib/init.sh"
2435
source ci/dependencies/iODBC.sh
@@ -28,6 +39,8 @@ source module ci/lib/io.sh
2839
# --- CMake configuration ---
2940
mapfile -t cmake_args < <(cmake::common_args)
3041
mapfile -t vcpkg_args < <(cmake::vcpkg_args)
42+
vcpkg_args+=(-DVCPKG_TARGET_TRIPLET=${VCPKG_TARGET_TRIPLET})
43+
3144
cmake_args+=(
3245
-DCMAKE_POSITION_INDEPENDENT_CODE=ON
3346
-DBUILD_SHARED_LIBS=ON

0 commit comments

Comments
 (0)