We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
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
xmake v2.9.7+HEAD.2bb99e0c3
Windows 11 23H2
When generating CMakeLists.txt from xmake and building the project, the resulting file does not copy required libraries to the output directory.
CMakeLists.txt
xmake
The generated CMakeLists.txt should copy required libraries to the output directory.
xmake.lua:
add_rules("mode.debug", "mode.release") add_requires("fmt", {configs = {shared = true}}) target("test") set_kind("binary") add_files("main.cpp") add_packages("fmt", {public = true})
main.cpp:
#include <fmt/format.h> int main(int argc, char** argv) { fmt::print("Hello World!\n"); return 0; }
Adding this to CMakeLists.txt to copy the files to output directory fixes the issue.
add_custom_command(TARGET test POST_BUILD COMMAND ${CMAKE_COMMAND} -E copy "......./fmt.dll" $<TARGET_FILE_DIR:test> )
The text was updated successfully, but these errors were encountered:
This is not supported yet, only support for compilation.
Sorry, something went wrong.
No branches or pull requests
Xmake Version
xmake v2.9.7+HEAD.2bb99e0c3
Operating System Version and Architecture
Windows 11 23H2
Describe Bug
When generating
CMakeLists.txt
fromxmake
and building the project, the resulting file does not copy required libraries to the output directory.Expected Behavior
The generated
CMakeLists.txt
should copy required libraries to the output directory.Project Configuration
xmake.lua:
main.cpp:
Additional Information and Error Logs
Adding this to
CMakeLists.txt
to copy the files to output directory fixes the issue.The text was updated successfully, but these errors were encountered: