Repository navigation
Closed
Labels
Description
The windows nightlies have been failing to compile for the last two days, and I've just now had time to take a look.
The problem seems to be a change in the CMakeLists.txt:
C:\git_repos\sqlitebrowser\release-sqlite-win32>cmake -G "Visual Studio 12 2013" -Wno-dev .. 1>>C:\\dev\\nightlies.log
CMake Error at CMakeLists.txt:353 (add_executable):
The target name "DB Browser for SQLite" is reserved or not valid for
certain CMake features, such as generator expressions, and may result in
undefined behavior.
CMake Error at CMakeLists.txt:361 (add_dependencies):
Cannot add target-level dependencies to non-existent target "DB Browser for
SQLite".
The add_dependencies works for top-level logical targets created by the
add_executable, add_library, or add_custom_target commands. If you want to
add file-level dependencies see the DEPENDS option of the add_custom_target
and add_custom_command commands.
CMake Error at CMakeLists.txt:363 (add_dependencies):
Cannot add target-level dependencies to non-existent target "DB Browser for
SQLite".
The add_dependencies works for top-level logical targets created by the
add_executable, add_library, or add_custom_target commands. If you want to
add file-level dependencies see the DEPENDS option of the add_custom_target
and add_custom_command commands.
CMake Error at CMakeLists.txt:366 (add_dependencies):
Cannot add target-level dependencies to non-existent target "DB Browser for
SQLite".
The add_dependencies works for top-level logical targets created by the
add_executable, add_library, or add_custom_target commands. If you want to
add file-level dependencies see the DEPENDS option of the add_custom_target
and add_custom_command commands.
CMake Error at CMakeLists.txt:382 (target_link_libraries):
Cannot specify link libraries for target "DB Browser for SQLite" which is
not built by this project.
The line numbers given don't seem to match up to any recent CMakeLists.txt change, so I'm not 100% sure what the problem is. Possibly related to 961141e though, as that change matches up with the start of the compile failure.
Anyone have ideas on what to try?
Activity
MKleusberg commentedon Jul 12, 2018
I think this is because of the spaces in the project name. Because we changed the cmake version from 2.x to 3.x this new policy is taking effect now. The other OSs didn't produce errors because the project name there is sqlitebrowser, without any spaces.
Shall we rename the project to
DB_Browser_for_SQLiteor back tosqlitebrowseron Windows?justinclift commentedon Jul 12, 2018
I guess we'll have to. We'll need to ensure the final resulting binary gets renamed to "DB Browser for SQLite.exe", but that might just mean adding a manual rename step somewhere appropriate. 😄
Fix cmake build on Windows
MKleusberg commentedon Jul 12, 2018
Looks like there is a way to have different names for the project and the executable in cmake. Let's try if that works - I've just pushed a commit for this 😄
justinclift commentedon Jul 12, 2018
Just kicked off a new nightly build manually to see if it works... and it's still erroring out. Just the one failure this time though:
justinclift commentedon Jul 12, 2018
Hmmm, I wonder if something like this will work?
I'll give that a go in a temp branch, and see what happens.
justinclift commentedon Jul 12, 2018
Hmmm, well that doesn't error out with CMake now, but it's still not happy. Still investigating.
As an aside, this error is showing up in the MSVC console now when compiling manually through MSVC:
Looks to be with the commit for silencing the clang warning the other day.
justinclift commentedon Jul 12, 2018
Ahhh, yep. That clang suppression line is definitely breaking the build. Just tested things without it, and the compile happens... although the output name is still getting done as "sqlitebrowser.exe" atm. Working on solving that next.
justinclift commentedon Jul 13, 2018
Initial working fix in 9a76537. I'll wait to see the nightly build fully run successfully by itself before closing this though. 😄
justinclift commentedon Jul 13, 2018
Well, it's partially working now. The 32-bit Windows builds all seemed to work, but the 64-bit Windows .msi's didn't. I'm pretty sure it's due to some tweaks I was making in the build script on the server (manual file renaming in the script), rather than a code problem.
Investigating now.
justinclift commentedon Jul 13, 2018
Turned out I'd just forgotten to update the new Qt path in the msi building bit. That's now, done.
The 64-bit .exe's being generated though aren't good. Weirdly, it appears to be a problem with Win7's dos based COPY command. Copying the "good" win64 .exe from one location to the eventual dir it's uploaded from is resulting in only the first few mb of the file being copied to the destination file. Consistently. Seen this one before, and the work was to copy it to a temp location using a slightly different method, then doing a 2nd copy to get it to the right spot. That's not working this time. Bizarre. Still investigating for a workaround.
justinclift commentedon Jul 13, 2018
Oops, no. It's not the copy going wrong for the 64 bit ones. Something else is wrong before that... when trying to run the 3MB Win64 .exe, it complains about missing Qt .dll's. Looks like they're not getting included for some unknown reason.
I'll drop back to Qt 5.7 for the 64-bit too, and see if the behaviour changes.
justinclift commentedon Jul 13, 2018
No change. Doesn't seem to be caused by the Qt version.
Instead of spending further hours trying to figure this out, let's just drop the .exe's. We'd been planning to move to .msi's only anyway.
justinclift commentedon Jul 13, 2018
k, things seem to be working acceptably now (.msi's only). For Windows 32-bit, the Qt version is still 5.7. For the 64-bit version, we're now using 5.10.1.
9 remaining items
justinclift commentedon Jul 15, 2018
@jungle-boogie @karim Would you have time to check today's nightlie's again? They're now rebuilt using Qt 5.9, so it'll be interesting to see if that makes a difference. 😄
karim commentedon Jul 15, 2018
Latest nightly (Qt 5.9.6) fixed the GUI look, but not the network error.
justinclift commentedon Jul 15, 2018
Thanks, that's useful info. I'll drop it back to Qt 5.8, and we can see if the network error still shows up.
Looks like it's not a "Must use OpenSSL 1.1" thing then too.
karim commentedon Jul 15, 2018
One odd thing with July 15 build is this..
The right side where you can have SQL log, Plot, and DB Schema is always there. In earlier version, if you are not using/showing them it would stretch the main view to the whole window, like this..
First screenshot is July 15 build (Qt 5.9.6). Second screenshot is July 14 (Qt 5.10.1).
Edit: To make that grey area go away you have to show a view in it (SQL log or DB Schema for example) then slightly resize it then close, and it will disappear. If you show it without resizing it will not disappear.
justinclift commentedon Jul 15, 2018
Weird. Kind of seems like a Qt 5.9 bug, as that doesn't happen with 5.7 nor 5.10.1.
justinclift commentedon Jul 15, 2018
k, new Windows nightlies have just been uploaded. These ones are based on Qt 5.8.
MKleusberg commentedon Jul 15, 2018
The style seems like it's easy enough to fix: we probably only need to add the
styles\qwindowsvistastyle.dllfile to the plugin directory. See here and here.justinclift commentedon Jul 15, 2018
Cool. 😄
I'm kind of suspecting the network error dialog might be caused by some missing new Qt dll too. 😄
jungle-boogie commentedon Jul 16, 2018
With 16 July download, I cannot open DB Browser:
The program can't start because Qt5Network.dll is missing from your computer. Try reinstalling the program to fix this problem.
jungle-boogie commentedon Jul 16, 2018
Ah, removing and reinstalling actually fixed it!
jungle-boogie commentedon Jul 16, 2018
I see the QT version is currently 5.8.
justinclift commentedon Jul 16, 2018
Sounds like the 16th July nightly is in decent shape then. Guess that means the weird network problem dialog is due to something introduced in Qt 5.9. It should show up in the 5.9 release notes then...
... except there's nothing obviously related to it there. 😦
karim commentedon Jul 16, 2018
I think I have an idea why..
Reinstalling or repairing the installer should fix this. Right-click on the .msi file and select Repair will do it.
@justinclift Yes, you are right. 16th July build fixed both (GUI and network) problems for me. Also I don't get this grey area on the right side as I mentioned in my earlier comment. Thanks 😄
justinclift commentedon Jul 16, 2018
Cool. Guess this issue can be closed again now. 😄