lidavidm commented on code in PR #2858:
URL: https://github.com/apache/arrow-adbc/pull/2858#discussion_r2409138744


##########
.github/workflows/native-windows.yml:
##########
@@ -319,3 +319,50 @@ jobs:
           BUILD_ALL: "0"
           BUILD_DRIVER_SQLITE: "1"
         run: .\ci\scripts\python_test.ps1 $pwd $pwd\build
+
+  # ------------------------------------------------------------
+  # MSVC/vcpkg build (no Conda)
+  # ------------------------------------------------------------
+  drivers-vcpkg:
+    name: "C/C++ (vcpkg/${{ matrix.os }})"
+    runs-on: ${{ matrix.os }}
+    strategy:
+      matrix:
+        os: ["windows-latest"]
+    steps:
+      - uses: actions/checkout@v4
+        with:
+          fetch-depth: 0
+          persist-credentials: false
+
+      - name: Setup vcpkg
+        run: |
+          git clone --shallow-since=2021-04-01 
https://github.com/microsoft/vcpkg
+
+          Push-Location vcpkg
+          git checkout 943c5ef1c8f6b5e6ced092b242c8299caae2ff01
+          ./bootstrap-vcpkg.bat -disableMetrics
+
+          Pop-Location
+
+          ./vcpkg/vcpkg install libpq sqlite3
+
+      - name: Add msbuild to PATH
+        uses: microsoft/setup-msbuild@v2
+
+      - name: Build and Install (No ASan)
+        run: |
+          $env:VCPKG_ROOT = $(Join-Path $pwd "vcpkg")
+          New-Item -ItemType Directory -Force -Path build | Out-Null
+          Push-Location build
+
+          # XXX(apache/arrow-adbc#616): must use Release build to line up with 
gtest
+          # Use the desired Visual Studio version as the generator, so that 
cmake generates the required vcxproj files in order to use msbuild for building 
and installing.
+          cmake ../c -G "Visual Studio 17 2022" --preset multi-config-windows 
-DCMAKE_INSTALL_PREFIX="../local" -DCMAKE_VERBOSE_MAKEFILE=ON
+          if (-not $?) { exit 1 }
+
+          msbuild ALL_BUILD.vcxproj /p:Configuration=Release /p:Platform=x64 /m

Review Comment:
   We could use `cmake --build . --target install` as well right?
   
   Should we run the tests here?



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]

Reply via email to