-
Notifications
You must be signed in to change notification settings - Fork 6.4k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[libmodplug] Patch CMakeLists.txt to fix install paths #21381
Conversation
whenever you touch a |
Understood, I believe I have done this now. |
you did everything in one commit and it’s not valid. You should have first committed your patches with the port version bump, then another commit with the modifications after running vcpkg x-add-versions |
164ec44
to
4c5bfed
Compare
Alright. How is it now? |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
You have modified or added at least one portfile where deprecated functions are used.
If you feel able to do so, please consider migrating them to the new functions:
vcpkg_install_cmake
-> vcpkg_cmake_install
(from port vcpkg-cmake
)
vcpkg_build_cmake
-> vcpkg_cmake_build
(from port vcpkg-cmake
)
vcpkg_configure_cmake
-> vcpkg_cmake_configure
(Please remove the option PREFER_NINJA
) (from port vcpkg-cmake
)
vcpkg_fixup_cmake_targets
-> vcpkg_cmake_config_fixup
(from port vcpkg-cmake-config
)
In the ports that use the new function, you have to add the corresponding dependencies:
{
"name": "vcpkg-cmake",
"host": true
},
{
"name": "vcpkg-cmake-config",
"host": true
}
The following files are affected:
ports/libmodplug/portfile.cmake
4c5bfed
to
108416c
Compare
Made requested changes. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
You have modified or added at least one portfile where deprecated functions are used.
If you feel able to do so, please consider migrating them to the new functions:
vcpkg_install_cmake
-> vcpkg_cmake_install
(from port vcpkg-cmake
)
vcpkg_build_cmake
-> vcpkg_cmake_build
(from port vcpkg-cmake
)
vcpkg_configure_cmake
-> vcpkg_cmake_configure
(Please remove the option PREFER_NINJA
) (from port vcpkg-cmake
)
vcpkg_fixup_cmake_targets
-> vcpkg_cmake_config_fixup
(from port vcpkg-cmake-config
)
In the ports that use the new function, you have to add the corresponding dependencies:
{
"name": "vcpkg-cmake",
"host": true
},
{
"name": "vcpkg-cmake-config",
"host": true
}
The following files are affected:
ports/libmodplug/portfile.cmake
Normally we make those changes with the port update / port feature / other port bug. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
You have modified or added at least one portfile where deprecated functions are used.
If you feel able to do so, please consider migrating them to the new functions:
vcpkg_install_cmake
-> vcpkg_cmake_install
(from port vcpkg-cmake
)
vcpkg_build_cmake
-> vcpkg_cmake_build
(from port vcpkg-cmake
)
vcpkg_configure_cmake
-> vcpkg_cmake_configure
(Please remove the option PREFER_NINJA
) (from port vcpkg-cmake
)
vcpkg_fixup_cmake_targets
-> vcpkg_cmake_config_fixup
(from port vcpkg-cmake-config
)
In the ports that use the new function, you have to add the corresponding dependencies:
{
"name": "vcpkg-cmake",
"host": true
},
{
"name": "vcpkg-cmake-config",
"host": true
}
The following files are affected:
ports/libmodplug/portfile.cmake
Describe the pull request
What does your PR fix?
Implements CMake: Fix install paths on Windows Konstanty/libmodplug#61 which fixes a bug in the CMakeLists.txt where DLL files are erroneously installed to the
lib
folder rather thanbin
. Currently theportfile.cmake
attempts to workaround this by manually renaming the files post-installation, but this is clunky (considering the filename has to be hardcoded), and will also fail if the user is installing only a release OR debug build (since both rename commands are hardcoded and CMake will throw a "file not found" error if they don't both exist).By patching the CMakeLists.txt, this is solved at the root of the problem. DLLs are correctly installed to
bin
in the first place (while other library/linking files are still correctly installed tolib
). The CMake documentation recommends this solution towards the end of the "Installing Targets" section here: https://cmake.org/cmake/help/latest/command/install.html#installing-targetsWhich triplets are supported/not supported? Have you updated the CI baseline?
All triplets are supported. This patch corrects Win32 issues without breaking other platforms.
Does your PR follow the maintainer guide?
I believe it does. In my opinion, this is a very small and readable patch that I believe will be easy to review. I also believe it makes no extraneous/trivial changes and is the code I am using is fairly well-documented.
If you have added/updated a port: Have you run
./vcpkg x-add-version --all
and committed the result?Yes.
If you are still working on the PR, open it as a Draft: https://github.blog/2019-02-14-introducing-draft-pull-requests/