]> OCCT Git - occt.git/commitdiff
Testing - Migration PR actions to VCPKG-based (#587)
authorPasukhin Dmitry <dpasukhi@opencascade.com>
Sun, 6 Jul 2025 13:35:22 +0000 (14:35 +0100)
committerGitHub <noreply@github.com>
Sun, 6 Jul 2025 13:35:22 +0000 (14:35 +0100)
Update the default testing to use result of VCPKG.
The 3rd-party are stored in GitHub NuGet storage and reused.
The 3rd-party archive with installed 3rd-party added as an artefact
Updated the actions to work with VCPKG 3rd party

28 files changed:
.github/actions/build-docs/action.yml
.github/actions/build-occt/action.yml
.github/actions/build-sample-qt/action.yml
.github/actions/build-tinspector/action.yml
.github/actions/download-vcpkg-cache/action.yml [new file with mode: 0644]
.github/actions/retest-failures/action.yml
.github/actions/run-gtest/action.yml
.github/actions/run-tests/action.yml
.github/actions/test-summary/action.yml
.github/actions/testgrid/testwindows.tcl
.github/actions/testgrid/testwindowsclang.tcl
.github/actions/upload-vcpkg-cache/action.yml [new file with mode: 0644]
.github/actions/vcpkg-setup/action.yml [new file with mode: 0644]
.github/workflows/build-and-test-multiplatform.yml
CMakeLists.txt
adm/cmake/draco.cmake
adm/cmake/occt_csf.cmake
adm/cmake/tcl.cmake
adm/vcpkg/ports/tcl/0001-Add-tk-build.patch [deleted file]
adm/vcpkg/ports/tcl/0001-Support-Tk.patch [new file with mode: 0644]
adm/vcpkg/ports/tcl/0002-Add-setpath-target.patch [deleted file]
adm/vcpkg/ports/tcl/0003-Update-unix-build.patch [deleted file]
adm/vcpkg/ports/tcl/0004-Update-mingw-build.patch [deleted file]
adm/vcpkg/ports/tcl/force-shell-install.patch [deleted file]
adm/vcpkg/ports/tcl/portfile.cmake
adm/vcpkg/triplets/x64-linux-dynamic-release.cmake [new file with mode: 0644]
adm/vcpkg/vcpkg-configuration.json
adm/vcpkg/vcpkg.json

index 65b7ddb895e05a57be52f68b5e9745f7a0ad93fe..8633d1ceaefe3286fd7f5fb67cce3213e5c2e2bf 100644 (file)
@@ -10,38 +10,31 @@ runs:
         choco install -y doxygen.install
       shell: pwsh
 
-    - name: Download and extract 3rdparty dependencies
-      run: |
-          Invoke-WebRequest -Uri https://github.com/Open-Cascade-SAS/OCCT/releases/download/V7_9_0_beta1/3rdparty-vc14-64.zip -OutFile 3rdparty-vc14-64.zip
-          Expand-Archive -Path 3rdparty-vc14-64.zip -DestinationPath .
-          Remove-Item 3rdparty-vc14-64.zip
-      shell: pwsh
-
     - name: Configure OCCT
       run: |
           mkdir build
           cd build
           cmake -T host=x64 `
-                -D USE_FREETYPE=ON `
-                -D USE_TK=OFF `
                 -D BUILD_USE_PCH=ON `
                 -D BUILD_OPT_PROFILE=Production `
                 -D BUILD_INCLUDE_SYMLINK=ON `
                 -D CMAKE_BUILD_TYPE=Release `
                 -D BUILD_DOC_Overview=ON `
                 -D BUILD_DOC_RefMan=ON `
-                -D 3RDPARTY_DIR=${{ github.workspace }}/3rdparty-vc14-64 `
-                -D INSTALL_DIR=${{ github.workspace }}/install `
-                -D USE_D3D=ON `
-                -D USE_DRACO=ON `
-                -D USE_FFMPEG=ON `
-                -D USE_FREEIMAGE=ON `
-                -D USE_GLES2=ON `
-                -D USE_OPENVR=ON `
-                -D USE_VTK=ON `
-                -D USE_TBB=ON `
-                -D USE_RAPIDJSON=ON `
-                -D USE_OPENGL=ON `
+                -D BUILD_MODULE_Draw=OFF `
+                -D USE_D3D=OFF `
+                -D USE_DRACO=OFF `
+                -D USE_FFMPEG=OFF `
+                -D USE_FREEIMAGE=OFF `
+                -D USE_GLES2=OFF `
+                -D USE_OPENVR=OFF `
+                -D USE_VTK=OFF `
+                -D USE_TBB=OFF `
+                -D USE_RAPIDJSON=OFF `
+                -D USE_OPENGL=OFF `
+                -D USE_FREETYPE=OFF `
+                -D USE_TK=OFF `
+                -D USE_TCL=OFF `
                 -D CMAKE_CXX_FLAGS="/W4 /WX" `
                 -D CMAKE_C_FLAGS="/W4 /WX" ..
       shell: pwsh
index 8ed81c26c24a7c53c1872da4cb778bc001f38c7d..3437e97b0f843d6d29242765abe26f4c2aef6cc6 100644 (file)
@@ -31,17 +31,17 @@ inputs:
     description: 'CMake build type (Release, Debug, etc)'
     required: false
     default: 'Release'
+  github-token:
+    description: 'GitHub token for vcpkg NuGet package access'
+    required: true
 
 runs:
   using: "composite"
   steps:
-    - name: Download and extract 3rdparty dependencies (Windows)
-      if: ${{ inputs.platform == 'windows' }}
-      run: |
-          Invoke-WebRequest -Uri https://github.com/Open-Cascade-SAS/OCCT/releases/download/V7_9_0_beta1/3rdparty-vc14-64.zip -OutFile 3rdparty-vc14-64.zip
-          Expand-Archive -Path 3rdparty-vc14-64.zip -DestinationPath .
-          Remove-Item 3rdparty-vc14-64.zip
-      shell: pwsh
+    - name: Setup vcpkg
+      uses: ./.github/actions/vcpkg-setup
+      with:
+        github-token: ${{ inputs.github-token }}
 
     - name: Download and extract Mesa3D (Windows)
       if: ${{ inputs.platform == 'windows' }}
@@ -58,80 +58,37 @@ runs:
         .\systemwidedeploy.cmd 5
       shell: cmd
 
-    - name: Install Ninja (Windows Clang)
-      if: ${{ inputs.platform == 'windows' && inputs.compiler == 'clang' }}
-      run: |
-        choco install ninja -y
-        ninja --version
-      shell: pwsh
-
-    - name: Install dependencies (macOS)
-      if: ${{ inputs.platform == 'macos' }}
-      run: |
-        brew update
-        brew install tcl-tk tbb gl2ps xerces-c \
-                     libxmu libxi libxft libxpm \
-                     glew freeimage draco glfw
-      shell: bash
-
     - name: Install dependencies (Linux)
       if: ${{ inputs.platform == 'linux' }}
-      run: sudo apt-get update && sudo apt-get install -y tcl-dev tk-dev cmake ${{ inputs.compiler == 'clang' && 'clang' || 'gcc g++' }} make libbtbb-dev libx11-dev libglu1-mesa-dev tcllib tcl-thread tcl libvtk9-dev libopenvr-dev libdraco-dev libfreeimage-dev libegl1-mesa-dev libgles2-mesa-dev libfreetype-dev
+      run: sudo apt-get update && sudo apt-get install -y cmake ${{ inputs.compiler == 'clang' && 'clang' || 'gcc g++' }} make libglu1-mesa-dev libegl1-mesa-dev libgles2-mesa-dev
       shell: bash
 
-    - name: Install rapidjson (macOS/Linux)
-      if: ${{ inputs.platform == 'macos' || inputs.platform == 'linux' }}
+    - name: Install required packages (macOS)
+      if: ${{ inputs.platform == 'macos' }}
       run: |
-        wget https://github.com/Tencent/rapidjson/archive/858451e5b7d1c56cf8f6d58f88cf958351837e53.zip -O rapidjson.zip
-        unzip rapidjson.zip
+        brew update || true
+        # temporary workaround for missing tcl-tk
+        brew install tcl-tk || true
+        # Force link any conflicting packages
+        brew link --overwrite python@3.12 || true
+        brew link --overwrite python@3.13 || true
       shell: bash
 
-    - name: Configure OCCT (Windows MSVC)
-      if: ${{ inputs.platform == 'windows' && inputs.compiler == 'msvc' }}
-      run: |
-          mkdir build
-          cd build
-          cmake -T host=x64 `
-                -D USE_FREETYPE=ON `
-                -D USE_TK=OFF `
-                -D BUILD_USE_PCH=${{ inputs.build-use-pch }} `
-                -D BUILD_OPT_PROFILE=${{ inputs.build-opt-profile }} `
-                -D BUILD_INCLUDE_SYMLINK=ON `
-                -D CMAKE_BUILD_TYPE=${{ inputs.cmake-build-type }} `
-                -D 3RDPARTY_DIR=${{ github.workspace }}/3rdparty-vc14-64 `
-                -D INSTALL_DIR=${{ github.workspace }}/install `
-                -D USE_D3D=ON `
-                -D USE_DRACO=ON `
-                -D USE_FFMPEG=ON `
-                -D USE_FREEIMAGE=ON `
-                -D USE_GLES2=ON `
-                -D USE_OPENVR=ON `
-                -D USE_VTK=${{ inputs.use-vtk }} `
-                -D USE_TBB=ON `
-                -D USE_RAPIDJSON=ON `
-                -D USE_OPENGL=ON `
-                -D BUILD_GTEST=ON `
-                -D BUILD_CPP_STANDARD=C++17 `
-                -D INSTALL_GTEST=ON `
-                ${{ inputs.additional-cmake-flags }} ..
-      shell: pwsh
-
-    - name: Configure OCCT (Windows Clang)
-      if: ${{ inputs.platform == 'windows' && inputs.compiler == 'clang' }}
+    - name: Configure OCCT (Windows)
+      if: ${{ inputs.platform == 'windows' }}
       run: |
           mkdir build
           cd build
-          cmake -G "Ninja" `
-                -D CMAKE_C_COMPILER=clang `
-                -D CMAKE_CXX_COMPILER=clang++ `
+          cmake -T ${{ inputs.compiler == 'msvc' && 'host=x64' || 'ClangCL' }} `
                 -D USE_FREETYPE=ON `
-                -D USE_TK=OFF `
+                -D USE_TK=ON `
                 -D BUILD_USE_PCH=${{ inputs.build-use-pch }} `
                 -D BUILD_OPT_PROFILE=${{ inputs.build-opt-profile }} `
                 -D BUILD_INCLUDE_SYMLINK=ON `
                 -D CMAKE_BUILD_TYPE=${{ inputs.cmake-build-type }} `
-                -D 3RDPARTY_DIR=${{ github.workspace }}/3rdparty-vc14-64 `
                 -D INSTALL_DIR=${{ github.workspace }}/install `
+                -D BUILD_USE_VCPKG=ON `
+                -D VCPKG_TARGET_TRIPLET=x64-windows `
                 -D USE_D3D=ON `
                 -D USE_DRACO=ON `
                 -D USE_FFMPEG=ON `
@@ -161,7 +118,8 @@ runs:
               -D BUILD_INCLUDE_SYMLINK=ON \
               -D CMAKE_BUILD_TYPE=${{ inputs.cmake-build-type }} \
               -D INSTALL_DIR=${{ github.workspace }}/install \
-              -D 3RDPARTY_RAPIDJSON_DIR=${{ github.workspace }}/rapidjson-858451e5b7d1c56cf8f6d58f88cf958351837e53 \
+              -D BUILD_USE_VCPKG=ON \
+              -D VCPKG_TARGET_TRIPLET=arm64-osx-dynamic \
               -D USE_RAPIDJSON=ON \
               -D USE_DRACO=ON \
               -D USE_FREETYPE=ON \
@@ -179,16 +137,21 @@ runs:
       run: |
         mkdir -p build
         cd build
+        # Set environment to help vcpkg find system libraries
+        export PKG_CONFIG_PATH="/usr/lib/x86_64-linux-gnu/pkgconfig:/usr/share/pkgconfig:$PKG_CONFIG_PATH"
+        export CMAKE_PREFIX_PATH="/usr:/usr/local:$CMAKE_PREFIX_PATH"
         cmake -G "Unix Makefiles" \
               -D CMAKE_C_COMPILER=${{ inputs.compiler == 'clang' && 'clang' || 'gcc' }} \
               -D CMAKE_CXX_COMPILER=${{ inputs.compiler == 'clang' && 'clang++' || 'g++' }} \
               -D BUILD_USE_PCH=${{ inputs.build-use-pch }} \
               -D BUILD_INCLUDE_SYMLINK=ON \
               -D BUILD_OPT_PROFILE=${{ inputs.build-opt-profile }} \
-              -D USE_TK=OFF \
+              -D USE_TK=ON \
               -D CMAKE_BUILD_TYPE=${{ inputs.cmake-build-type }} \
               -D INSTALL_DIR=${{ github.workspace }}/install \
-              -D 3RDPARTY_RAPIDJSON_DIR=${{ github.workspace }}/rapidjson-858451e5b7d1c56cf8f6d58f88cf958351837e53 \
+              -D BUILD_USE_VCPKG=ON \
+              -D BUILD_LIBRARY_TYPE=Shared \
+              -D VCPKG_TARGET_TRIPLET=x64-linux-dynamic \
               -D USE_FREETYPE=ON \
               -D USE_DRACO=ON \
               -D USE_FFMPEG=ON \
@@ -196,7 +159,7 @@ runs:
               -D USE_GLES2=ON \
               -D USE_OPENVR=ON \
               -D USE_VTK=${{ inputs.use-vtk }} \
-              -D USE_TBB=OFF \
+              -D USE_TBB=ON \
               -D USE_RAPIDJSON=ON \
               -D USE_OPENGL=ON \
               -D BUILD_GTEST=ON \
@@ -205,6 +168,12 @@ runs:
               ${{ inputs.additional-cmake-flags }} ..
       shell: bash
 
+    - name: Upload vcpkg cache
+      uses: ./.github/actions/upload-vcpkg-cache
+      with:
+        artifact-name: ${{ inputs.artifact-name }}-cache
+        build-directory: build
+
     - name: Build OCCT (Windows)
       if: ${{ inputs.platform == 'windows' }}
       run: |
index 4ee2d8933d26a836ee3e07d469fb9f63989fa24d..7e39dc6436510eeb850676d8310c5beea3e359a3 100644 (file)
@@ -22,6 +22,11 @@ runs:
         name: ${{ inputs.install-artifact-name }}
         path: occt-install
 
+    - name: Download vcpkg cache
+      uses: ./.github/actions/download-vcpkg-cache
+      with:
+        artifact-name: ${{ inputs.install-artifact-name }}-cache
+
     - name: Install Windows dependencies
       if: inputs.platform == 'windows'
       shell: pwsh
@@ -84,6 +89,12 @@ runs:
       run: |
         cd ${{ github.workspace }}/occt-install/bin
         source env.sh
+        
+        # Set library paths for vcpkg dependencies
+        export LD_LIBRARY_PATH="${{ github.workspace }}/build/vcpkg_installed/x64-linux-dynamic/lib:${{ github.workspace }}/occt-install/lib:$LD_LIBRARY_PATH"
+        export LIBRARY_PATH="${{ github.workspace }}/build/vcpkg_installed/x64-linux-dynamic/lib:${{ github.workspace }}/occt-install/lib:$LIBRARY_PATH"
+        export PKG_CONFIG_PATH="${{ github.workspace }}/build/vcpkg_installed/x64-linux-dynamic/lib/pkgconfig:$PKG_CONFIG_PATH"
+        
         cd ${{ github.workspace }}/samples/qt
         
         for sample in IESample Tutorial FuncDemo; do
@@ -92,7 +103,13 @@ runs:
           host=`uname -s`
           export STATION=$host
           export RES_DIR="${{ github.workspace }}/samples/qt/${sample}/result"
-          qmake $sample.pro
+          
+          # Configure qmake with vcpkg paths
+          qmake $sample.pro \
+            "LIBS += -L${{ github.workspace }}/build/vcpkg_installed/x64-linux-dynamic/lib" \
+            "LIBS += -Wl,-rpath,${{ github.workspace }}/build/vcpkg_installed/x64-linux-dynamic/lib" \
+            "INCLUDEPATH += ${{ github.workspace }}/build/vcpkg_installed/x64-linux-dynamic/include"
+          
           aNbJobs="$(getconf _NPROCESSORS_ONLN)"
           make -j$aNbJobs release
           cd ..
index ef51b10b665180165167e2e9c929c228ccde1dd5..18e93babe020a90eb6e4a312cd7b6934c98eb723 100644 (file)
@@ -22,6 +22,11 @@ runs:
         name: ${{ inputs.install-artifact-name }}
         path: occt-install
 
+    - name: Download vcpkg cache
+      uses: ./.github/actions/download-vcpkg-cache
+      with:
+        artifact-name: ${{ inputs.install-artifact-name }}-cache
+
     - name: Install Windows dependencies
       if: inputs.platform == 'windows'
       shell: pwsh
@@ -65,12 +70,17 @@ runs:
         cd inspector
         mkdir build
         cd build
+        export LD_LIBRARY_PATH="${{ github.workspace }}/build/vcpkg_installed/x64-linux-dynamic/lib:${{ github.workspace }}/occt-install/lib:$LD_LIBRARY_PATH"
         cmake -G "Unix Makefiles" \
               -D CMAKE_BUILD_TYPE=Release \
               -D BUILD_SHARED_LIBS=ON \
               -D OpenCASCADE_DIR=${{ github.workspace }}/occt-install \
               -D INSTALL_DIR=${{ github.workspace }}/inspector/install \
               -D CMAKE_POLICY_VERSION_MINIMUM=3.5 \
+              -D CMAKE_LIBRARY_PATH="${{ github.workspace }}/build/vcpkg_installed/x64-linux-dynamic/lib" \
+              -D CMAKE_INCLUDE_PATH="${{ github.workspace }}/build/vcpkg_installed/x64-linux-dynamic/include" \
+              -D CMAKE_EXE_LINKER_FLAGS="-L${{ github.workspace }}/build/vcpkg_installed/x64-linux-dynamic/lib -Wl,-rpath,${{ github.workspace }}/build/vcpkg_installed/x64-linux-dynamic/lib" \
+              -D CMAKE_SHARED_LINKER_FLAGS="-L${{ github.workspace }}/build/vcpkg_installed/x64-linux-dynamic/lib -Wl,-rpath,${{ github.workspace }}/build/vcpkg_installed/x64-linux-dynamic/lib" \
               ..
 
     - name: Build TInspector - Windows
@@ -85,6 +95,10 @@ runs:
       shell: bash
       run: |
         cd inspector/build
+        # Set library paths for build and runtime
+        export LD_LIBRARY_PATH="${{ github.workspace }}/build/vcpkg_installed/x64-linux-dynamic/lib:${{ github.workspace }}/occt-install/lib:$LD_LIBRARY_PATH"
+        export LIBRARY_PATH="${{ github.workspace }}/build/vcpkg_installed/x64-linux-dynamic/lib:${{ github.workspace }}/occt-install/lib:$LIBRARY_PATH"
+        export PKG_CONFIG_PATH="${{ github.workspace }}/build/vcpkg_installed/x64-linux-dynamic/lib/pkgconfig:$PKG_CONFIG_PATH"
         make install -j$(nproc)
 
     - name: Upload TInspector installation
diff --git a/.github/actions/download-vcpkg-cache/action.yml b/.github/actions/download-vcpkg-cache/action.yml
new file mode 100644 (file)
index 0000000..35d566c
--- /dev/null
@@ -0,0 +1,79 @@
+name: 'Download vcpkg Cache'
+description: 'Download and restore vcpkg installed packages and cache'
+
+inputs:
+  artifact-name:
+    description: 'Name of the artifact containing vcpkg cache'
+    required: true
+  build-directory:
+    description: 'Build directory where vcpkg_installed should be restored'
+    required: false
+    default: 'build'
+
+runs:
+  using: "composite"
+  steps:
+
+    - name: Download vcpkg tar archive
+      uses: actions/download-artifact@v4.1.8
+      with:
+        name: ${{ inputs.artifact-name }}
+        path: ${{ inputs.build-directory }}
+
+    - name: Extract vcpkg dependencies
+      run: |
+        cd ${{ inputs.build-directory }}
+        tar -xzf vcpkg-dependencies.tar.gz
+        rm vcpkg-dependencies.tar.gz
+      shell: bash
+
+    - name: Copy manual-link libraries and set paths for Windows
+      if: runner.os == 'Windows'
+      run: |
+        $vcpkg_bin = "${{ inputs.build-directory }}/vcpkg_installed/x64-windows/bin"
+        $vcpkg_lib = "${{ inputs.build-directory }}/vcpkg_installed/x64-windows/lib"
+        $vcpkg_manual = "${{ inputs.build-directory }}/vcpkg_installed/x64-windows/lib/manual-link"
+        
+        # Copy manual-link DLLs to bin directory for runtime access
+        if (Test-Path $vcpkg_manual) {
+          Write-Host "Copying manual-link libraries to bin directory"
+          Copy-Item "$vcpkg_manual\*" "$vcpkg_bin\" -Force -ErrorAction SilentlyContinue
+        }
+        
+        # Set library search paths
+        $current_path = $env:PATH
+        echo "PATH=$vcpkg_bin;$vcpkg_lib;$vcpkg_manual;$current_path" >> $env:GITHUB_ENV
+      shell: pwsh
+
+    - name: Copy manual-link libraries and set paths for Linux
+      if: runner.os == 'Linux'
+      run: |
+        vcpkg_lib="${{ inputs.build-directory }}/vcpkg_installed/x64-linux-dynamic/lib"
+        vcpkg_manual="${{ inputs.build-directory }}/vcpkg_installed/x64-linux-dynamic/lib/manual-link"
+        
+        # Copy manual-link libraries to main lib directory for runtime access
+        if [ -d "$vcpkg_manual" ]; then
+          echo "Copying manual-link libraries to main lib directory"
+          cp -f "$vcpkg_manual"/* "$vcpkg_lib/" 2>/dev/null || true
+        fi
+        
+        # Set library search paths
+        echo "LD_LIBRARY_PATH=$vcpkg_lib:$vcpkg_manual:$LD_LIBRARY_PATH" >> $GITHUB_ENV
+      shell: bash
+
+    - name: Copy manual-link libraries and set paths for macOS
+      if: runner.os == 'macOS'
+      run: |
+        vcpkg_lib="${{ inputs.build-directory }}/vcpkg_installed/arm64-osx-dynamic/lib"
+        vcpkg_manual="${{ inputs.build-directory }}/vcpkg_installed/arm64-osx-dynamic/lib/manual-link"
+        
+        # Copy manual-link libraries to main lib directory for runtime access
+        if [ -d "$vcpkg_manual" ]; then
+          echo "Copying manual-link libraries to main lib directory"
+          cp -f "$vcpkg_manual"/* "$vcpkg_lib/" 2>/dev/null || true
+        fi
+        
+        # Set library search paths
+        echo "DYLD_FALLBACK_LIBRARY_PATH=$vcpkg_lib:$vcpkg_manual:$DYLD_FALLBACK_LIBRARY_PATH" >> $GITHUB_ENV
+        echo "DYLD_LIBRARY_PATH=$vcpkg_lib:$vcpkg_manual:$DYLD_LIBRARY_PATH" >> $GITHUB_ENV
+      shell: bash
index 06d0540b1e0677a9d88e7053d6dca1adb13afabc..3327b05ffb9028c274f565f4330ea233a8b695f1 100644 (file)
@@ -84,27 +84,16 @@ runs:
         echo "failed_count={0}" >> $GITHUB_OUTPUT
         ', steps.check_failures_unix.outputs.failed_count) }}
 
-    - name: Download and extract 3rdparty dependencies (Windows)
-      if: ${{ inputs.platform == 'windows' && steps.check_failures.outputs.failed_count > 0 }}
-      shell: pwsh
-      run: |
-          Invoke-WebRequest -Uri https://github.com/Open-Cascade-SAS/OCCT/releases/download/V7_9_0_beta1/3rdparty-vc14-64.zip -OutFile 3rdparty-vc14-64.zip
-          Expand-Archive -Path 3rdparty-vc14-64.zip -DestinationPath .
-          Remove-Item 3rdparty-vc14-64.zip
-
-    - name: Install dependencies (macOS)
-      if: ${{ inputs.platform == 'macos' && steps.check_failures.outputs.failed_count > 0 }}
-      shell: bash
-      run: |
-        brew update
-        brew install tcl-tk tbb gl2ps xerces-c \
-                     libxmu libxi libxft libxpm \
-                     glew freeimage draco glfw
+    - name: Download vcpkg cache
+      if: steps.check_failures.outputs.failed_count > 0
+      uses: ./.github/actions/download-vcpkg-cache
+      with:
+        artifact-name: ${{ inputs.install-artifact-name }}-cache
 
     - name: Install dependencies (Linux)
       if: ${{ inputs.platform == 'linux' && steps.check_failures.outputs.failed_count > 0 }}
       shell: bash
-      run: sudo apt-get update && sudo apt-get install -y tcl-dev tk-dev cmake ${{ inputs.compiler == 'clang' && 'clang' || 'gcc g++' }} make libbtbb-dev libx11-dev libglu1-mesa-dev tcllib tcl-thread tcl libvtk9-dev libopenvr-dev libdraco-dev libfreeimage-dev libegl1-mesa-dev libgles2-mesa-dev libfreetype-dev fonts-noto-cjk fonts-liberation fonts-ubuntu fonts-liberation fonts-ubuntu fonts-noto-cjk fonts-ipafont-gothic fonts-ipafont-mincho fonts-unfonts-core
+      run: sudo apt-get update && sudo apt-get install -y cmake ${{ inputs.compiler == 'clang' && 'clang' || 'gcc g++' }} make libglu1-mesa-dev libegl1-mesa-dev libgles2-mesa-dev fonts-noto-cjk fonts-liberation fonts-ubuntu fonts-liberation fonts-ubuntu fonts-noto-cjk fonts-ipafont-gothic fonts-ipafont-mincho fonts-unfonts-core
 
     - name: Setup Xvfb and Mesa (Linux)
       if: ${{ inputs.platform == 'linux' && steps.check_failures.outputs.failed_count > 0 }}
@@ -167,7 +156,7 @@ runs:
       shell: cmd
       run: |
         cd install
-        call env.bat ${{ inputs.compiler == 'clang' && 'clang' || 'vc14' }} win64 release
+        call env.bat vc14 win64 release
         DRAWEXE.exe -v -c testgrid -regress results/${{ inputs.test-directory-name }} -outdir results/${{ inputs.test-directory-name }}-retest -parallel 0
       env:
         LIBGL_ALWAYS_SOFTWARE: 1
@@ -193,7 +182,7 @@ runs:
       shell: cmd
       run: |
         cd install
-        call env.bat ${{ inputs.compiler == 'clang' && 'clang' || 'vc14' }} win64 release
+        call env.bat vc14 win64 release
         # Repeat failed tests for 10 times
         for /l %%i in (1,1,10) do (
           DRAWEXE.exe -v -c testgrid -regress results/${{ inputs.test-directory-name }}-retest -outdir results/${{ inputs.test-directory-name }}-retest -parallel 0 -overwrite
@@ -239,7 +228,7 @@ runs:
         if exist "*" (
           xcopy /s /y /i . "..\${{ inputs.test-directory-name }}"
           cd ..\..
-          call env.bat ${{ inputs.compiler == 'clang' && 'clang' || 'vc14' }} win64 release
+          call env.bat vc14 win64 release
           DRAWEXE.exe -v -c "testsummarize results/${{ inputs.test-directory-name }}"
         ) else (
           echo No retest results to copy - directory is empty
index 9eae4b536543ec1d564c7fb8283220d6e55ef898..d3fb85d625c72b53a03b60aa97e344f748eb273f 100644 (file)
@@ -30,22 +30,10 @@ runs:
         name: ${{ inputs.install-artifact-name }}
         path: install
 
-    - name: Download and extract 3rdparty dependencies for Windows
-      if: inputs.platform == 'windows'
-      shell: pwsh
-      run: |
-        Invoke-WebRequest -Uri https://github.com/Open-Cascade-SAS/OCCT/releases/download/V7_9_0_beta1/3rdparty-vc14-64.zip -OutFile 3rdparty-vc14-64.zip
-        Expand-Archive -Path 3rdparty-vc14-64.zip -DestinationPath .
-        Remove-Item 3rdparty-vc14-64.zip
-
-    - name: Install macOS dependencies
-      if: inputs.platform == 'macos'
-      shell: bash
-      run: |
-        brew update
-        brew install tcl-tk tbb gl2ps xerces-c \
-                     libxmu libxi libxft libxpm \
-                     glew freeimage draco glfw
+    - name: Download vcpkg cache
+      uses: ./.github/actions/download-vcpkg-cache
+      with:
+        artifact-name: ${{ inputs.install-artifact-name }}-cache
 
     - name: Install Linux dependencies
       if: inputs.platform == 'linux'
@@ -69,7 +57,7 @@ runs:
       shell: cmd
       run: |
         cd install
-        call env.bat ${{ inputs.compiler == 'msvc' && 'vc14' || 'clang' }} win64 release
+        call env.bat vc14 win64 release
         cd bin
         set GTEST_OUTPUT=""
         OpenCascadeGTest.exe --gtest_output=xml:gtest_results.xml > gtest_output.log 2>&1
index 3099b25d903473489a82e3f93424096c4b4d8829..2ee753b25a425eaa1f90f7ee5df119891caa06ba 100644 (file)
@@ -21,26 +21,14 @@ inputs:
 runs:
   using: "composite"
   steps:
-    - name: Download and extract 3rdparty dependencies (Windows)
-      if: ${{ inputs.platform == 'windows' }}
-      run: |
-          Invoke-WebRequest -Uri https://github.com/Open-Cascade-SAS/OCCT/releases/download/V7_9_0_beta1/3rdparty-vc14-64.zip -OutFile 3rdparty-vc14-64.zip
-          Expand-Archive -Path 3rdparty-vc14-64.zip -DestinationPath .
-          Remove-Item 3rdparty-vc14-64.zip
-      shell: pwsh
-
-    - name: Install dependencies (macOS)
-      if: ${{ inputs.platform == 'macos' }}
-      run: |
-        brew update
-        brew install tcl-tk tbb gl2ps xerces-c \
-                     libxmu libxi libxft libxpm \
-                     glew freeimage draco glfw
-      shell: bash
+    - name: Download vcpkg cache
+      uses: ./.github/actions/download-vcpkg-cache
+      with:
+        artifact-name: ${{ inputs.install-artifact-name }}-cache
 
     - name: Install dependencies (Linux)
       if: ${{ inputs.platform == 'linux' }}
-      run: sudo apt-get update && sudo apt-get install -y tcl-dev tk-dev cmake ${{ inputs.compiler == 'gcc' && 'gcc g++' || 'clang' }} make libbtbb-dev libx11-dev libglu1-mesa-dev tcllib tcl-thread tcl libvtk9-dev libopenvr-dev libdraco-dev libfreeimage-dev libegl1-mesa-dev libgles2-mesa-dev libfreetype-dev fonts-noto-cjk fonts-liberation fonts-ubuntu fonts-liberation fonts-ubuntu fonts-noto-cjk fonts-ipafont-gothic fonts-ipafont-mincho fonts-unfonts-core
+      run: sudo apt-get update && sudo apt-get install -y cmake ${{ inputs.compiler == 'gcc' && 'gcc g++' || 'clang' }} make libglu1-mesa-dev libegl1-mesa-dev fonts-noto-cjk fonts-liberation fonts-ubuntu fonts-liberation fonts-ubuntu fonts-noto-cjk fonts-ipafont-gothic fonts-ipafont-mincho fonts-unfonts-core
       shell: bash
 
     - name: Setup Xvfb and Mesa (Linux)
@@ -107,7 +95,7 @@ runs:
       if: ${{ inputs.platform == 'windows' }}
       run: |
         cd install
-        call env.bat ${{ inputs.compiler == 'msvc' && 'vc14' || 'clang' }} win64 release
+        call env.bat vc14 win64 release
         DRAWEXE.exe -v -f ${{ github.workspace }}/${{ inputs.test-script }}
       shell: cmd
       env:
@@ -133,7 +121,7 @@ runs:
       if: ${{ inputs.platform == 'windows' }}
       run: |
         cd install
-        call env.bat ${{ inputs.compiler == 'msvc' && 'vc14' || 'clang' }} win64 release
+        call env.bat vc14 win64 release
         DRAWEXE.exe -v -c cleanuptest results/${{ inputs.test-directory-name }}
       shell: cmd
       env:
index a6fbb8546b28d469202cde304599a24fe987bf83..e9a222486bf76a5955dcb6509b8633d9d7466735 100644 (file)
@@ -4,8 +4,13 @@ description: 'Compare test results between current branch and master'
 runs:
   using: "composite"
   steps:
+    - name: Download vcpkg cache
+      uses: ./.github/actions/download-vcpkg-cache
+      with:
+        artifact-name: install-linux-gcc-x64-cache
+
     - name: Install dependencies
-      run: sudo apt-get update && sudo apt-get install -y tcl-dev tk-dev cmake gcc g++ make libbtbb-dev libx11-dev libglu1-mesa-dev tcllib tcl-thread tcl libvtk9-dev libopenvr-dev libdraco-dev libfreeimage-dev libegl1-mesa-dev libgles2-mesa-dev libfreetype-dev
+      run: sudo apt-get update && sudo apt-get install -y cmake gcc g++ make libglu1-mesa-dev libegl1-mesa-dev libgles2-mesa-dev
       shell: bash
 
     - name: Setup Xvfb and Mesa
index 321ab6dcdf71832d9a2fe7a5c955778b566cd4dc..a70bcaad21238bd6510ac4dcf10a1c0f4f1ce98d 100644 (file)
@@ -17,7 +17,13 @@ set exclude_list [list \
     "chamfer dist_angle_complex A4" \
     "chamfer dist_angle_complex A5" \
     "chamfer dist_angle_sequence A1" \
-    "chamfer dist_angle_sequence A4"
+    "chamfer dist_angle_sequence A4" \
+    "caf basic W12" \
+    "opengles3 general msaa" \
+    "opengles3 geom interior1" \
+    "opengles3 geom interior2" \
+    "opengles3 shadows dir2" \
+    "opengles3 textures alpha_mask"
 ]
 
 set exclude_str [join $exclude_list ,]
index b5e95e83f0dd022114da1aac988b5f6ea0fb3f9b..a8cc022da60f843b4b2bf4fc6dff5ce949a105d6 100644 (file)
@@ -18,7 +18,14 @@ set exclude_list [list \
     "chamfer dist_angle_complex A4" \
     "chamfer dist_angle_complex A5" \
     "chamfer dist_angle_sequence A1" \
-    "chamfer dist_angle_sequence A4"
+    "chamfer dist_angle_sequence A4" \
+    "bugs fclasses bug30775" \
+    "caf basic W12" \
+    "opengles3 general msaa" \
+    "opengles3 geom interior1" \
+    "opengles3 geom interior2" \
+    "opengles3 shadows dir2" \
+    "opengles3 textures alpha_mask"
 ]
 
 set exclude_str [join $exclude_list ,]
diff --git a/.github/actions/upload-vcpkg-cache/action.yml b/.github/actions/upload-vcpkg-cache/action.yml
new file mode 100644 (file)
index 0000000..a8d5e98
--- /dev/null
@@ -0,0 +1,33 @@
+name: 'Upload vcpkg Cache'
+description: 'Upload vcpkg installed packages and cache for reuse'
+
+inputs:
+  artifact-name:
+    description: 'Name of the artifact to store vcpkg cache'
+    required: true
+  build-directory:
+    description: 'Build directory containing vcpkg_installed'
+    required: false
+    default: 'build'
+
+runs:
+  using: "composite"
+  steps:
+
+    - name: Create vcpkg tar archive
+      run: |
+        cd ${{ inputs.build-directory }}
+        tar -czf vcpkg-dependencies.tar.gz \
+          --exclude='vcpkg_installed/*/debug' \
+          --exclude='vcpkg_installed/**/*.pdb' \
+          --exclude='vcpkg_installed/**/*.lib' \
+          ./vcpkg_installed/
+      shell: bash
+
+    - name: Upload vcpkg tar archive
+      uses: actions/upload-artifact@v4.4.3
+      with:
+        name: ${{ inputs.artifact-name }}
+        path: ${{ inputs.build-directory }}/vcpkg-dependencies.tar.gz
+        retention-days: 7
+        compression-level: 1
diff --git a/.github/actions/vcpkg-setup/action.yml b/.github/actions/vcpkg-setup/action.yml
new file mode 100644 (file)
index 0000000..af913f9
--- /dev/null
@@ -0,0 +1,108 @@
+name: 'Setup vcpkg'
+description: 'Setup vcpkg dependencies for OCCT build on a specific platform'
+
+inputs:
+  vcpkg-tag:
+    description: 'vcpkg tag to checkout'
+    required: false
+    default: '2025.06.13'
+  github-token:
+    description: 'GitHub token for NuGet package access'
+    required: true
+
+runs:
+  using: "composite"
+  steps:
+    - name: Set environment variables
+      run: |
+        echo "USERNAME=Open-Cascade-SAS" >> $GITHUB_ENV
+        echo "VCPKG_ROOT=${{ github.workspace }}/vcpkg" >> $GITHUB_ENV
+        echo "VCPKG_EXE=${{ github.workspace }}/vcpkg/vcpkg" >> $GITHUB_ENV
+        echo "FEED_URL=https://nuget.pkg.github.com/Open-Cascade-SAS/index.json" >> $GITHUB_ENV
+        echo "VCPKG_BINARY_SOURCES=clear;nuget,https://nuget.pkg.github.com/Open-Cascade-SAS/index.json,readwrite" >> $GITHUB_ENV
+        echo "VCPKG_FEATURE_FLAGS=binarycaching,manifests,versions" >> $GITHUB_ENV
+        echo "VCPKG_DISABLE_COMPILER_TRACKING=1" >> $GITHUB_ENV
+      shell: bash
+      if: runner.os != 'Windows'
+
+    - name: Set environment variables (Windows)
+      run: |
+        echo "USERNAME=Open-Cascade-SAS" >> $env:GITHUB_ENV
+        echo "VCPKG_ROOT=${{ github.workspace }}/vcpkg" >> $env:GITHUB_ENV
+        echo "VCPKG_EXE=${{ github.workspace }}/vcpkg/vcpkg" >> $env:GITHUB_ENV
+        echo "FEED_URL=https://nuget.pkg.github.com/Open-Cascade-SAS/index.json" >> $env:GITHUB_ENV
+        echo "VCPKG_BINARY_SOURCES=clear;nuget,https://nuget.pkg.github.com/Open-Cascade-SAS/index.json,readwrite" >> $env:GITHUB_ENV
+        echo "VCPKG_FEATURE_FLAGS=binarycaching,manifests,versions" >> $env:GITHUB_ENV
+        echo "VCPKG_DISABLE_COMPILER_TRACKING=1" >> $env:GITHUB_ENV
+      shell: pwsh
+      if: runner.os == 'Windows'
+
+    - name: Install required packages (Linux)
+      if: runner.os == 'Linux'
+      run: |
+        sudo apt-get update
+        sudo apt-get install -y build-essential ninja-build curl zip unzip tar nasm autoconf mono-complete \
+              libx11-dev \
+              libxi-dev \
+              libxext-dev \
+              mesa-common-dev \
+              libglu1-mesa-dev \
+              libegl1-mesa-dev \
+              libgles2-mesa-dev
+      shell: bash
+
+    - name: Install required packages (macOS)
+      if: runner.os == 'macOS'
+      run: |
+        brew update || true
+        brew install cmake ninja nasm autoconf automake mono || true
+        brew install --cask xquartz || true
+      shell: bash
+
+    - name: Set up vcpkg (Unix)
+      if: runner.os != 'Windows'
+      run: |
+        git clone https://github.com/microsoft/vcpkg.git
+        cd vcpkg
+        git checkout ${{ inputs.vcpkg-tag }}
+        ./bootstrap-vcpkg.sh
+      shell: bash
+
+    - name: Set up vcpkg (Windows)
+      if: runner.os == 'Windows'
+      run: |
+        git clone https://github.com/microsoft/vcpkg.git
+        cd vcpkg
+        git checkout ${{ inputs.vcpkg-tag }}
+        .\bootstrap-vcpkg.bat
+      shell: cmd
+
+    - name: Add NuGet sources
+      if: runner.os == 'Windows'
+      run: |
+        .$(${{ env.VCPKG_EXE }} fetch nuget) `
+          sources add `
+          -Source "${{ env.FEED_URL }}" `
+          -StorePasswordInClearText `
+          -Name GitHubPackages `
+          -UserName "${{ env.USERNAME }}" `
+          -Password "${{ inputs.github-token }}"
+        .$(${{ env.VCPKG_EXE }} fetch nuget) `
+          setapikey "${{ inputs.github-token }}" `
+          -Source "${{ env.FEED_URL }}"
+      shell: pwsh
+
+    - name: Add NuGet sources
+      if: runner.os != 'Windows'
+      run: |
+        mono `${{ env.VCPKG_EXE }} fetch nuget | tail -n 1` \
+          sources add \
+          -Source "${{ env.FEED_URL }}" \
+          -StorePasswordInClearText \
+          -Name GitHubPackages \
+          -UserName "${{ env.USERNAME }}" \
+          -Password "${{ inputs.github-token }}"
+        mono `${{ env.VCPKG_EXE }} fetch nuget | tail -n 1` \
+          setapikey "${{ inputs.github-token }}" \
+          -Source "${{ env.FEED_URL }}"
+      shell: bash
index 53fffa7e5a146e8367ee7880f842093ea8894330..9fe11c0e1f64072c136903be22f2c7bad6fb2407 100644 (file)
@@ -60,6 +60,7 @@ jobs:
         platform: windows
         compiler: msvc
         artifact-name: install-windows-x64
+        github-token: ${{ secrets.GITHUB_TOKEN }}
 
   prepare-and-build-windows-clang-x64:
     name: Prepare and Build on Windows with Clang (x64)
@@ -76,6 +77,7 @@ jobs:
         compiler: clang
         artifact-name: install-windows-clang-x64
         use-vtk: 'false'
+        github-token: ${{ secrets.GITHUB_TOKEN }}
 
   prepare-and-build-macos-x64:
     name: Prepare and Build on macOS with Clang (x64)
@@ -91,6 +93,7 @@ jobs:
         platform: macos
         compiler: clang
         artifact-name: install-macos-x64
+        github-token: ${{ secrets.GITHUB_TOKEN }}
 
   prepare-and-build-macos-gcc-x64:
     name: Prepare and Build on macOS with GCC (x64)
@@ -106,6 +109,7 @@ jobs:
         platform: macos
         compiler: gcc
         artifact-name: install-macos-gcc-x64
+        github-token: ${{ secrets.GITHUB_TOKEN }}
 
   prepare-and-build-linux-clang-x64:
     name: Prepare and Build on Ubuntu with Clang (x64)
@@ -121,6 +125,7 @@ jobs:
         platform: linux
         compiler: clang
         artifact-name: install-linux-clang-x64
+        github-token: ${{ secrets.GITHUB_TOKEN }}
 
   prepare-and-build-macos-clang-no-pch:
     name: Prepare and Build on macOS with Clang (No PCH)
@@ -140,6 +145,7 @@ jobs:
         build-opt-profile: 'Default'
         additional-cmake-flags: '-D CMAKE_CXX_FLAGS="-Werror -Wall -Wextra" -D CMAKE_C_FLAGS="-Werror -Wall -Wextra"'
         cmake-build-type: 'Debug'
+        github-token: ${{ secrets.GITHUB_TOKEN }}
 
   prepare-and-build-linux-gcc-x64:
     name: Prepare and Build on Ubuntu with GCC (x64)
@@ -155,6 +161,7 @@ jobs:
         platform: linux
         compiler: gcc
         artifact-name: install-linux-gcc-x64
+        github-token: ${{ secrets.GITHUB_TOKEN }}
 
   build-inspector-windows:
     name: Build TInspector on Windows
index 48ee59ac7daa49548b622335fda8d5f836cccb2d..a67b70d823fcbe5cf56759dcc76009f6c65888a5 100644 (file)
@@ -776,6 +776,10 @@ endif()
 # the platform specific variables.
 if (BUILD_USE_VCPKG)
   project (OCCT)
+  if (APPLE)
+    # set Apple specific variables
+    occt_set_apple_csf_vars()
+  endif()
 endif()
 
 # copying clang-format file to the root of the project
index 5b2f5e0e787a6f4d32769720a6b09bf9bfe67b9d..e84863109e1520c60d229413012e622d5935f833 100644 (file)
@@ -38,11 +38,7 @@ endmacro()
 # vcpkg processing
 if (BUILD_USE_VCPKG)
   find_package (draco CONFIG REQUIRED)
-
-  set (3RDPARTY_DRACO_DIR "${VCPKG_INSTALLED_DIR}/${VCPKG_TARGET_TRIPLET}")
-  SEARCH_DRACO_LIB()
-
-  list (APPEND 3RDPARTY_INCLUDE_DIRS "${VCPKG_INSTALLED_DIR}/${VCPKG_TARGET_TRIPLET}/include/draco")
+  set(CSF_Draco draco::draco)
   return()
 endif()
 
index 49e35d442b158802f3d960dfe27662216427845a..0795158ae7d2e3ae6d77051190eceaa17c4537b3 100644 (file)
@@ -113,37 +113,8 @@ if (WIN32)
   set (CSF_OpenGlLibs    "opengl32.lib")
   set (CSF_OpenGlesLibs  "libEGL libGLESv2")
 else()
-
   if (APPLE)
-    set (CSF_objc        "objc")
-
-    # frameworks
-    if (IOS)
-      find_library (Appkit_LIB NAMES UIKit)
-      set (CSF_Appkit ${Appkit_LIB})
-    else()
-      find_library (Appkit_LIB NAMES AppKit)
-      set (CSF_Appkit ${Appkit_LIB})
-    endif()
-    OCCT_CHECK_AND_UNSET (Appkit_LIB)
-
-    find_library (IOKit_LIB NAMES IOKit)
-    set (CSF_IOKit ${IOKit_LIB})
-    OCCT_CHECK_AND_UNSET (IOKit_LIB)
-
-    if (IOS)
-      find_library (OpenGlesLibs_LIB NAMES OpenGLES)
-      set (CSF_OpenGlesLibs ${OpenGlesLibs_LIB})
-      OCCT_CHECK_AND_UNSET (OpenGlesLibs_LIB)
-    elseif (USE_XLIB)
-      set (CSF_OpenGlLibs "GL")
-      set (CSF_XwLibs     "X11")
-    else()
-      find_library (OpenGlLibs_LIB NAMES OpenGL)
-      set (CSF_OpenGlLibs ${OpenGlLibs_LIB})
-      OCCT_CHECK_AND_UNSET (OpenGlLibs_LIB)
-    endif()
-
+   # Will be called later
   elseif (EMSCRIPTEN)
     set (CSF_ThreadLibs   "pthread rt stdc++")
     set (CSF_OpenGlesLibs "EGL GLESv2")
@@ -163,7 +134,59 @@ else()
     set (CSF_OpenGlesLibs "EGL GLESv2")
     set (CSF_dl          "dl")
     if (USE_FREETYPE)
-      set (CSF_fontconfig "fontconfig")
+      set (CSF_fontconfig "fontconfig expat")
     endif()
   endif()
 endif()
+
+# Updates APPLE variables
+function(occt_set_apple_csf_vars)
+  set (CSF_objc        "objc" PARENT_SCOPE)
+
+  # frameworks
+  if (IOS)
+    find_library (Appkit_LIB NAMES UIKit)
+    if (Appkit_LIB)
+      set (CSF_Appkit ${Appkit_LIB} PARENT_SCOPE)
+    else()
+      set (CSF_Appkit "UIKit" PARENT_SCOPE)
+    endif()
+  else()
+    find_library (Appkit_LIB NAMES AppKit)
+    if (Appkit_LIB)
+      set (CSF_Appkit ${Appkit_LIB} PARENT_SCOPE)
+    else()
+      set (CSF_Appkit "AppKit" PARENT_SCOPE)
+    endif()
+  endif()
+  OCCT_CHECK_AND_UNSET (Appkit_LIB)
+
+  find_library (IOKit_LIB NAMES IOKit)
+  if (IOKit_LIB)
+    set (CSF_IOKit ${IOKit_LIB} PARENT_SCOPE)
+  else()
+    set (CSF_IOKit "IOKit" PARENT_SCOPE)
+  endif()
+  OCCT_CHECK_AND_UNSET (IOKit_LIB)
+
+  if (IOS)
+    find_library (OpenGlesLibs_LIB NAMES OpenGLES)
+    if (OpenGlesLibs_LIB)
+      set (CSF_OpenGlesLibs ${OpenGlesLibs_LIB} PARENT_SCOPE)
+    else()
+      set (CSF_OpenGlesLibs "OpenGLES" PARENT_SCOPE)
+    endif()
+    OCCT_CHECK_AND_UNSET (OpenGlesLibs_LIB)
+  elseif (USE_XLIB)
+    set (CSF_OpenGlLibs "GL" PARENT_SCOPE)
+    set (CSF_XwLibs     "X11" PARENT_SCOPE)
+  else()
+    find_library (OpenGlLibs_LIB NAMES OpenGL)
+    if (OpenGlLibs_LIB)
+      set (CSF_OpenGlLibs ${OpenGlLibs_LIB} PARENT_SCOPE)
+    else()
+      set (CSF_OpenGlLibs "OpenGL" PARENT_SCOPE)
+    endif()
+    OCCT_CHECK_AND_UNSET (OpenGlLibs_LIB)
+  endif()
+endfunction()
index ba3664f710366fb8ba23327a0cf4b58204d0fe70..842223861b32cb7817b2f483adf610b9e55f2ff2 100644 (file)
@@ -17,6 +17,7 @@ endif()
 if (BUILD_USE_VCPKG)
   set (3RDPARTY_TCL_DIR "${VCPKG_INSTALLED_DIR}/${VCPKG_TARGET_TRIPLET}" CACHE PATH "The directory containing tcl" FORCE)
   set (3RDPARTY_TCL_INCLUDE_DIR "${VCPKG_INSTALLED_DIR}/${VCPKG_TARGET_TRIPLET}/include" CACHE FILEPATH "The directory containing headers of tcl" FORCE)
+  set (3RDPARTY_TCL_LIBRARY_DIR "${VCPKG_INSTALLED_DIR}/${VCPKG_TARGET_TRIPLET}/lib" CACHE FILEPATH "The directory containing tcl library" FORCE)
 endif()
 
 # tcl library file (with absolute path)
@@ -182,7 +183,7 @@ endif()
 
 if (3RDPARTY_TCL_LIBRARY AND EXISTS "${3RDPARTY_TCL_LIBRARY}")
   list (APPEND 3RDPARTY_LIBRARY_DIRS "${3RDPARTY_TCL_LIBRARY_DIR}")
-else()
+elseif(NOT BUILD_USE_VCPKG)
   list (APPEND 3RDPARTY_NO_LIBS 3RDPARTY_TCL_LIBRARY_DIR)
 endif()
 
diff --git a/adm/vcpkg/ports/tcl/0001-Add-tk-build.patch b/adm/vcpkg/ports/tcl/0001-Add-tk-build.patch
deleted file mode 100644 (file)
index cf2aa6b..0000000
+++ /dev/null
@@ -1,48 +0,0 @@
-diff --git a/win/makefile.vc b/win/makefile.vc
-index c88c0ec3dc..6c9dd624d7 100644
---- a/win/makefile.vc
-+++ b/win/makefile.vc
-@@ -466,13 +466,13 @@ TESTFLAGS = $(TESTFLAGS) -file $(TESTPAT)
- # release   - Everything that builds as part of a release
- #---------------------------------------------------------------------
--release:    setup $(TCLSH) $(TCLSTUBLIB) dlls pkgs
-+release:    setup $(TCLSH) $(TCLSTUBLIB) dlls pkgs tk-build
- all:      setup $(TCLSH) $(TCLSTUBLIB) dlls $(CAT32) pkgs
- core:     setup $(TCLLIB) $(TCLSTUBLIB)
- shell:            setup $(TCLSH)
- dlls:     setup $(TCLREGLIB) $(TCLDDELIB) $(OUT_DIR)\zlib1.dll
- tcltest:    setup $(TCLTEST) dlls $(CAT32)
--install:    install-binaries install-libraries install-docs install-pkgs
-+install:    install-binaries install-libraries install-docs install-pkgs tk-build tk-install
- !if $(SYMBOLS)
- install:    install-pdbs
- !endif
-@@ -569,6 +569,24 @@ pkgs:
-           popd \
-         )
-+tk-build:
-+!if defined(TKDIR) && defined(INSTALLDIR)
-+      @if exist "$(TKDIR)\win\makefile.vc" ( \
-+          pushd "$(TKDIR)\win" & \
-+          $(MAKE) -$(MAKEFLAGS) -f makefile.vc TCLDIR=$(ROOT) INSTALLDIR=$(INSTALLDIR) OPTS=$(OPTS) STATS=$(STATS) CHECKS=$(CHECKS) MACHINE=$(MACHINE) &\
-+          popd \
-+        )
-+!endif
-+
-+tk-install:
-+!if defined(TKDIR) && defined(INSTALLDIR)
-+      @if exist "$(TKDIR)\win\makefile.vc" ( \
-+          pushd "$(TKDIR)\win" & \
-+          $(MAKE) -$(MAKEFLAGS) -f makefile.vc TCLDIR=$(ROOT) INSTALLDIR=$(INSTALLDIR) OPTS=$(OPTS) STATS=$(STATS) CHECKS=$(CHECKS) MACHINE=$(MACHINE) install &\
-+          popd \
-+        )
-+!endif
-+
- test-pkgs:
-       @for /d %d in ($(PKGSDIR)\*) do \
-         @if exist "%~fd\win\makefile.vc" ( \
--- 
-2.47.1.windows.2
-
diff --git a/adm/vcpkg/ports/tcl/0001-Support-Tk.patch b/adm/vcpkg/ports/tcl/0001-Support-Tk.patch
new file mode 100644 (file)
index 0000000..ec0fc2b
--- /dev/null
@@ -0,0 +1,415 @@
+From da6b5b83ef997f550155d9087c5e7b289168fb1b Mon Sep 17 00:00:00 2001
+From: dpasukhi <dpasukhi@opencascade.com>
+Date: Sat, 5 Jul 2025 11:36:01 +0100
+Subject: [PATCH] Add support for building and installing Tk in Makefiles for
+ Unix and Windows
+
+---
+ unix/Makefile.in | 94 +++++++++++++++++++++++++++++++++++++++++++++--
+ win/Makefile.in  | 68 ++++++++++++++++++++++++++++++++++
+ win/makefile.vc  | 96 +++++++++++++++++++++++++++++++++++++++++++++---
+ 3 files changed, 249 insertions(+), 9 deletions(-)
+
+diff --git a/unix/Makefile.in b/unix/Makefile.in
+index bc743b3892..dfdcf35acd 100644
+--- a/unix/Makefile.in
++++ b/unix/Makefile.in
+@@ -232,6 +232,7 @@ TOOL_DIR           = $(TOP_DIR)/tools
+ UNIX_DIR              = $(TOP_DIR)/unix
+ MAC_OSX_DIR           = $(TOP_DIR)/macosx
+ PKGS_DIR              = $(TOP_DIR)/pkgs
++EXTRADIR              = $(TOP_DIR)/extra
+ # Must be absolute because of the cd dltest $(DLTEST_DIR)/configure below.
+ DLTEST_DIR            = @TCL_SRC_DIR@/unix/dltest
+ # Must be absolute to so the corresponding tcltest's tcl_library is absolute.
+@@ -622,7 +623,7 @@ SRCS = $(GENERIC_SRCS) $(UNIX_SRCS) $(NOTIFY_SRCS) \
+ # Start of rules
+ #--------------------------------------------------------------------------
+-all: binaries libraries doc packages
++all: binaries libraries doc packages extra
+ binaries: ${LIB_FILE} ${TCL_EXE}
+@@ -666,13 +667,13 @@ Makefile: $(UNIX_DIR)/Makefile.in $(DLTEST_DIR)/Makefile.in
+ #tclConfig.h: $(UNIX_DIR)/tclConfig.h.in
+ #     $(SHELL) config.status
+-clean: clean-packages
++clean: clean-packages clean-extra
+       rm -rf *.a *.o libtcl* core errs *~ \#* TAGS *.E a.out \
+               errors ${TCL_EXE} ${TCLTEST_EXE} lib.exp Tcl @DTRACE_HDR@ \
+               minizip${HOST_EXEEXT} *.${HOST_OBJEXT} *.zip *.vfs
+       (cd dltest ; $(MAKE) clean)
+-distclean: distclean-packages clean
++distclean: distclean-packages clean distclean-extra
+       rm -rf Makefile config.status config.cache config.log tclConfig.sh \
+               tclConfig.h *.plist Tcl.framework tcl.pc tclUuid.h
+       (cd dltest ; $(MAKE) distclean)
+@@ -795,7 +796,7 @@ INSTALL_EXTRA_TARGETS = @EXTRA_INSTALL@
+ INSTALL_TARGETS = $(INSTALL_BASE_TARGETS) $(INSTALL_DOC_TARGETS) $(INSTALL_DEV_TARGETS) \
+                 $(INSTALL_PACKAGE_TARGETS) $(INSTALL_EXTRA_TARGETS)
+-install: $(INSTALL_TARGETS)
++install: $(INSTALL_TARGETS) install-extra
+ install-strip:
+       $(MAKE) $(INSTALL_TARGETS) \
+@@ -1725,6 +1726,7 @@ PKG_CFG_ARGS             = @PKG_CFG_ARGS@
+ # cannot use absolute paths due to issues in nested configure when path to
+ # build dir contains spaces).
+ PKG_DIR                       = ./pkgs
++EXTRA_BUILD_DIR               = ./extra
+ configure-packages:
+       @for i in $(PKGS_DIR)/*; do \
+@@ -2151,6 +2153,89 @@ BUILD_HTML = \
+               --useversion=$(HTML_VERSION) --htmldir="$(HTML_INSTALL_DIR)" \
+               --srcdir=$(TOP_DIR)/.. $(BUILD_HTML_FLAGS)
++#--------------------------------------------------------------------------
++# Extra packages build targets (for TK and other extras)
++#--------------------------------------------------------------------------
++
++extra:
++      @if test -d "$(EXTRADIR)"; then \
++          for extradir in $(EXTRADIR)/*; do \
++              if test -d "$$extradir/unix" && test -f "$$extradir/unix/configure"; then \
++                  extrapkg=`basename $$extradir`; \
++                  echo "Building extra package '$$extrapkg'"; \
++                  mkdir -p "$(EXTRA_BUILD_DIR)/$$extrapkg"; \
++                  TCL_BUILD_DIR="`pwd`"; \
++                  if test ! -f "$(EXTRA_BUILD_DIR)/$$extrapkg/Makefile"; then \
++                      echo "Configuring extra package '$$extrapkg'"; \
++                      (cd "$(EXTRA_BUILD_DIR)/$$extrapkg" && \
++                       "$$extradir/unix/configure" \
++                           --prefix="$(prefix)" \
++                           --exec-prefix="$(exec_prefix)" \
++                           --with-tcl="$$TCL_BUILD_DIR" \
++                           CFLAGS="$(CFLAGS)" \
++                           CPPFLAGS="$(CPPFLAGS)" \
++                           LDFLAGS="$(LDFLAGS)" \
++                           CC="$(CC)") || exit $$?; \
++                  fi; \
++                  echo "Building extra package '$$extrapkg'"; \
++                  (cd "$(EXTRA_BUILD_DIR)/$$extrapkg" && \
++                   $(MAKE) \
++                      TCL_LIBRARY=$(TCL_LIBRARY) \
++                      CFLAGS="$(CFLAGS)" \
++                      CPPFLAGS="$(CPPFLAGS)" \
++                      LDFLAGS="$(LDFLAGS)" \
++                      CC="$(CC)") || exit $$?; \
++              fi; \
++          done; \
++      else \
++          echo "No extra directory found at $(EXTRADIR) - skipping extra builds"; \
++      fi
++
++install-extra:
++      @if test -d "$(EXTRADIR)"; then \
++          for extradir in $(EXTRADIR)/*; do \
++              if test -d "$$extradir/unix" && test -f "$$extradir/unix/configure"; then \
++                  extrapkg=`basename $$extradir`; \
++                  if test -f "$(EXTRA_BUILD_DIR)/$$extrapkg/Makefile"; then \
++                      echo "Installing extra package '$$extrapkg'"; \
++                      (cd "$(EXTRA_BUILD_DIR)/$$extrapkg" && $(MAKE) install \
++                          DESTDIR="$(INSTALL_ROOT)" \
++                          prefix="$(prefix)" \
++                          exec_prefix="$(exec_prefix)" \
++                          TCL_LIBRARY=$(TCL_LIBRARY) \
++                          CFLAGS="$(CFLAGS)" \
++                          CPPFLAGS="$(CPPFLAGS)" \
++                          LDFLAGS="$(LDFLAGS)" \
++                          CC="$(CC)") || exit $$?; \
++                  fi; \
++              fi; \
++          done; \
++      else \
++          echo "No extra directory found - skipping extra installs"; \
++      fi
++
++clean-extra:
++      @if test -d "$(EXTRA_BUILD_DIR)"; then \
++          for extrapkg in $(EXTRA_BUILD_DIR)/*; do \
++              if test -d "$$extrapkg" && test -f "$$extrapkg/Makefile"; then \
++                  echo "Cleaning extra package in $$extrapkg"; \
++                  (cd "$$extrapkg" && $(MAKE) clean) || exit $$?; \
++              fi; \
++          done; \
++      fi
++
++distclean-extra:
++      @if test -d "$(EXTRA_BUILD_DIR)"; then \
++          for extrapkg in $(EXTRA_BUILD_DIR)/*; do \
++              if test -d "$$extrapkg" && test -f "$$extrapkg/Makefile"; then \
++                  echo "Distcleaning extra package in $$extrapkg"; \
++                  (cd "$$extrapkg" && $(MAKE) distclean) || exit $$?; \
++              fi; \
++              rm -rf "$$extrapkg"; \
++          done; \
++          rm -rf "$(EXTRA_BUILD_DIR)"; \
++      fi
++
+ #--------------------------------------------------------------------------
+ # The list of all the targets that do not correspond to real files. This stops
+ # 'make' from getting confused when someone makes an error in a rule.
+@@ -2166,6 +2251,7 @@ BUILD_HTML = \
+ .PHONY: install-tzdata install-msgs
+ .PHONY: packages configure-packages test-packages clean-packages
+ .PHONY: dist-packages distclean-packages install-packages
++.PHONY: extra install-extra clean-extra distclean-extra
+ #--------------------------------------------------------------------------
+ # DO NOT DELETE THIS LINE -- make depend depends on it.
+diff --git a/win/Makefile.in b/win/Makefile.in
+index 8dd107670f..f0cf267329 100644
+--- a/win/Makefile.in
++++ b/win/Makefile.in
+@@ -129,6 +129,11 @@ ROOT_DIR_WIN_NATIVE       = $(shell cd '$(ROOT_DIR)' ; pwd -W 2>/dev/null || pwd -P)
+ ZLIB_DIR_NATIVE               = $(shell $(CYGPATH) '$(ZLIB_DIR)')
+ TOMMATH_DIR_NATIVE    = $(shell $(CYGPATH) '$(TOMMATH_DIR)')
++# Tk-related directories (TKDIR can be set by user)
++TK_SRC_DIR            = $(TKDIR)
++TK_BUILD_TOP          = $(TKDIR)/win
++CONFIG_INSTALL_DIR    = $(LIB_INSTALL_DIR)
++
+ # Fully qualify library path so that `make test`
+ # does not depend on the current directory.
+ LIBRARY_DIR1          = $(shell cd '$(ROOT_DIR_NATIVE)/library' ; pwd -P)
+@@ -432,6 +437,34 @@ TCL_OBJS = ${GENERIC_OBJS} ${WIN_OBJS} @ZLIB_OBJS@ $(TOMMATH_OBJS)
+ TCL_DOCS = "$(ROOT_DIR_NATIVE)"/doc/*.[13n]
+ all: binaries libraries doc packages
++      @if test -n "$(TKDIR)" && test -d "$(TKDIR)"; then \
++          echo "TKDIR detected - automatically building Tk..."; \
++          echo "========== TK BUILD PARAMETERS =========="; \
++          echo "TKDIR=$(TKDIR)"; \
++          echo "TCLDIR=$(TOP_DIR)"; \
++          echo "prefix=$(prefix)"; \
++          echo "exec_prefix=$(exec_prefix)"; \
++          echo "TCL_TCLSH=$(BIN_INSTALL_DIR)/tclsh$(VER)${EXESUFFIX}"; \
++          echo "=========================================="; \
++          if test -f "$(TK_BUILD_TOP)/Makefile"; then \
++              echo "Building Tk using existing Makefile..."; \
++              (cd "$(TK_BUILD_TOP)" && $(MAKE)) || exit $$?; \
++          elif test -f "$(TK_SRC_DIR)/win/configure"; then \
++              echo "Configuring and building Tk..."; \
++              mkdir -p "$(TK_BUILD_TOP)"; \
++              (cd "$(TK_BUILD_TOP)" && \
++               "$(TK_SRC_DIR)/win/configure" \
++                  --prefix="$(prefix)" \
++                  --exec-prefix="$(exec_prefix)" \
++                  --with-tcl="$(CONFIG_INSTALL_DIR)" && \
++               $(MAKE)) || exit $$?; \
++          else \
++              echo "ERROR: Tk configure script not found at $(TK_SRC_DIR)/win/configure"; \
++              exit 1; \
++          fi; \
++      else \
++          echo "TKDIR not set or directory does not exist - skipping Tk build"; \
++      fi
+ # Test-suite helper (can be used to test Tcl from build directory with all expected modules).
+ # To start from windows shell use:
+@@ -648,6 +681,27 @@ gentommath_h:
+               > "$(GENERIC_DIR_NATIVE)/tclTomMath.h"
+ install: all install-binaries install-libraries install-doc install-packages
++      @if test -n "$(TKDIR)" && test -d "$(TKDIR)"; then \
++          echo "TKDIR detected - automatically installing Tk..."; \
++          echo "========== TK INSTALL PARAMETERS =========="; \
++          echo "TKDIR=$(TKDIR)"; \
++          echo "TCLDIR=$(TOP_DIR)"; \
++          echo "prefix=$(prefix)"; \
++          echo "exec_prefix=$(exec_prefix)"; \
++          echo "DESTDIR=$(INSTALL_ROOT)"; \
++          echo "TCL_TCLSH=$(BIN_INSTALL_DIR)/tclsh$(VER)${EXESUFFIX}"; \
++          echo "==========================================="; \
++          if test -f "$(TK_BUILD_TOP)/Makefile"; then \
++              echo "Installing Tk..."; \
++              (cd "$(TK_BUILD_TOP)" && $(MAKE) install DESTDIR="$(INSTALL_ROOT)") || exit $$?; \
++          else \
++              echo "ERROR: Tk Makefile not found at $(TK_BUILD_TOP)/Makefile"; \
++              echo "Please run 'make all' first to build Tk"; \
++              exit 1; \
++          fi; \
++      else \
++          echo "TKDIR not set or directory does not exist - skipping Tk install"; \
++      fi
+ install-binaries: binaries
+       @for i in "$(LIB_INSTALL_DIR)" "$(BIN_INSTALL_DIR)"; \
+@@ -848,10 +902,24 @@ clean: cleanhelp clean-packages
+       $(RM) $(TCLSH) $(CAT32) $(TEST_EXE_FILE) $(TEST_DLL_FILE) tcltest.cmd tcltest.sh
+       $(RM) *.pch *.ilk *.pdb *.zip
+       $(RMDIR) *.vfs
++      @if test -n "$(TKDIR)" && test -d "$(TKDIR)" && test -f "$(TK_BUILD_TOP)/Makefile"; then \
++          echo "TKDIR detected - automatically cleaning Tk..."; \
++          echo "Cleaning Tk build..."; \
++          (cd "$(TK_BUILD_TOP)" && $(MAKE) clean) || exit $$?; \
++      else \
++          echo "TKDIR not set, directory does not exist, or no Tk build to clean"; \
++      fi
+ distclean: distclean-packages clean
+       $(RM) Makefile config.status config.cache config.log tclConfig.sh \
+               tcl.hpj config.status.lineno tclsh.exe.manifest tclUuid.h
++      @if test -n "$(TKDIR)" && test -d "$(TKDIR)" && test -f "$(TK_BUILD_TOP)/Makefile"; then \
++          echo "TKDIR detected - automatically distcleaning Tk..."; \
++          echo "Distcleaning Tk build..."; \
++          (cd "$(TK_BUILD_TOP)" && $(MAKE) distclean) || exit $$?; \
++      else \
++          echo "TKDIR not set, directory does not exist, or no Tk build to distclean"; \
++      fi
+ #
+ # Bundled package targets
+diff --git a/win/makefile.vc b/win/makefile.vc
+index c88c0ec3dc..cbdad89ba8 100644
+--- a/win/makefile.vc
++++ b/win/makefile.vc
+@@ -420,6 +420,7 @@ TCLSTUBOBJS = \
+ ### the left side of implicit rules.
+ TOMMATHDIR    = $(ROOT)\libtommath
+ PKGSDIR               = $(ROOT)\pkgs
++WINDIR                = $(ROOT)\win
+ # Additional include and C macro definitions for the implicit rules
+ # defined in rules.vc
+@@ -438,6 +439,7 @@ TESTFLAGS = $(TESTFLAGS) -file $(TESTPAT)
+ !endif
++
+ #---------------------------------------------------------------------
+ # Project specific targets
+ # There are 4 primary build configurations to consider from the combination
+@@ -466,18 +468,24 @@ TESTFLAGS = $(TESTFLAGS) -file $(TESTPAT)
+ # release   - Everything that builds as part of a release
+ #---------------------------------------------------------------------
+-release:    setup $(TCLSH) $(TCLSTUBLIB) dlls pkgs
+-all:      setup $(TCLSH) $(TCLSTUBLIB) dlls $(CAT32) pkgs
++release:    setup $(TCLSH) $(TCLSTUBLIB) dlls setpath pkgs tk-build
++all:      setup $(TCLSH) $(TCLSTUBLIB) dlls $(CAT32) setpath pkgs
+ core:     setup $(TCLLIB) $(TCLSTUBLIB)
+ shell:            setup $(TCLSH)
+ dlls:     setup $(TCLREGLIB) $(TCLDDELIB) $(OUT_DIR)\zlib1.dll
+ tcltest:    setup $(TCLTEST) dlls $(CAT32)
+-install:    install-binaries install-libraries install-docs install-pkgs
++install:    setpath install-binaries install-libraries install-docs install-pkgs tk-build tk-install
+ !if $(SYMBOLS)
+ install:    install-pdbs
+ !endif
+ setup:      default-setup
++# Add TCL win directory to PATH for current session
++setpath:
++      @echo Adding $(WINDIR) to PATH
++      @set PATH=$(WINDIR);$(PATH)
++      @echo PATH updated for current session
++
+ test: test-core test-pkgs
+ test-core: setup $(TCLTEST) dlls $(CAT32)
+       set TCL_LIBRARY=$(ROOT:\=/)/library
+@@ -569,6 +577,84 @@ pkgs:
+           popd \
+         )
++tk-build:
++!if defined(TKDIR)
++      @echo TKDIR detected - building Tk...
++      @echo ========== TK BUILD PARAMETERS ==========
++      @echo TKDIR=$(TKDIR)
++      @echo TCLDIR=$(ROOT)
++!if defined(INSTALLDIR)
++      @echo INSTALLDIR=$(INSTALLDIR)
++!endif
++      @echo OPTS=$(OPTS)
++      @echo STATS=$(STATS)
++      @echo CHECKS=$(CHECKS)
++      @echo MACHINE=$(MACHINE)
++      @echo ==========================================
++      @if exist "$(TKDIR)\win\makefile.vc" ( \
++          pushd "$(TKDIR)\win" & \
++          $(MAKE) -$(MAKEFLAGS) -f makefile.vc TCLDIR=$(ROOT) OPTS=$(OPTS) STATS=$(STATS) CHECKS=$(CHECKS) MACHINE=$(MACHINE) & \
++          popd \
++        ) else ( \
++          echo ERROR: Tk makefile.vc not found at $(TKDIR)\win\makefile.vc & \
++          exit 1 \
++        )
++!else
++      @echo TKDIR not set or directory does not exist - skipping Tk build
++!endif
++
++tk-install:
++!if defined(TKDIR) && defined(INSTALLDIR)
++      @echo TKDIR detected - installing Tk...
++      @echo ========== TK INSTALL PARAMETERS ==========
++      @echo TKDIR=$(TKDIR)
++      @echo TCLDIR=$(ROOT)
++      @echo INSTALLDIR=$(INSTALLDIR)
++      @echo OPTS=$(OPTS)
++      @echo STATS=$(STATS)
++      @echo CHECKS=$(CHECKS)
++      @echo MACHINE=$(MACHINE)
++      @echo ===========================================
++      @if exist "$(TKDIR)\win\makefile.vc" ( \
++          pushd "$(TKDIR)\win" & \
++          $(MAKE) -$(MAKEFLAGS) -f makefile.vc TCLDIR=$(ROOT) INSTALLDIR=$(INSTALLDIR) OPTS=$(OPTS) STATS=$(STATS) CHECKS=$(CHECKS) MACHINE=$(MACHINE) install & \
++          popd \
++        ) else ( \
++          echo ERROR: Tk makefile.vc not found at $(TKDIR)\win\makefile.vc & \
++          exit 1 \
++        )
++!else
++      @echo TKDIR not set, INSTALLDIR not set, or directory does not exist - skipping Tk install
++!endif
++
++tk-clean:
++!if defined(TKDIR)
++      @echo TKDIR detected - cleaning Tk build...
++      @if exist "$(TKDIR)\win\makefile.vc" ( \
++          pushd "$(TKDIR)\win" & \
++          $(MAKE) -$(MAKEFLAGS) -f makefile.vc TCLDIR=$(ROOT) clean & \
++          popd \
++        ) else ( \
++          echo No Tk makefile found to clean \
++        )
++!else
++      @echo TKDIR not set or directory does not exist - skipping Tk clean
++!endif
++
++tk-distclean:
++!if defined(TKDIR)
++      @echo TKDIR detected - distcleaning Tk build...
++      @if exist "$(TKDIR)\win\makefile.vc" ( \
++          pushd "$(TKDIR)\win" & \
++          $(MAKE) -$(MAKEFLAGS) -f makefile.vc TCLDIR=$(ROOT) distclean & \
++          popd \
++        ) else ( \
++          echo No Tk makefile found to distclean \
++        )
++!else
++      @echo TKDIR not set or directory does not exist - skipping Tk distclean
++!endif
++
+ test-pkgs:
+       @for /d %d in ($(PKGSDIR)\*) do \
+         @if exist "%~fd\win\makefile.vc" ( \
+@@ -1058,8 +1144,8 @@ tidy:
+       @echo Removing $(TCLREGLIB) ...
+       @if exist $(TCLREGLIB) del $(TCLREGLIB)
+-clean: default-clean clean-pkgs
+-hose: default-hose hose-pkgs
++clean: default-clean clean-pkgs tk-clean
++hose: default-hose hose-pkgs tk-distclean
+ realclean: hose
+ .PHONY:
+-- 
+2.43.0
+
diff --git a/adm/vcpkg/ports/tcl/0002-Add-setpath-target.patch b/adm/vcpkg/ports/tcl/0002-Add-setpath-target.patch
deleted file mode 100644 (file)
index 0f517e9..0000000
+++ /dev/null
@@ -1,51 +0,0 @@
-diff --git a/win/makefile.vc b/win/makefile.vc
-index 6c9dd624d7..d29185feed 100644
---- a/win/makefile.vc
-+++ b/win/makefile.vc
-@@ -420,6 +420,7 @@ TCLSTUBOBJS = \
- ### the left side of implicit rules.
- TOMMATHDIR    = $(ROOT)\libtommath
- PKGSDIR               = $(ROOT)\pkgs
-+WINDIR                = $(ROOT)\win
- # Additional include and C macro definitions for the implicit rules
- # defined in rules.vc
-@@ -438,6 +439,7 @@ TESTFLAGS = $(TESTFLAGS) -file $(TESTPAT)
- !endif
-+
- #---------------------------------------------------------------------
- # Project specific targets
- # There are 4 primary build configurations to consider from the combination
-@@ -466,18 +468,24 @@ TESTFLAGS = $(TESTFLAGS) -file $(TESTPAT)
- # release   - Everything that builds as part of a release
- #---------------------------------------------------------------------
--release:    setup $(TCLSH) $(TCLSTUBLIB) dlls pkgs tk-build
--all:      setup $(TCLSH) $(TCLSTUBLIB) dlls $(CAT32) pkgs
-+release:    setup $(TCLSH) $(TCLSTUBLIB) dlls setpath pkgs tk-build
-+all:      setup $(TCLSH) $(TCLSTUBLIB) dlls $(CAT32) setpath pkgs
- core:     setup $(TCLLIB) $(TCLSTUBLIB)
- shell:            setup $(TCLSH)
- dlls:     setup $(TCLREGLIB) $(TCLDDELIB) $(OUT_DIR)\zlib1.dll
- tcltest:    setup $(TCLTEST) dlls $(CAT32)
--install:    install-binaries install-libraries install-docs install-pkgs tk-build tk-install
-+install:    setpath install-binaries install-libraries install-docs install-pkgs tk-build tk-install
- !if $(SYMBOLS)
- install:    install-pdbs
- !endif
- setup:      default-setup
-+# Add TCL win directory to PATH for current session
-+setpath:
-+      @echo Adding $(WINDIR) to PATH
-+      @set PATH=$(WINDIR);$(PATH)
-+      @echo PATH updated for current session
-+
- test: test-core test-pkgs
- test-core: setup $(TCLTEST) dlls $(CAT32)
-       set TCL_LIBRARY=$(ROOT:\=/)/library
--- 
-2.47.1.windows.2
-
diff --git a/adm/vcpkg/ports/tcl/0003-Update-unix-build.patch b/adm/vcpkg/ports/tcl/0003-Update-unix-build.patch
deleted file mode 100644 (file)
index 164eead..0000000
+++ /dev/null
@@ -1,119 +0,0 @@
-From 34a5ac55260871875c3ad678df8c21ef31500d21 Mon Sep 17 00:00:00 2001
-From: dpasukhi <dpasukhi@opencascade.com>
-Date: Sun, 22 Jun 2025 14:18:19 +0100
-Subject: [PATCH] Add Tk build and install support to Makefile; include
- automatic clean and distclean steps
-
----
- unix/Makefile.in | 69 ++++++++++++++++++++++++++++++++++++++++++++++++
- 1 file changed, 69 insertions(+)
-
-diff --git a/unix/Makefile.in b/unix/Makefile.in
-index bc743b3892..7464e3f930 100644
---- a/unix/Makefile.in
-+++ b/unix/Makefile.in
-@@ -95,6 +95,12 @@ TCL_PACKAGE_PATH    = @TCL_PACKAGE_PATH@
- # Tcl Module default path roots (TIP189).
- TCL_MODULE_PATH               = @TCL_MODULE_PATH@
-+# Tk-related directories and settings
-+# These can be overridden on the command line or set via environment
-+TKDIR                 = @TKDIR@
-+TK_BUILD_TOP          = $(TKDIR)/unix
-+TK_SRC_DIR            = $(TKDIR)
-+
- # warning flags
- CFLAGS_WARNING                = @CFLAGS_WARNING@
-@@ -623,6 +629,34 @@ SRCS = $(GENERIC_SRCS) $(UNIX_SRCS) $(NOTIFY_SRCS) \
- #--------------------------------------------------------------------------
- all: binaries libraries doc packages
-+      @if test -n "$(TKDIR)" && test -d "$(TKDIR)"; then \
-+          echo "TKDIR detected - automatically building Tk..."; \
-+          echo "========== TK BUILD PARAMETERS =========="; \
-+          echo "TKDIR=$(TKDIR)"; \
-+          echo "TCLDIR=$(TOP_DIR)"; \
-+          echo "prefix=$(prefix)"; \
-+          echo "exec_prefix=$(exec_prefix)"; \
-+          echo "TCL_TCLSH=$(BIN_INSTALL_DIR)/tclsh$(VERSION)${EXE_SUFFIX}"; \
-+          echo "=========================================="; \
-+          if test -f "$(TK_BUILD_TOP)/Makefile"; then \
-+              echo "Building Tk using existing Makefile..."; \
-+              (cd "$(TK_BUILD_TOP)" && $(MAKE)) || exit $$?; \
-+          elif test -f "$(TK_SRC_DIR)/unix/configure"; then \
-+              echo "Configuring and building Tk..."; \
-+              mkdir -p "$(TK_BUILD_TOP)"; \
-+              (cd "$(TK_BUILD_TOP)" && \
-+               "$(TK_SRC_DIR)/unix/configure" \
-+                  --prefix="$(prefix)" \
-+                  --exec-prefix="$(exec_prefix)" \
-+                  --with-tcl="$(CONFIG_INSTALL_DIR)" && \
-+               $(MAKE)) || exit $$?; \
-+          else \
-+              echo "ERROR: Tk configure script not found at $(TK_SRC_DIR)/unix/configure"; \
-+              exit 1; \
-+          fi; \
-+      else \
-+          echo "TKDIR not set or directory does not exist - skipping Tk build"; \
-+      fi
- binaries: ${LIB_FILE} ${TCL_EXE}
-@@ -671,11 +705,25 @@ clean: clean-packages
-               errors ${TCL_EXE} ${TCLTEST_EXE} lib.exp Tcl @DTRACE_HDR@ \
-               minizip${HOST_EXEEXT} *.${HOST_OBJEXT} *.zip *.vfs
-       (cd dltest ; $(MAKE) clean)
-+      @if test -n "$(TKDIR)" && test -d "$(TKDIR)" && test -f "$(TK_BUILD_TOP)/Makefile"; then \
-+          echo "TKDIR detected - automatically cleaning Tk..."; \
-+          echo "Cleaning Tk build..."; \
-+          (cd "$(TK_BUILD_TOP)" && $(MAKE) clean) || exit $$?; \
-+      else \
-+          echo "TKDIR not set, directory does not exist, or no Tk build to clean"; \
-+      fi
- distclean: distclean-packages clean
-       rm -rf Makefile config.status config.cache config.log tclConfig.sh \
-               tclConfig.h *.plist Tcl.framework tcl.pc tclUuid.h
-       (cd dltest ; $(MAKE) distclean)
-+      @if test -n "$(TKDIR)" && test -d "$(TKDIR)" && test -f "$(TK_BUILD_TOP)/Makefile"; then \
-+          echo "TKDIR detected - automatically distcleaning Tk..."; \
-+          echo "Distcleaning Tk build..."; \
-+          (cd "$(TK_BUILD_TOP)" && $(MAKE) distclean) || exit $$?; \
-+      else \
-+          echo "TKDIR not set, directory does not exist, or no Tk build to distclean"; \
-+      fi
- depend:
-       makedepend -- $(DEPEND_SWITCHES) -- $(SRCS)
-@@ -796,6 +844,27 @@ INSTALL_TARGETS = $(INSTALL_BASE_TARGETS) $(INSTALL_DOC_TARGETS) $(INSTALL_DEV_T
-                 $(INSTALL_PACKAGE_TARGETS) $(INSTALL_EXTRA_TARGETS)
- install: $(INSTALL_TARGETS)
-+      @if test -n "$(TKDIR)" && test -d "$(TKDIR)"; then \
-+          echo "TKDIR detected - automatically installing Tk..."; \
-+          echo "========== TK INSTALL PARAMETERS =========="; \
-+          echo "TKDIR=$(TKDIR)"; \
-+          echo "TCLDIR=$(TOP_DIR)"; \
-+          echo "prefix=$(prefix)"; \
-+          echo "exec_prefix=$(exec_prefix)"; \
-+          echo "DESTDIR=$(INSTALL_ROOT)"; \
-+          echo "TCL_TCLSH=$(BIN_INSTALL_DIR)/tclsh$(VERSION)${EXE_SUFFIX}"; \
-+          echo "==========================================="; \
-+          if test -f "$(TK_BUILD_TOP)/Makefile"; then \
-+              echo "Installing Tk..."; \
-+              (cd "$(TK_BUILD_TOP)" && $(MAKE) install DESTDIR="$(INSTALL_ROOT)") || exit $$?; \
-+          else \
-+              echo "ERROR: Tk Makefile not found at $(TK_BUILD_TOP)/Makefile"; \
-+              echo "Please run 'make all' first to build Tk"; \
-+              exit 1; \
-+          fi; \
-+      else \
-+          echo "TKDIR not set or directory does not exist - skipping Tk install"; \
-+      fi
- install-strip:
-       $(MAKE) $(INSTALL_TARGETS) \
--- 
-2.47.1.windows.2
-
diff --git a/adm/vcpkg/ports/tcl/0004-Update-mingw-build.patch b/adm/vcpkg/ports/tcl/0004-Update-mingw-build.patch
deleted file mode 100644 (file)
index 278f1f0..0000000
+++ /dev/null
@@ -1,117 +0,0 @@
-From bf55f8558b8ca6603f6539c6421391f26ab6139a Mon Sep 17 00:00:00 2001
-From: dpasukhi <dpasukhi@opencascade.com>
-Date: Sun, 22 Jun 2025 15:20:03 +0100
-Subject: [PATCH] Add Tk build and install automation to Makefile; include
- clean and distclean targets
-
----
- win/Makefile.in | 68 +++++++++++++++++++++++++++++++++++++++++++++++++
- 1 file changed, 68 insertions(+)
-
-diff --git a/win/Makefile.in b/win/Makefile.in
-index 8dd107670f..f0cf267329 100644
---- a/win/Makefile.in
-+++ b/win/Makefile.in
-@@ -129,6 +129,11 @@ ROOT_DIR_WIN_NATIVE       = $(shell cd '$(ROOT_DIR)' ; pwd -W 2>/dev/null || pwd -P)
- ZLIB_DIR_NATIVE               = $(shell $(CYGPATH) '$(ZLIB_DIR)')
- TOMMATH_DIR_NATIVE    = $(shell $(CYGPATH) '$(TOMMATH_DIR)')
-+# Tk-related directories (TKDIR can be set by user)
-+TK_SRC_DIR            = $(TKDIR)
-+TK_BUILD_TOP          = $(TKDIR)/win
-+CONFIG_INSTALL_DIR    = $(LIB_INSTALL_DIR)
-+
- # Fully qualify library path so that `make test`
- # does not depend on the current directory.
- LIBRARY_DIR1          = $(shell cd '$(ROOT_DIR_NATIVE)/library' ; pwd -P)
-@@ -432,6 +437,34 @@ TCL_OBJS = ${GENERIC_OBJS} ${WIN_OBJS} @ZLIB_OBJS@ $(TOMMATH_OBJS)
- TCL_DOCS = "$(ROOT_DIR_NATIVE)"/doc/*.[13n]
- all: binaries libraries doc packages
-+      @if test -n "$(TKDIR)" && test -d "$(TKDIR)"; then \
-+          echo "TKDIR detected - automatically building Tk..."; \
-+          echo "========== TK BUILD PARAMETERS =========="; \
-+          echo "TKDIR=$(TKDIR)"; \
-+          echo "TCLDIR=$(TOP_DIR)"; \
-+          echo "prefix=$(prefix)"; \
-+          echo "exec_prefix=$(exec_prefix)"; \
-+          echo "TCL_TCLSH=$(BIN_INSTALL_DIR)/tclsh$(VER)${EXESUFFIX}"; \
-+          echo "=========================================="; \
-+          if test -f "$(TK_BUILD_TOP)/Makefile"; then \
-+              echo "Building Tk using existing Makefile..."; \
-+              (cd "$(TK_BUILD_TOP)" && $(MAKE)) || exit $$?; \
-+          elif test -f "$(TK_SRC_DIR)/win/configure"; then \
-+              echo "Configuring and building Tk..."; \
-+              mkdir -p "$(TK_BUILD_TOP)"; \
-+              (cd "$(TK_BUILD_TOP)" && \
-+               "$(TK_SRC_DIR)/win/configure" \
-+                  --prefix="$(prefix)" \
-+                  --exec-prefix="$(exec_prefix)" \
-+                  --with-tcl="$(CONFIG_INSTALL_DIR)" && \
-+               $(MAKE)) || exit $$?; \
-+          else \
-+              echo "ERROR: Tk configure script not found at $(TK_SRC_DIR)/win/configure"; \
-+              exit 1; \
-+          fi; \
-+      else \
-+          echo "TKDIR not set or directory does not exist - skipping Tk build"; \
-+      fi
- # Test-suite helper (can be used to test Tcl from build directory with all expected modules).
- # To start from windows shell use:
-@@ -648,6 +681,27 @@ gentommath_h:
-               > "$(GENERIC_DIR_NATIVE)/tclTomMath.h"
- install: all install-binaries install-libraries install-doc install-packages
-+      @if test -n "$(TKDIR)" && test -d "$(TKDIR)"; then \
-+          echo "TKDIR detected - automatically installing Tk..."; \
-+          echo "========== TK INSTALL PARAMETERS =========="; \
-+          echo "TKDIR=$(TKDIR)"; \
-+          echo "TCLDIR=$(TOP_DIR)"; \
-+          echo "prefix=$(prefix)"; \
-+          echo "exec_prefix=$(exec_prefix)"; \
-+          echo "DESTDIR=$(INSTALL_ROOT)"; \
-+          echo "TCL_TCLSH=$(BIN_INSTALL_DIR)/tclsh$(VER)${EXESUFFIX}"; \
-+          echo "==========================================="; \
-+          if test -f "$(TK_BUILD_TOP)/Makefile"; then \
-+              echo "Installing Tk..."; \
-+              (cd "$(TK_BUILD_TOP)" && $(MAKE) install DESTDIR="$(INSTALL_ROOT)") || exit $$?; \
-+          else \
-+              echo "ERROR: Tk Makefile not found at $(TK_BUILD_TOP)/Makefile"; \
-+              echo "Please run 'make all' first to build Tk"; \
-+              exit 1; \
-+          fi; \
-+      else \
-+          echo "TKDIR not set or directory does not exist - skipping Tk install"; \
-+      fi
- install-binaries: binaries
-       @for i in "$(LIB_INSTALL_DIR)" "$(BIN_INSTALL_DIR)"; \
-@@ -848,10 +902,24 @@ clean: cleanhelp clean-packages
-       $(RM) $(TCLSH) $(CAT32) $(TEST_EXE_FILE) $(TEST_DLL_FILE) tcltest.cmd tcltest.sh
-       $(RM) *.pch *.ilk *.pdb *.zip
-       $(RMDIR) *.vfs
-+      @if test -n "$(TKDIR)" && test -d "$(TKDIR)" && test -f "$(TK_BUILD_TOP)/Makefile"; then \
-+          echo "TKDIR detected - automatically cleaning Tk..."; \
-+          echo "Cleaning Tk build..."; \
-+          (cd "$(TK_BUILD_TOP)" && $(MAKE) clean) || exit $$?; \
-+      else \
-+          echo "TKDIR not set, directory does not exist, or no Tk build to clean"; \
-+      fi
- distclean: distclean-packages clean
-       $(RM) Makefile config.status config.cache config.log tclConfig.sh \
-               tcl.hpj config.status.lineno tclsh.exe.manifest tclUuid.h
-+      @if test -n "$(TKDIR)" && test -d "$(TKDIR)" && test -f "$(TK_BUILD_TOP)/Makefile"; then \
-+          echo "TKDIR detected - automatically distcleaning Tk..."; \
-+          echo "Distcleaning Tk build..."; \
-+          (cd "$(TK_BUILD_TOP)" && $(MAKE) distclean) || exit $$?; \
-+      else \
-+          echo "TKDIR not set, directory does not exist, or no Tk build to distclean"; \
-+      fi
- #
- # Bundled package targets
--- 
-2.47.1.windows.2
-
diff --git a/adm/vcpkg/ports/tcl/force-shell-install.patch b/adm/vcpkg/ports/tcl/force-shell-install.patch
deleted file mode 100644 (file)
index 0725945..0000000
+++ /dev/null
@@ -1,27 +0,0 @@
-From 85842ba83b70d99f90ee3fff8c956e82d17759f2 Mon Sep 17 00:00:00 2001
-From: Marek Roszko <mark.roszko@gmail.com>
-Date: Tue, 18 Aug 2020 23:11:27 -0400
-Subject: [PATCH] Remove broken exist check for shell install
-
----
- win/makefile.vc | 2 --
- 1 file changed, 2 deletions(-)
-
-diff --git a/win/makefile.vc b/win/makefile.vc
-index f5d2f4a..6bffe32 100644
---- a/win/makefile.vc
-+++ b/win/makefile.vc
-@@ -869,10 +869,8 @@ install-binaries:
-       @$(CPY) "$(TCLLIB)" "$(BIN_INSTALL_DIR)\"
- !endif
-       @$(CPY) "$(TCLIMPLIB)" "$(LIB_INSTALL_DIR)\"
--!if exist($(TCLSH))
-       @echo Installing $(TCLSHNAME)
-       @$(CPY) "$(TCLSH)" "$(BIN_INSTALL_DIR)\"
--!endif
-       @echo Installing $(TCLSTUBLIBNAME)
-       @$(CPY) "$(TCLSTUBLIB)" "$(LIB_INSTALL_DIR)\"
--- 
-2.28.0.windows.1
-
index 2055f9025ce501e67af7c3c679a046d287b34a44..d46032ccd7b9c071ec07397703f87f7afcc6aca1 100644 (file)
@@ -5,15 +5,14 @@ vcpkg_from_sourceforge(
     FILENAME tcl8.6.16-src.tar.gz
     SHA512 434c92f8181fb8dca6bc065b0f1f5078779086f19adf008818c90a3108596c63465ef43e9f3c1cfb3d4151a9de244d0bf0e6ee5b40e714b1ddca4a78eb43050b
     PATCHES
-        0001-Add-tk-build.patch
-        0002-Add-setpath-target.patch
-        0003-Update-unix-build.patch
-        0004-Update-mingw-build.patch
+        0001-Support-Tk.patch
 )
 
 set(USE_TCL_TK OFF)
 
+set (TKDIR_WIN "")
 if ("tk" IN_LIST FEATURES)
+  set (TKDIR_WIN "TKDIR=../extra/tk.8.6.16-src")
   vcpkg_from_sourceforge(
       OUT_SOURCE_PATH TK_SOURCE_PATH
       REPO tcl/Tcl
@@ -81,7 +80,7 @@ if (VCPKG_TARGET_IS_WINDOWS AND NOT VCPKG_TARGET_IS_MINGW)
             ${TCL_BUILD_ARCH_STR}
             ${TCL_BUILD_STATS}
             ${TCL_BUILD_CHECKS}
-            TKDIR=../extra/tk.8.6.16-src
+            ${TKDIR_WIN}
         OPTIONS_DEBUG
             ${TCL_BUILD_OPTS},symbols,pdbs
             INSTALLDIR=${CURRENT_PACKAGES_DIR}/debug
@@ -102,20 +101,30 @@ else()
     if (VCPKG_TARGET_IS_MINGW)
         set (TCL_PROJECT_SUBPATH win)
     endif()
-    file(REMOVE "${SOURCE_PATH}/${TCL_PROJECT_SUBPATH}/configure")
+    file(REMOVE "${SOURCE_PATH}/${TCL_PROJECT_SUBPATH}/configure")
     # For MinGW and other Unix-like environments on Windows, use unix build path
     # MinGW can use either win/ (with MinGW-compatible Makefiles) or unix/ (with autotools)
     vcpkg_configure_make(
         SOURCE_PATH "${SOURCE_PATH}"
         PROJECT_SUBPATH ${TCL_PROJECT_SUBPATH}
-        OPTIONS
-            TKDIR=${SOURCE_PATH}/extra/tk.8.6.16-src
+        AUTOCONFIG
     )
 
-    vcpkg_install_make(
-        OPTIONS
-            TKDIR=${SOURCE_PATH}/extra/tk.8.6.16-src
-    )
+    # Build with explicit X11 paths for Tk when needed
+    if(USE_TCL_TK AND NOT VCPKG_TARGET_IS_WINDOWS)
+        vcpkg_build_make(
+            ENVIRONMENT 
+                "CPPFLAGS=-I${CURRENT_INSTALLED_DIR}/include"
+                "LDFLAGS=-L${CURRENT_INSTALLED_DIR}/lib"
+        )
+        vcpkg_install_make(
+            ENVIRONMENT 
+                "CPPFLAGS=-I${CURRENT_INSTALLED_DIR}/include" 
+                "LDFLAGS=-L${CURRENT_INSTALLED_DIR}/lib"
+        )
+    else()
+        vcpkg_install_make()
+    endif()
 
     vcpkg_fixup_pkgconfig()
 
diff --git a/adm/vcpkg/triplets/x64-linux-dynamic-release.cmake b/adm/vcpkg/triplets/x64-linux-dynamic-release.cmake
new file mode 100644 (file)
index 0000000..4b398c9
--- /dev/null
@@ -0,0 +1,9 @@
+set(VCPKG_TARGET_ARCHITECTURE x64)
+set(VCPKG_CRT_LINKAGE dynamic)
+set(VCPKG_LIBRARY_LINKAGE dynamic)
+
+set(VCPKG_CMAKE_SYSTEM_NAME Linux)
+
+set(VCPKG_FIXUP_ELF_RPATH ON)
+
+set(VCPKG_BUILD_TYPE "release")
index d3926351ae8478e8595bcd9e2e2f9e9c2bf99ca9..538de8425e4bf002374842a0bd40332aa6b7117f 100644 (file)
@@ -14,5 +14,8 @@
   ],
   "overlay-ports": [
     "./ports"
-   ]
-}
+  ],
+  "overlay-triplets": [
+    "./triplets"
+  ]
+}
\ No newline at end of file
index 43676d24e96cc135ca3baa9ff162e7fb42e90229..81e1829cf79cb3db6362a0f5afc908921f92c370 100644 (file)
   ],
   "features": {
     "angle": {
-      "description": "Enables optional usage of ANGLE. Part of the module-visualization.",
+      "description": "Enables optional usage of OpenGL ES 2.0. Part of the module-visualization.",
       "dependencies": [
-        "angle"
+        {
+          "name": "angle",
+          "platform": "!(linux & !static)"
+        }
       ]
     },
     "opengl": {
           "features": [
             "tk"
           ]
+        },
+        {
+          "name": "libx11",
+          "platform": "!windows"
         }
       ]
     },