README_VISUAL.TXT 4.86 KB
Newer Older
Sylvain Thery's avatar
Sylvain Thery committed
1
 *** english version below ***
Pierre Kraemer's avatar
Pierre Kraemer committed
2 3

Compilation sous VisualExpress C++
Sylvain Thery's avatar
Sylvain Thery committed
4

Pierre Kraemer's avatar
Pierre Kraemer committed
5
Prérequis:
Sylvain Thery's avatar
Sylvain Thery committed
6
Visual Studio ou C++ Express 2013 (C++11
7
CMake (au moins 2.8)
Pierre Kraemer's avatar
Pierre Kraemer committed
8

thery's avatar
thery committed
9
Unziper le windows_dependencies.zip (http://iggservis.u-strasbg.fr/Data/) a la racine de CGoGN
unknown's avatar
unknown committed
10
Installer boost et Qt (4.8.x pas de 5.0 pour le moment)
11 12 13 14 15 16

Attention installer les binaires de Qt dans une version de compilateur differente (VS2008/VS2010)
permet d'executer mais pas de debugger !

Le plus sur mais plus long est de compiler soi-même Qt et Boost (bon courage)

Sylvain Thery's avatar
Sylvain Thery committed
17 18
Pour les "ThirdParty libs":
Lancer CMake (gui)
thery's avatar
thery committed
19
Mettre le chemin de la racine de CGoGN + /ThirdParty pour les sources
Sylvain Thery's avatar
Sylvain Thery committed
20
Mettre le chemin de la racine de CGoGN + /ThirdParty/build
unknown's avatar
unknown committed
21

thery's avatar
thery committed
22 23
Cliquer sur Configure
Choisir le bon compilateur (celui de votre version de Visual C++)
24
Modifier les variables en fonctions de ce que vous voulez compiler (README.TXT de ThirdParty)
Sylvain Thery's avatar
Sylvain Thery committed
25
Modifier le CMAKE_PREFIX_PATH si nécessaire (cf remarque dépendances)
thery's avatar
thery committed
26 27
Recliquer sur Configure
Cliquer sur Generate
Sylvain Thery's avatar
Sylvain Thery committed
28
Aller sous visual, charger et compiler en Release et Debug 
unknown's avatar
unknown committed
29
Ne pas oublier de générer la cible INSTALL (une seule fois)
thery's avatar
thery committed
30

Sylvain Thery's avatar
Sylvain Thery committed
31
Pour CGoGN:
thery's avatar
thery committed
32
Relancer CMake
Sylvain Thery's avatar
Sylvain Thery committed
33
Mettre le chemin de la racine de CGoGN pour les sources
Sylvain Thery's avatar
Sylvain Thery committed
34
Mettre le chemin de la racine de CGoGN + /build pour le build
Pierre Kraemer's avatar
Pierre Kraemer committed
35 36
Cliquer sur Configure
Choisir le bon compilateur (celui de votre version de Visual C++)
Sylvain Thery's avatar
Sylvain Thery committed
37
Modifier les variables comme pour ThirdParty (et CMAKE_PREFIX_PATH si nécessaire)
Pierre Kraemer's avatar
Pierre Kraemer committed
38 39
Recliquer sur Configure
Cliquer sur Generate
thery's avatar
thery committed
40

unknown's avatar
unknown committed
41
Si il ne trouve pas Qt lui remplir la variable QT_QMAKE_EXECUTABLE
Sylvain Thery's avatar
Sylvain Thery committed
42
Si il ne trouve pas boost, remplir la variable Boost_INCLUDE_DIR (C:\Boost1.55\include par exemple)
unknown's avatar
unknown committed
43

Pierre Kraemer's avatar
Pierre Kraemer committed
44 45
Aller dans Visual et double-cliquer sur CGoGN.sln !!

unknown's avatar
unknown committed
46 47 48 49 50
ATTENTION: Problème de link avec QGLViewer en Debug.
Si vous compiler un exemple (tuto1 & viewer) en Debug, il faut modifier
le projet: Proprietés de configuration -> Editeur de liens -> entrée -> Dépendances supplémentaires
et changer le QGLViewer2.lib en QGLViewerd2.lib

Sylvain Thery's avatar
Sylvain Thery committed
51 52
Pour que les executables fonctionnent ajouter le chemin vers les dll des dépendances dans la variable
d'environnement path (ou copier les dll dans un répertoire déjà dans le path)
Pierre Kraemer's avatar
Pierre Kraemer committed
53 54


Sylvain Thery's avatar
Sylvain Thery committed
55
Remarque dépendances:
56
Si vous voulez utiliser vos propre versions des dépendance (Zlib / glew / Boost / Qt)
Sylvain Thery's avatar
Sylvain Thery committed
57 58
changer le CMAKE_PREFIX_PATH (voir ci dessous)
Attention pour Boost le prefix path ne marche pas (utiliser BOOST_ROOT et d'autres si nécessaire)
59

unknown's avatar
unknown committed
60
Compilation 64bits: TODO
Pierre Kraemer's avatar
Pierre Kraemer committed
61

Sylvain Thery's avatar
Sylvain Thery committed
62 63 64 65 66 67 68


=========================================================================================
                                ENGLISH VERSION
=========================================================================================

Prerequisites:
unknown's avatar
unknown committed
69
Visual Studio and C ++ Express (2010)
Sylvain Thery's avatar
Sylvain Thery committed
70 71 72 73 74 75 76 77 78 79 80 81 82 83
CMake (at least 2.8)

Unzip the windows_dependencies.zip (http://iggservis.u-strasbg.fr/Data/) is the root of CGoGN
Install boost and Qt


Warning installing the binaries of Qt in a version of different compilers (VS2008/VS2010)
allows you to run but not in debug mode!

The safest but longest is to compile Qt yourself and Boost (good luck)


For the "ThirdParty libs"
Run CMake (gui)
Sylvain Thery's avatar
Sylvain Thery committed
84 85
Put the path to the root of CGoGN + / ThirdParty sources for sources
Put the path to the root of CGoGN + / ThirdParty / build for build
Sylvain Thery's avatar
Sylvain Thery committed
86 87 88 89 90 91 92

Click on Configure
Choosing the right compiler (your version of Visual C + +)
Change the variables in functions that you want to compile (README.TXT for ThirdParty)
Edit CMAKE_PREFIX_PATH if necessary (see note dependencies)
Click again on Configure
Click on Generate
Sylvain Thery's avatar
Sylvain Thery committed
93
Go on visual, load and compile the solution in Release and Debug
unknown's avatar
unknown committed
94
Do not forgot to generate the target INSTALL (once) 
Sylvain Thery's avatar
Sylvain Thery committed
95 96 97 98 99


For CGoGN:
Restart CMake
Put the path to the root of CGoGN for sources
Sylvain Thery's avatar
Sylvain Thery committed
100
Put the path to the root of CGoGN + / build to build
Sylvain Thery's avatar
Sylvain Thery committed
101 102 103 104 105 106 107
Click on Configure
Choosing the right compiler (your version of Visual C + +)
Change the variables as ThirdParty (and CMAKE_PREFIX_PATH if necessary)
Click again on Configure
Click on Generate
Go to Visual and double-click on CGoGN.sln!

Sylvain Thery's avatar
Sylvain Thery committed
108 109 110 111
If it does not found Qt fill the QT_QMAKE_EXECUTABLE variable.
If it does not found boost, fill the Boost_INCLUDE_DIR variable (C:\Boost1.55\include for example)


unknown's avatar
unknown committed
112 113 114 115
WARNING: Problem of linking with QGLViewer in Debug
If you compile an example (tuto1 & viewer) in Debug you have to modifiy
the project: Configuration properties -> Linking Editor -> Entries -> Supplementary dependencies
and change QGLViewer2.lib in QGLViewerd2.lib
Sylvain Thery's avatar
Sylvain Thery committed
116 117 118 119 120 121 122 123 124 125

For running executables you have to add the path to the dll dependencies in the variable
path environment (or copy the dll in a directory already in the path)


Note Dependencies:
If you want to use your own versions of dependency (Zlib / glew / Boost / Qt)
CMAKE_PREFIX_PATH change (see below)
Attention to Boost the prefix path does not work (use BOOST_ROOT and others if necessary)

unknown's avatar
unknown committed
126
Compiling 64-bit: TODO