Skip to content

[vcpkg baseline] [qtbase] Update the hash of qtinterfaceframework#21909

Closed
PhoebeHui wants to merge 2 commits intomicrosoft:masterfrom
PhoebeHui:dev/Phoebe/qtinterfaceframework
Closed

[vcpkg baseline] [qtbase] Update the hash of qtinterfaceframework#21909
PhoebeHui wants to merge 2 commits intomicrosoft:masterfrom
PhoebeHui:dev/Phoebe/qtinterfaceframework

Conversation

@PhoebeHui
Copy link
Contributor

Related to #20439

qtinterfaceframework:x64-windows failed in CI testing.
Failures:
error: Server does not allow request for unadvertised object 118fa138186144cf2d802405255f08662ed76d43

@PhoebeHui PhoebeHui added category:port-bug The issue is with a library, which is something the port should already support info:internal labels Dec 8, 2021
@PhoebeHui
Copy link
Contributor Author

cc @Neumann-A

Copy link

@github-actions github-actions bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This is a new experimental fast check for PR issues. Please let us know if this bot is helpful!

After committing all other changes, the version database must be updated
git add -u && git commit
git checkout 7bb175eafedb203f19b18cf211666ec728c7461a -- versions
./vcpkg x-add-version --all
Diff
diff --git a/versions/baseline.json b/versions/baseline.json
index d91e4e8..066a56c 100644
--- a/versions/baseline.json
+++ b/versions/baseline.json
@@ -5698,7 +5698,7 @@
     },
     "qtbase": {
       "baseline": "6.2.2",
-      "port-version": 0
+      "port-version": 1
     },
     "qtcharts": {
       "baseline": "6.2.2",
diff --git a/versions/q-/qtbase.json b/versions/q-/qtbase.json
index ce35abd..33bf392 100644
--- a/versions/q-/qtbase.json
+++ b/versions/q-/qtbase.json
@@ -1,5 +1,10 @@
 {
   "versions": [
+    {
+      "git-tree": "b589c663257547e0ae21fd71d6502c8905d90a5b",
+      "version-semver": "6.2.2",
+      "port-version": 1
+    },
     {
       "git-tree": "c314a6af00c3a57bbd887c834cc0b5f80bfd65fc",
       "version-semver": "6.2.2",

@Neumann-A
Copy link
Contributor

I think this won't work. you need to pass FETCH_REF to vcpkg_from_git for the qt ports without tags. The shallow fetch is not working.

@PhoebeHui
Copy link
Contributor Author

PhoebeHui commented Dec 8, 2021

I tried this locally, it works. I get it from https://code.qt.io/cgit/qt/qtinterfaceframework.git/commit/?h=6.2.2&id=c39926232ee04ded0ebbe971aeb047b6d92ee4d8

Starting package 1/1: qtinterfaceframework:x64-windows
Building package qtinterfaceframework[core]:x64-windows...
[DEBUG] CreateProcessW("C:\Program Files\CMake\bin\cmake.exe" -DALL_FEATURES= -DCURRENT_PORT_DIR=E:/vcpkg/src/vcpkg/ports/qtinterfaceframework -D_HOST_TRIPLET=x64-windows -DFEATURES=core -DPORT=qtinterfaceframework -DVCPKG_USE_HEAD_VERSION=0 -D_VCPKG_DOWNLOAD_TOOL=BUILT_IN -D_VCPKG_EDITABLE=0 -D_VCPKG_NO_DOWNLOADS=0 -DCMD=BUILD -DDOWNLOADS=E:/vcpkg/src/vcpkg/downloads -DTARGET_TRIPLET=x64-windows -DTARGET_TRIPLET_FILE=E:/vcpkg/src/vcpkg/triplets/x64-windows.cmake -DVCPKG_BASE_VERSION=2021-11-24 -DVCPKG_CONCURRENCY=9 -DVCPKG_PLATFORM_TOOLSET=v142 -DGIT=E:/vcpkg/src/vcpkg/downloads/tools/git-2.32.0.2-windows/mingw32/bin/git.exe -DVCPKG_ROOT_DIR=E:/vcpkg/src/vcpkg -DPACKAGES_DIR=E:/vcpkg/src/vcpkg/packages -DBUILDTREES_DIR=E:/vcpkg/src/vcpkg/buildtrees -D_VCPKG_INSTALLED_DIR=E:/vcpkg/src/vcpkg/installed -DDOWNLOADS=E:/vcpkg/src/vcpkg/downloads -DVCPKG_MANIFEST_INSTALL=OFF -P "E:\vcpkg\src\vcpkg\scripts\ports.cmake")
-- Fetching https://code.qt.io/qt/qtinterfaceframework.git c39926232ee04ded0ebbe971aeb047b6d92ee4d8...
-- Extracting source E:/vcpkg/src/vcpkg/downloads/qtinterfaceframework-c39926232ee04ded0ebbe971aeb047b6d92ee4d8.tar.gz
-- Applying patch fix-taglib-search.patch
-- Using source at E:/vcpkg/src/vcpkg/buildtrees/qtinterfaceframework/src/b6d92ee4d8-fe0ad2c164.clean
-- Using cached msys-mingw-w64-i686-pkg-config-0.29.2-2-any.pkg.tar.zst.
-- Using cached msys-mingw-w64-i686-libwinpthread-git-8.0.0.5906.c9a21571-1-any.pkg.tar.zst.
-- Using msys root at E:/vcpkg/src/vcpkg/downloads/tools/msys2/aa5af7b2aa7e90e8
-- Downloading https://github.com/pypa/get-pip/archive/309a56c5fd94bd1134053a541cb4657a4e47e09d.tar.gz -> pypa-get-pip-309a56c5fd94bd1134053a541cb4657a4e47e09d.tar.gz...
-- Extracting source E:/vcpkg/src/vcpkg/downloads/pypa-get-pip-309a56c5fd94bd1134053a541cb4657a4e47e09d.tar.gz
-- Using source at E:/vcpkg/src/vcpkg/buildtrees/qtinterfaceframework/src/7a4e47e09d-f4730c06c6.clean
Collecting pip
  Downloading https://files.pythonhosted.org/packages/a4/6d/6463d49a933f547439d6b5b98b46af8742cc03ae83543e4d7688c2420f8b/pip-21.3.1-py3-none-any.whl (1.7MB)
Collecting setuptools
  Downloading https://files.pythonhosted.org/packages/40/a9/7deac76c58fa47c95360116a06b53b9b62f6db11336fe61b6ab53784d98b/setuptools-59.5.0-py3-none-any.whl (952kB)
Collecting wheel
  Downloading https://files.pythonhosted.org/packages/04/80/cad93b40262f5d09f6de82adbee452fd43cdff60830b56a74c5930f7e277/wheel-0.37.0-py2.py3-none-any.whl
Installing collected packages: pip, setuptools, wheel
Successfully installed pip-21.3.1 setuptools-59.5.0 wheel-0.37.0
Collecting virtualenv
  Downloading virtualenv-20.10.0-py2.py3-none-any.whl (5.6 MB)
Collecting platformdirs<3,>=2
  Downloading platformdirs-2.4.0-py3-none-any.whl (14 kB)
Collecting six<2,>=1.9.0
  Downloading six-1.16.0-py2.py3-none-any.whl (11 kB)
Collecting distlib<1,>=0.3.1
  Downloading distlib-0.3.3-py2.py3-none-any.whl (496 kB)
Collecting backports.entry-points-selectable>=1.0.4
  Downloading backports.entry_points_selectable-1.1.1-py2.py3-none-any.whl (6.2 kB)
Collecting filelock<4,>=3.2
  Downloading filelock-3.4.0-py3-none-any.whl (9.8 kB)
Installing collected packages: six, platformdirs, filelock, distlib, backports.entry-points-selectable, virtualenv
Successfully installed backports.entry-points-selectable-1.1.1 distlib-0.3.3 filelock-3.4.0 platformdirs-2.4.0 six-1.16.0 virtualenv-20.10.0
Collecting qface
  Downloading qface-2.0.5-2-py3-none-any.whl (41 kB)
Collecting path.py>=11.0.1
  Downloading path.py-12.5.0-py3-none-any.whl (2.3 kB)
Collecting click>=6.7
  Downloading click-8.0.3-py3-none-any.whl (97 kB)
Collecting typing>=3.6.4
  Downloading typing-3.7.4.3.tar.gz (78 kB)
  Preparing metadata (setup.py): started
  Preparing metadata (setup.py): finished with status 'done'
Collecting jinja2>=2.10.3
  Downloading Jinja2-3.0.3-py3-none-any.whl (133 kB)
Collecting antlr4-python3-runtime>=4.7.1
  Downloading antlr4-python3-runtime-4.9.3.tar.gz (117 kB)
  Preparing metadata (setup.py): started
  Preparing metadata (setup.py): finished with status 'done'
Collecting coloredlogs>=10.0
  Downloading coloredlogs-15.0.1-py2.py3-none-any.whl (46 kB)
Requirement already satisfied: six>=1.11.0 in e:\vcpkg\src\vcpkg\downloads\tools\python\python-3.10.0-x64\lib\site-packages (from qface) (1.16.0)
Collecting watchdog>=0.8.3
  Downloading watchdog-2.1.6-py3-none-win_amd64.whl (76 kB)
Collecting pyyaml>=5.1
  Downloading PyYAML-6.0-cp310-cp310-win_amd64.whl (151 kB)
Collecting colorama
  Downloading colorama-0.4.4-py2.py3-none-any.whl (16 kB)
Collecting humanfriendly>=9.1
  Downloading humanfriendly-10.0-py2.py3-none-any.whl (86 kB)
Collecting MarkupSafe>=2.0
  Downloading MarkupSafe-2.0.1-cp310-cp310-win_amd64.whl (15 kB)
Collecting path
  Downloading path-16.2.0-py3-none-any.whl (21 kB)
Collecting pyreadline3
  Downloading pyreadline3-3.3-py3-none-any.whl (95 kB)
Building wheels for collected packages: antlr4-python3-runtime, typing
  Building wheel for antlr4-python3-runtime (setup.py): started
  Building wheel for antlr4-python3-runtime (setup.py): finished with status 'done'
  Created wheel for antlr4-python3-runtime: filename=antlr4_python3_runtime-4.9.3-py3-none-any.whl size=144575 sha256=62b79df6277932e26163e5b30e7ef60eca3dc37e868483e360c09bca84c11f22
  Stored in directory: c:\users\v-phma.fareast\appdata\local\pip\cache\wheels\12\93\dd\1f6a127edc45659556564c5730f6d4e300888f4bca2d4c5a88
  Building wheel for typing (setup.py): started
  Building wheel for typing (setup.py): finished with status 'done'
  Created wheel for typing: filename=typing-3.7.4.3-py3-none-any.whl size=26324 sha256=fc0909db91fd77868407f8e6748030c671244d11d923750090e2d82f3f4a8e76
  Stored in directory: c:\users\v-phma.fareast\appdata\local\pip\cache\wheels\7c\d0\9e\1f26ebb66d9e1732e4098bc5a6c2d91f6c9a529838f0284890
Successfully built antlr4-python3-runtime typing
Installing collected packages: pyreadline3, path, MarkupSafe, humanfriendly, colorama, watchdog, typing, pyyaml, path.py, jinja2, coloredlogs, click, antlr4-python3-runtime, qface
Successfully installed MarkupSafe-2.0.1 antlr4-python3-runtime-4.9.3 click-8.0.3 colorama-0.4.4 coloredlogs-15.0.1 humanfriendly-10.0 jinja2-3.0.3 path-16.2.0 path.py-12.5.0 pyreadline3-3.3 pyyaml-6.0 qface-2.0.5 typing-3.7.4.3 watchdog-2.1.6
-- Configuring x64-windows
CMake Warning at scripts/cmake/vcpkg_configure_cmake.cmake:410 (message):
  The following variables are not used in CMakeLists.txt:

      INPUT_debug
      INSTALL_TRANSLATIONSDIR
      QT_NO_MAKE_EXAMPLES
      QT_NO_MAKE_TESTS

  Please recheck them and remove the unnecessary options from the
  `vcpkg_configure_cmake` call.

  If these options should still be passed for whatever reason, please use the
  `MAYBE_UNUSED_VARIABLES` argument.
Call Stack (most recent call first):
  installed/x64-windows/share/qtbase/qt_install_submodule.cmake:87 (vcpkg_configure_cmake)
  ports/qtinterfaceframework/portfile.cmake:80 (qt_cmake_configure)
  scripts/ports.cmake:142 (include)


-- Building x64-windows-dbg
-- Building x64-windows-rel
-- Installing: E:/vcpkg/src/vcpkg/packages/qtinterfaceframework_x64-windows/share/qtinterfaceframework/copyright
[DEBUG] cmd_execute_and_stream_data() returned 0 after 264076452 us
-- Performing post-build validation
...
-- Performing post-build validation done
...
Stored binary cache: C:\Users\phoebe\AppData\Local\vcpkg\archives\02\024b1740c45662b081a592cb8279cf6206e00ad34bb77e3239e68e2aec4072f4.zip
Installing package qtinterfaceframework[core]:x64-windows...
Elapsed time for package qtinterfaceframework:x64-windows: 4.533 min

Total elapsed time: 4.642 min

The package qtinterfaceframework provides CMake targets:

    find_package(QmlPlugins CONFIG REQUIRED)
    target_link_libraries(main PRIVATE Qt6::qtifmediaplugin Qt6::qtifvehiclefunctionsplugin Qt6::qtinterfaceframeworkplugin)

    find_package(Qt6 CONFIG REQUIRED)
    target_link_libraries(main PRIVATE WrapSystemTagLib::WrapSystemTagLib)

    find_package(Qt6IfMedia CONFIG REQUIRED)
    target_link_libraries(main PRIVATE Qt::IfMedia Qt6::IfMedia Qt::IfMediaPrivate Qt6::IfMediaPrivate)

    find_package(Qt6IfRemoteObjectsHelperPrivate CONFIG REQUIRED)
    target_link_libraries(main PRIVATE Qt::IfRemoteObjectsHelperPrivate Qt6::IfRemoteObjectsHelperPrivate)

    find_package(Qt6IfVehicleFunctions CONFIG REQUIRED)
    target_link_libraries(main PRIVATE Qt::IfVehicleFunctions Qt6::IfVehicleFunctions Qt::IfVehicleFunctionsPrivate Qt6::IfVehicleFunctionsPrivate)

    find_package(Qt6InterfaceFramework CONFIG REQUIRED)
    # Note: 5 target(s) were omitted.
    target_link_libraries(main PRIVATE Qt6::MediaPlugin Qt6::TunerPlugin Qt6::MediaQtROPlugin Qt6::VehicleQtROPlugin)

@Neumann-A
Copy link
Contributor

@PhoebeHui the update of the ref will work until the branch is pushed to again. Looking at the history this might happend within the next 7 days.

@PhoebeHui
Copy link
Contributor Author

I added 'FETCH_REF 6.2.2' to https://github.com/microsoft/vcpkg/blob/master/ports/qtbase/cmake/qt_install_submodule.cmake#L35, and test it, it fails with 'fatal: not a tree object: 118fa138186144cf2d802405255f08662ed76d43'

@Neumann-A
Copy link
Contributor

Neumann-A commented Dec 8, 2021

@PhoebeHui:
FETCH_REF only needs to be added to the ports mentioned here:

if(PORT MATCHES "qtdeviceutilities|qtlocation|qtinterfaceframework|qtapplicationmanager")

The object is:
https://code.qt.io/cgit/qt/qtinterfaceframework.git/commit/?h=6.2.2&id=118fa138186144cf2d802405255f08662ed76d43
maybe the ref needs to be changed to 8b036f1626d0a0fccdebe9548606dfcd1242fe76 which is the tree.

@PhoebeHui
Copy link
Contributor Author

@Neumann-A, I also tried 8b036f1626d0a0fccdebe9548606dfcd1242fe76, it failed with 'fatal: not a tree object: 8b036f1626d0a0fccdebe9548606dfcd1242fe76'

@Neumann-A
Copy link
Contributor

vcpkg install with --x-cmake-args=--trace-expand and post the vcpkg log for it. Maybe the scripts are not doing what they should.

@PhoebeHui
Copy link
Contributor Author

PhoebeHui commented Dec 8, 2021

This is trace log for origin problems: trace.log

Here is trace log when pass FETCH_REF 6.2.2 to vcpkg_from_git:
FETCH_REF_trace.log

@Neumann-A
Copy link
Contributor

vcpkg_execute_required_process(ALLOW_IN_DOWNLOAD_MODE COMMAND E:/vcpkg/src/vcpkg/downloads/tools/git-2.32.0.2-windows/mingw32/bin/git.exe fetch https://code.qt.io/qt/qtinterfaceframework.git 118fa138186144cf2d802405255f08662ed76d43 --depth;1 -n WORKING_DIRECTORY E:/vcpkg/src/vcpkg/downloads/git-tmp LOGNAME git-fetch-x64-windows )

still tries to do a shallow checkout which won't work.

E:/vcpkg/src/vcpkg/scripts/cmake/vcpkg_from_git.cmake(97):  if(DEFINED arg_FETCH_REF )
E:/vcpkg/src/vcpkg/installed/x64-windows/share/qtbase/qt_install_submodule.cmake(100):  else()
E:/vcpkg/src/vcpkg/scripts/cmake/vcpkg_from_git.cmake(101):  set(ref_to_use 118fa138186144cf2d802405255f08662ed76d43 )

seems like FETCH_REF is not set. Did you modify the installed/share/qtbase script or the script in ports/? Modifying the installed script is necessary if you want to have the effect without reinstallation of qtbase

@PhoebeHui
Copy link
Contributor Author

I modified the installed/share/qtbase/qt_port_details.cmake and share/qtbase/qt_install_submodule.cmake.

@Neumann-A
Copy link
Contributor

I modified the installed/share/qtbase/qt_port_details.cmake and share/qtbase/qt_install_submodule.cmake.

I think you will need to manually run the git steps in a folder and figure out whats wrong with vcpkg_from_git or to be more precise with the archiving step. It seems like the checkout just worked. Maybe @strega-nil can help here.

@Neumann-A
Copy link
Contributor

Also If i run

git init
git fetch https://code.qt.io/qt/qtinterfaceframework.git 6.2.2  -n
git archive 118fa138186144cf2d802405255f08662ed76d43 -o qtinterfaceframework-6.2.2.tar.gz

in my git bash it just works.

This should be equivalent to vcpkg doing:

execute_process(COMMAND;E:/vcpkg/src/vcpkg/downloads/tools/git-2.32.0.2-windows/mingw32/bin/git.exe;init;E:/vcpkg/src/vcpkg/downloads/git-tmp;OUTPUT_FILE;E:/vcpkg/src/vcpkg/buildtrees/qtinterfaceframework/git-init-x64-windows-out.log;ERROR_FILE;E:/vcpkg/src/vcpkg/buildtrees/qtinterfaceframework/git-init-x64-windows-err.log;WORKING_DIRECTORY;E:/vcpkg/src/vcpkg/buildtrees/qtinterfaceframework   RESULT_VARIABLE;result_var  )
execute_process(COMMAND;E:/vcpkg/src/vcpkg/downloads/tools/git-2.32.0.2-windows/mingw32/bin/git.exe;fetch;https://code.qt.io/qt/qtinterfaceframework.git;6.2.2;-n;OUTPUT_FILE;E:/vcpkg/src/vcpkg/buildtrees/qtinterfaceframework/git-fetch-x64-windows-out.log;ERROR_FILE;E:/vcpkg/src/vcpkg/buildtrees/qtinterfaceframework/git-fetch-x64-windows-err.log;WORKING_DIRECTORY;E:/vcpkg/src/vcpkg/downloads/git-tmp   RESULT_VARIABLE;result_var  )
execute_process(COMMAND;E:/vcpkg/src/vcpkg/downloads/tools/git-2.32.0.2-windows/mingw32/bin/git.exe;rev-parse;118fa138186144cf2d802405255f08662ed76d43;WORKING_DIRECTORY;E:/vcpkg/src/vcpkg/downloads/git-tmp OUTPUT_VARIABLE;out_err_var ERROR_VARIABLE;out_err_var RESULT_VARIABLE;result_var  )
execute_process(COMMAND;E:/vcpkg/src/vcpkg/downloads/tools/git-2.32.0.2-windows/mingw32/bin/git.exe;archive;118fa138186144cf2d802405255f08662ed76d43;-o;E:/vcpkg/src/vcpkg/downloads/temp/qtinterfaceframework-6.2.2.tar.gz;OUTPUT_FILE;E:/vcpkg/src/vcpkg/buildtrees/qtinterfaceframework/git-archive-out.log;ERROR_FILE;E:/vcpkg/src/vcpkg/buildtrees/qtinterfaceframework/git-archive-err.log;WORKING_DIRECTORY;E:/vcpkg/src/vcpkg/downloads/git-tmp   RESULT_VARIABLE;result_var  )

@PhoebeHui
Copy link
Contributor Author

PhoebeHui commented Dec 8, 2021

Thanks @Neumann-A for taking look at this issue, I also could fetch the source successfully locally.

cc @BillyONeal

@Neumann-A
Copy link
Contributor

seems like #21925 works.

@PhoebeHui
Copy link
Contributor Author

Closing in favor of #21925.

@PhoebeHui PhoebeHui closed this Dec 8, 2021
@PhoebeHui PhoebeHui reopened this Dec 9, 2021
@PhoebeHui
Copy link
Contributor Author

PhoebeHui commented Dec 9, 2021

After I deleted "E:\vcpkg\src\vcpkg\downloads\git-tmp.git\shallow" in my local machine, this issue has gone. The source file fetched successfully.

@PhoebeHui PhoebeHui closed this Dec 9, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

category:port-bug The issue is with a library, which is something the port should already support

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants