Description
When adding $(SolutionDir), which contains a trailing slash, to the include path, then this results in a build error.
This problem does not occur with the addin 1.1.3.
Steps to reproduce the problem:
1. Install add-in 1.1.5.
2. Open Visual studio.
3. Create new QT project witn GUI wizard.
4. In Project properties / C++ / General - Additional Include
Directories append $(SolutionDir)
5. Try to build project in VS.
The result is as follows:
1>------ Build started: Project: testProject, Configuration: Debug Win32
------
1>Rcc'ing testproject.qrc...
1>RCC: Warning: No resources in
'c\testProject\testProject\testproject.qrc'.
1>Moc'ing testproject.h...
1>standard input(0): Warning: No relevant classes found. No output
generated.
1>Uic'ing testproject.ui...
1>Compiling...
1>moc_testproject.cpp
1>c1xx : fatal error C1083: Cannot open source file:
'.\GeneratedFiles\Debug\moc_testproject.cpp': No such file or directory
1>testproject.cpp
1>main.cpp
1>Generating Code...
1>Build log was saved at
"file://c:\testProject\testProject\Debug\BuildLog.htm"
1>testProject - 1 error(s), 0 warning(s)
========== Build: 0 succeeded, 1 failed, 0 up-to-date, 0 skipped ==========
looking for moc command lien:
"C:\QT\4.6.3\bin\moc.exe" -D -DUNICODE -DWIN32
-DQT_LARGEFILE_SUPPORT -DQT_THREAD_SUPPORT -DQT_CORE_LIB -DQT_GUI_LIB
-I".\GeneratedFiles" -I"C:\QT\4.6.3\include"
-I".\GeneratedFiles\Debug" -I"C:\QT\4.6.3\include\qtmain"
-I"C:\QT\4.6.3.\include\QtCore" -I"C:\QT\4.6.3\include\QtGui"
-I"." -I"C:\\testProject\testProject\" ".\testproject.h" -o
".\GeneratedFiles\Debug\moc_testproject.cpp"
Try to remove $(SolutionDir) Additional Include Directories append.
And see log:
...
========== Build: 1 succeeded, 0 failed, 0 up-to-date, 0 skipped ==========
and mocing command line:
"C:\QT\4.6.3\bin\moc.exe" -D -DUNICODE -DWIN32
-DQT_LARGEFILE_SUPPORT -DQT_THREAD_SUPPORT -DQT_CORE_LIB -DQT_GUI_LIB
-I".\GeneratedFiles" -I"C:\QT\4.6.3\include"
-I".\GeneratedFiles\Debug" -I"C:\QT\4.6.3\include\qtmain"
-I"C:\QT\4.6.3\include\QtCore" -I"C:\QT\4.6.3\include\QtGui"
-I"." ".\testproject.h" -o ".\GeneratedFiles\Debug\moc_testproject.cpp"
The same scenario for add-in version 1.1.3 work fine and command line
for moc is:
"C:\QT\4.6.3\bin\moc.exe"
"c:\testProject\testProject\testproject.h" -o
".\GeneratedFiles\Debug\moc_testproject.cpp" -D -DQT_CORE_LIB
-DQT_GUI_LIB -DQT_LARGEFILE_SUPPORT -DQT_THREAD_SUPPORT -DUNICODE
-DWIN32 -I"C:\QT\4.6.3\include\."
-I"C:\QT\4.6.3\include\QtCore\." -I"C:\QT\4.6.3\include\QtGui\."
-I"C:\QT\4.6.3\include\qtmain\."
-I"D:\Work\testProject\testProject
." -I".\."
-I".\GeneratedFiles\Debug\." -I".\GeneratedFiles\
Attachments
Issue Links
- Is tested by
-
QTVSADDINBUG-244 Qt4VSAddin: add autotest for include paths with trailing backslashes
-
- Closed
-