@ceanwang Sorry, but you are wrong. The FLTK test/CMakeLists.txt file does not use '../' in any way. The code you're seeing that uses the relative directory is generated by CMake. And since you're using the "Unix Makefiles " generator you're implicitly saying that you want to build with a Unix (POSIX) environment that allows '../' relative directory syntax.
As a proof, here's the relevant code that runs the fluid executable from CMake/FLTK-Functions.cmake :
add_custom_command(
OUTPUT "${basename}.cxx" "${basename}.h"
COMMAND fluid -c ${CMAKE_CURRENT_SOURCE_DIR}/${src}
DEPENDS ${src}
MAIN_DEPENDENCY ${src}
)
The key is the line COMMAND fluid -c ${CMAKE_CURRENT_SOURCE_DIR}/${src} which invokes the CMake target fluid to generate the .cxx and .h files from the .fl file. As you can clearly see there's no '../' in this cmake file (the code is in a macro). The execution code is definitely generated by CMake.
As I wrote before, please use a MinGW or MSYS terminal which should be available in your install. Here's a screenshot from my Windows 10 system:
I clicked on the icon labeled 'M2' (which stands for MSYS2) and you see the popup from which I selected Mingw-w64 64 bit to do the build in my environment (64 bit Windows) and this works flawlessly. You can be sure that I tested this! However, the menus may be different, depending how you installed the MinGW-w64 environment.
— You are receiving this because you are subscribed to this thread. Reply to this email directly, view it on GitHub, or unsubscribe.
[ Direct Link to Message ] |