-
Notifications
You must be signed in to change notification settings - Fork 12
Installation under windows 64 bit
Please see http://cranvas.org/download.html instead.
- Install R and Rtools. Add the following to your PATH, in which ... should be substituted by the directory that installed R and Rtools.
...\Rtools\bin;
...\Rtools\gcc-4.6.3\bin;
...\R\bin\x64;
-
Install cmake 2.8.11 from http://www.cmake.org/files/v2.8/cmake-2.8.11-win32-x86.exe. Add
...\CMake 2.8\bin
to the PATH. -
Download MinGW from http://sourceforge.net/projects/mingwbuilds/ Install it with settings: Version - 4.8.1; Architecture - x64; Threads - posix; Exception - sjlj; Build revision - rev5. Then add it to PATH. (For example,
...\MinGW\bin
) NOTE: No spaces are allowed in the directory. -
Install Perl and add its bin to the PATH.
-
Download Qt from http://download.qt-project.org/archive/qt/4.8/4.8.4/qt-everywhere-opensource-src-4.8.4.zip and extract it somewhere, for example,
C:\Qt\4.8.4\
. Add its bin folder to PATH. (C:\Qt\4.8.4\bin
) -
Open
C:/Qt/4.8.4/mkspecs/win32-g++/qmake.conf
and set bothQMAKE_CFLAGS
andQMAKE_LFLAGS
to "-m64". Also, add "-F pe-x86-64" toQMAKE_RC
. (i.e.,QMAKE_RC = $${CROSS_COMPILE}windres -F pe-x86-64
) -
Open
C:/Qt/4.8.4/qmake/Makefile.win32-g++-sh
, add "-m64" toCFLAGS
(i.e.,CFLAGS = -c -o$@ -O -m64 \
) and changeLFLAGS
to "-s -m64". (i.e.,LFLAGS = -s -m64
) -
Run the following two lines (one by one) in the command prompt under the Qt directory (
C:/Qt/4.8.4/
). This Qt compiling step may take 3-4 hours.
configure -release -opensource -nomake examples -nomake demos -no-qt3support
mingw32-make
-
If you get an error like:
__cpuid(info, 1) was not declared in this scope
, then openC:/Qt/4.8.4/src/corelib/tools/qsimd.cpp
, add#include <intrin.h>
on top. -
Create the
CMAKE
environment variable and set it to point to yourcmake.exe
. (for example,...\CMake 2.8\bin\cmake.exe
) -
Set
QMAKE
environment variable to point toqmake.exe
. (for example,C:\Qt\4.8.4\bin\qmake.exe
) -
Set
RC_COMPILER
environment variable to point towindres.exe
from Rtools. Make sure to change the backslash(\
) to slash(/
) here. (for example,.../Rtools/gcc-4.6.3/bin/windres.exe
) -
Set
QTBASE_QT_PATH
to the directory containingqmake.exe
. (for example,C:\Qt\4.8.4\bin
) -
Make sure perl, cmake, Qt, R-64bit, Rtools, Rtools-gcc, MinGW are on your PATH. Example PATH to build qtbase (better to put these before others):
C:\MinGW\bin;
C:\Program Files\Rtools\bin;
C:\Program Files\Rtools\gcc-4.6.3\bin;
C:\Program Files\R\bin\x64;
C:\Qt\4.8.4\bin;
C:\Perl\strawberry\perl\bin\;
C:\Program Files\CMake 2.8\bin;
[... other directories ...]
-
Download qtbase from https://github.com/ggobi/qtbase/archive/master.zip and unzip it. It does not matter where you unzip it. Change the folder name from "qtbase-master" to "qtbase".
-
(This should be fixed in code) Check
qtbase/src/mkdef.sh
Changesed -n $1 tmp >> qtbase.def
to
sed -n 's/^.* [BCDRT] / /p' tmp >> qtbase.def
-
Make a copy of the whole qtbase folder. Put it in another directory, or just rename it. Don't delete this clean copy until you successfully install qtbase after step 17.
-
Start the command shell, go to the directory containing qtbase (i.e., the parent directory of qtbase). Run:
R CMD INSTALL --build qtbase
Please make sure the folder qtbase is completely clean (i.e., has never been built).
If not, get the clean copy from step 16.
-
Add the
...\qtbase\local\lib
to PATH. where ... is replaced by your R library path. Run?.libPaths
in R to find out it. -
Download glext.h from http://www.opengl.org/registry/api/glext.h And copy it to
C:\Qt\4.8.4\src\opengl\
Add a line to
C:\Qt\4.8.4\include\QtOpenGL\qgl.h
:
#include "../../src/opengl/glext.h"
??? An alternative way is editing `OpenGLPainter.cpp`
#ifdef Q_OS_WIN
#include "glext.h"
#endif
- Download qtpaint Start the command shell, go to the directory containing qtpaint. Run:
R CMD INSTALL --build qtpaint