title: Compiling Qt 5.3.0 for static linking under windows
body: <p>I am trying to compile Qt for static linking following this tutorial: <a href="http://qt-project.org/wiki/How-to-build-a-static-Qt-for-Windows-MinGW" rel="nofollow">http://qt-project.org/wiki/How-to-build-a-static-Qt-for-Windows-MinGW</a></p>
  
  <p>But i receive tons of warnings and a few errors.</p>
  
  <p>For example this one:</p>
  
  <pre><code>C:/Developement/Qt/Tools/mingw482_32/bin/../lib/gcc/i686-w64-mingw32/4.8.2/../../../../i686-w64-mingw32/bin/ld.exe: cannot find -lqjp2
  collect2.exe: error: ld returned 1 exit status
  Makefile.Release:79: recipe for target '..\..\bin\dumpdoc.exe' failed
  mingw32-make[4]: *** [..\..\bin\dumpdoc.exe] Error 1
  mingw32-make[4]: Target 'first' not remade because of errors.
  mingw32-make[4]: Leaving directory 'C:/Developement/Qt/Static/src/qt-everywhere-opensource-src-5.3.0/qtactiveqt/tools/dumpdoc'
  Makefile:34: recipe for target 'release' failed
  mingw32-make[3]: *** [release] Error 2
  mingw32-make[3]: Target 'first' not remade because of errors.
  </code></pre>
  
  <p>for this, i set the environement variable to my path:</p>
  
  <pre><code>Name: LIBRARY_PATH
  Value: C:\Developement\Qt\5.3\mingw482_32\bin
  </code></pre>
  
  <p>... but dunno yet if its gonna workin'</p>
  
  <p>Beside this, i put the following paths to the PATH environement variable:</p>
  
  <pre><code>C:\Developement\Qt\5.3\mingw482_32\bin;
  C:\Developement\Qt\Tools\mingw482_32\bin;
  </code></pre>
  
  <p>I am receiving tons of these kind of warning:</p>
  
  <blockquote>
    <p>In file included from
    C:\Developement\Qt\Static\src\qt-everywhere-opensource-src-5.3.0\qtbase\src\3rdparty\libjpeg/jpeglib.h:25:0,
                     from ......\3rdparty\jasper\src\libjasper\jpg\jpg_jpeglib.h:74,
                     from ......\3rdparty\jasper\src\libjasper\jpg\jpg_dec.c:75:
    C:\Developement\Qt\Static\src\qt-everywhere-opensource-src-5.3.0\qtbase\src\3rdparty\libjpeg/jconfig.h:55:0:
    warning:  "HAVE_STDDEF_H" redefined [enabled by default]  #define
    HAVE_STDDEF_H  ^ In file included from
    ......\3rdparty\jasper\src\libjasper\include/jasper/jas_tvp.h:75:0,
                     from ......\3rdparty\jasper\src\libjasper\jpg\jpg_dec.c:70:
    ......\3rdparty\jasper\src\libjasper\include/jasper/jas_config.h:65:0:
    note: this is the location of the previous definition  #define
    HAVE_STDDEF_H 1  ^ In file included from
    C:\Developement\Qt\Static\src\qt-everywhere-opensource-src-5.3.0\qtbase\src\3rdparty\libjpeg/jpeglib.h:25:0,
                     from ......\3rdparty\jasper\src\libjasper\jpg\jpg_jpeglib.h:74,
                     from ......\3rdparty\jasper\src\libjasper\jpg\jpg_dec.c:75:
    C:\Developement\Qt\Static\src\qt-everywhere-opensource-src-5.3.0\qtbase\src\3rdparty\libjpeg/jconfig.h:59:0:
    warning:  "HAVE_STDLIB_H" redefined [enabled by default]  #define
    HAVE_STDLIB_H  ^
        In file included from ......\3rdparty\jasper\src\libjasper\include/jasper/jas_tvp.h:75:0,
                     from ......\3rdparty\jasper\src\libjasper\jpg\jpg_dec.c:70:
        ......\3rdparty\jasper\src\libjasper\include/jasper/jas_config.h:71:0:
    note: this is the location of the previous definition
        #define HAVE_STDLIB_H 1
        ^
        ......\3rdparty\jasper\src\libjasper\jpg\jpg_dec.c: In function 'jpg_decode':
        ......\3rdparty\jasper\src\libjasper\jpg\jpg_dec.c:134:49: warning: parameter 'optstr' set but not used 
        [-Wunused-but-set-parameter]
        jas_image_t *jpg_decode(jas_stream_t *in, char *optstr)
                                                     ^
        ......\3rdparty\jasper\src\libjasper\jpg\jpg_dec.c: In function 'jpg_start_output':
        ......\3rdparty\jasper\src\libjasper\jpg\jpg_dec.c:298:47: warning: parameter 'cinfo' set but not used
    [-Wunused-but-set-parameter]
        static void jpg_start_output(j_decompress_ptr cinfo, jpg_dest_t *dinfo)
                                                   ^
        ......\3rdparty\jasper\src\libjasper\jpg\jpg_dec.c: In function 'jpg_finish_output':
        ......\3rdparty\jasper\src\libjasper\jpg\jpg_dec.c:335:48: warning: parameter 'cinfo' set but not used
    [-Wunused-but-set-parameter]
        static void jpg_finish_output(j_decompress_ptr cinfo, jpg_dest_t *dinfo)
                                                    ^    ......\3rdparty\jasper\src\libjasper\jpg\jpg_dec.c:335:67: warning:
    parameter 'dinfo' set but not used [-Wunused-but-set-parameter]
        static void jpg_finish_output(j_decompress_ptr cinfo, jpg_dest_t *dinfo)
                                                                       ^</p>
  </blockquote>
  
  <p>Wasn't i prepared enough to compile Qt?</p>
  
  <p>What do i need to do in order to be able to compile Qt without getting errors everytime thrown out?</p>
  
  <p>How long would it take until its compiled.</p>