From 10:00 CET Friday 22nd November we will adjust how the server works to deal with some recently reported problems. Therefore there may be a load problem, if you experience more problems than usual trying to access the forum then please PM AndyS or any of the moderators so they can inform me.
qmake install error detection on Windows
Hi Guys, I'm facing an annoying deployment problem when using
Take this example .pro file:
target.path = C:/temp baseLibs.path = C:/temp baseLibs.files = "SomeConfigFile.xml" INSTALLS += baseLibs target
and that the target is
Now let's imagine I call
nmake installwhile I have
C:/temp/MyApp.exeopen. The result is that the target copy will fail but, since the xml file gets copied successfully make terminates with a success (errorlevel is 0).
Is there any way I can detect that error?
I already tried inverting the arguments to
INSTALLSbut it doesn't solve my problem
Since this is going to be a Windows specific issue, did you check the content of the Makefile regarding the install step ?
Yes, not much there:
INSTALL_FILE = copy /y install_target: first FORCE @if not exist $(INSTALL_ROOT)C:\temp mkdir $(INSTALL_ROOT)C:\temp & if not exist $(INSTALL_ROOT)C:\temp exit 1 -$(INSTALL_FILE) $(DESTDIR_TARGET) $(INSTALL_ROOT)C:\temp\$(TARGET) install_baseLibs: first FORCE @if not exist $(INSTALL_ROOT)C:\temp mkdir $(INSTALL_ROOT)C:\temp & if not exist $(INSTALL_ROOT)C:\temp exit 1 -$(INSTALL_FILE) SomeConfigFile.xml $(INSTALL_ROOT)C:\temp
Ideal scenario would be that I can check if any of those
What if you add the
Just a wild guess, but what if you add dependency of the one target to the other?
target.path = C:/temp baseLibs.path = C:/temp baseLibs.files = "SomeConfigFile.xml" target.depends = baseLibs
target.depends = baseLibs
This was a very promising idea but unfortunately it looks like
.dependsdoes not work with other