Rebuilding Qt 5 (MSVC) from source wihtout breaking SDK structure



  • Because of recent discoveries of dependencies not needed for Qt 5 apps, it has become necessary to rebuild with those items removed. Specifically OpenGL and Webkit. These create a need of many DLLs which are not needed for the apps that are created. However, in the first pass at the rebuild I notice that the folders created after the rebuild are not the same as what is represented in the SDK.

    I used the following switches in the build:

    -no-opengl
    -no-icu

    It appears the build re-created the qtbase contents only. It also appears that the platforms folder is missing and there may be more.
    The goal is to have a SDK with those features not needed and if I were to use that, then my SDK somewhat incomplete.

    What is the right path to having a custom SDK?


  • Moderators

    I don't think there is any. After all, SDK is simply a prepackaged Qt Creator + Qt libraries. If you compile Qt yourself from source (git, tarball or zip), Qt Creator continues to work. I don't see the point in custom SDK.

    In any case, you can take a look at QtSdk repo in gitorious, or search for Qt Installer Framework. It should allow you to create custom SDK packages.


  • Moderators

    As sierdzio already lines out a recompilation will fit into your environment.
    You should consider an SDK more as a convenient way to start working with Qt and its tools. Especially for beginners it is easier to install an SDK where already everything is in order. Unfortunately, this is not the case with Qt5 and qt creator, but that is another story.

    Two things I like to add:

    • in the past it was a bad choice to recompile Qt libs based on source which came with the SDK. I am not sure if this is still the case.
    • the pre-compilation may have more than you need. However, that should not be the reason to make a recompilation necessary. The extra eats disk space. That is a fact. However, it eats only the disk space on your development machine. However, you do not have to include all those dlls into your distributions of your developed applications.

    Personally, I am using only a fraction of Qt, but that was never the reason to do a recompilation. Certainly I will consider the different modules to include when doing the recompile, because this saves compile time then.



  • [quote author="koahnig" date="1358848593"]As sierdzio already lines out a recompilation will fit into your environment.
    You should consider an SDK more as a convenient way to start working with Qt and its tools. Especially for beginners it is easier to install an SDK where already everything is in order. Unfortunately, this is not the case with Qt5 and qt creator, but that is another story.

    Two things I like to add:

    • in the past it was a bad choice to recompile Qt libs based on source which came with the SDK. I am not sure if this is still the case.
    • the pre-compilation may have more than you need. However, that should not be the reason to make a recompilation necessary. The extra eats disk space. That is a fact. However, it eats only the disk space on your development machine. However, you do not have to include all those dlls into your distributions of your developed applications.

    Personally, I am using only a fraction of Qt, but that was never the reason to do a recompilation. Certainly I will consider the different modules to include when doing the recompile, because this saves compile time then. [/quote]

    I am not glib about the decision to recompile the libraries. The decision was more of a forced one. With all the added dependencies accompanying apps, it has become necessary to build out things like Open GL, Webkit etc.



  • Looking at some posts here and others on another forum, it seems that there are a growing list of issues building version 5.0 from source. For instance when running configure -no-opengl -no-icu, I get many errors, the most recent is related to printsupport.lib I can only assume that this is part of the problem in the whole build not running to completion. I recall that in version 4.8.4 that everything built including designer.


  • Moderators

    Uoh, you should have seen pre-alpha stage ;) A lot more compilation problems back then. Anyway, 5.0.1 is just around the corner, with 300+ updates. Maybe it will make another impression on you :)



  • [quote author="sierdzio" date="1359035704"]Uoh, you should have seen pre-alpha stage ;) A lot more compilation problems back then. Anyway, 5.0.1 is just around the corner, with 300+ updates. Maybe it will make another impression on you :)[/quote]

    Not knowing when the next minor rev is due, I need to try to hobble along and get this built. I installed Active Perl as this is the tool that targets my needs i.e. no Webkit nor JsBackend requirements. Also, of course, the Win SDK 7.1 for compiling.

    I am building the source from the download page and not grabbing via Git. I am doing everything as instructed and have a very clean build environment.



  • [quote author="koahnig" date="1358848593"]As sierdzio already lines out a recompilation will fit into your environment.
    You should consider an SDK more as a convenient way to start working with Qt and its tools. Especially for beginners it is easier to install an SDK where already everything is in order. Unfortunately, this is not the case with Qt5 and qt creator, but that is another story.

    Two things I like to add:

    • in the past it was a bad choice to recompile Qt libs based on source which came with the SDK. I am not sure if this is still the case.
    • the pre-compilation may have more than you need. However, that should not be the reason to make a recompilation necessary. The extra eats disk space. That is a fact. However, it eats only the disk space on your development machine. However, you do not have to include all those dlls into your distributions of your developed applications.

    Personally, I am using only a fraction of Qt, but that was never the reason to do a recompilation. Certainly I will consider the different modules to include when doing the recompile, because this saves compile time then. [/quote]

    You do have include those DLLs which are dependent upon the EXE and that number with this release can be rather large. Prior versions had two DLLs. Version 5 has almost 3x more for the same app.


  • Moderators

    [quote author="astodolski" date="1359037325"]
    You do have include those DLLs which are dependent upon the EXE and that number with this release can be rather large. Prior versions had two DLLs. Version 5 has almost 3x more for the same app.
    [/quote]
    OK, that is good to know. As already noted I do not have Qt5 experience. With Qt4 I am typically requiring QtCore, QtNetwork and maybe QtGui dlls. My concern there is only that those have increased over the years significantly.
    My hope was that there might be more dlls in Qt5, but that they have some sort of a smart selection. This may shrink the overall application plus dll size.
    I would not consider some required modules found and any dependency on OpenGL and webkit, if you are not them at all in your app.
    I have compiled the Qt4 libs already a couple of times. The major nuisance is the required time and that you have to do it again, because of stupid options you have chosen with configure. Nevertheless the compilation I try avoid if not absolutely required.


Log in to reply
 

Looks like your connection to Qt Forum was lost, please wait while we try to reconnect.