@@ -25,15 +25,15 @@ How to call cmake initially, then repeatedly
25
25
- Example of configuring, building, reconfiguring, rebuilding:
26
26
$ mkdir build
27
27
$ cd build
28
- $ cmake -DCMAKE_C_COMPILER=gcc -DCMAKE_CXX_COMPILER=g++ -Darch =32 .. # Initial configuration
28
+ $ cmake -DCMAKE_C_COMPILER=gcc -DCMAKE_CXX_COMPILER=g++ -DLIBOMP_ARCH =32 .. # Initial configuration
29
29
$ make all common
30
30
...
31
31
$ make clean
32
- $ cmake -Darch =32e -DCMAKE_BUILD_TYPE=Debug .. # Second configuration
32
+ $ cmake -DLIBOMP_ARCH =32e -DCMAKE_BUILD_TYPE=Debug .. # Second configuration
33
33
$ make all common
34
34
...
35
35
$ rm -rf *
36
- $ cmake -DCMAKE_C_COMPILER=gcc -DCMAKE_CXX_COMPILER=g++ -Darch =32e .. # Third configuration
36
+ $ cmake -DCMAKE_C_COMPILER=gcc -DCMAKE_CXX_COMPILER=g++ -DLIBOMP_ARCH =32e .. # Third configuration
37
37
$ make all common
38
38
- Notice in the example how the compiler definitions are only specified
39
39
for an empty build directory, but other Build options are used at any time.
@@ -58,7 +58,7 @@ Instructions to Build
58
58
$ cmake -DCMAKE_C_COMPILER=<C Compiler> -DCMAKE_CXX_COMPILER=<C++ Compiler> ..
59
59
60
60
[ Intel(R) Many Integrated Core Library (Intel(R) MIC Library) ]
61
- $ cmake -DCMAKE_C_COMPILER=<C Compiler> -DCMAKE_CXX_COMPILER=<C++ Compiler> -Darch =mic ..
61
+ $ cmake -DCMAKE_C_COMPILER=<C Compiler> -DCMAKE_CXX_COMPILER=<C++ Compiler> -DLIBOMP_ARCH =mic ..
62
62
63
63
[ Windows Libraries ]
64
64
$ cmake -G "Unix Makefiles" -DCMAKE_C_COMPILER=<C Compiler> -DCMAKE_CXX_COMPILER=<C++ Compiler> -DCMAKE_ASM_MASM_COMPILER=[ml | ml64] -DCMAKE_BUILD_TYPE=Release ..
@@ -71,13 +71,13 @@ Mac* Fat Libraries
71
71
On OS X* machines, it is possible to build universal (or fat) libraries which
72
72
include both IA-32 architecture and Intel(R) 64 architecture objects in a
73
73
single archive; just build the 32 and 32e libraries separately:
74
- $ cmake -DCMAKE_C_COMPILER=clang -DCMAKE_CXX_COMPILER=clang++ -Darch =32 ..
74
+ $ cmake -DCMAKE_C_COMPILER=clang -DCMAKE_CXX_COMPILER=clang++ -DLIBOMP_ARCH =32 ..
75
75
$ make
76
- $ cmake -Darch =32e ..
76
+ $ cmake -DLIBOMP_ARCH =32e ..
77
77
$ make
78
78
then invoke make again with a special argument as follows:
79
79
$ make fat
80
- - The fat target is only available for the arch =32e configuration.
80
+ - The fat target is only available for the LIBOMP_ARCH =32e configuration.
81
81
- The fat libraries will be put in exports/mac_32e/lib while the "thin" libraries
82
82
will be in exports/mac_32e/lib.thin and exports/mac_32/lib.thin
83
83
@@ -89,7 +89,7 @@ Compiler options
89
89
90
90
-DCMAKE_Fortran_COMPILER=<Fortran compiler name>
91
91
Unix* systems (Optional as compiler is default):
92
- This option is only needed when -Dcreate_fortran_modules is true
92
+ This option is only needed when -DLIBOMP_FORTRAN_MODULES is true
93
93
94
94
-DCMAKE_ASM_MASM_COMPILER=[ml | ml64 ]
95
95
This option is Windows* Only
@@ -101,52 +101,51 @@ Build options
101
101
==========================
102
102
==== Operating System ====
103
103
==========================
104
- -Dos =lin|mac|win
104
+ -DLIBOMP_OS =lin|mac|win
105
105
* Operating system can be lin (Linux*), mac (Mac*), or win (Windows*).
106
106
If not specified, cmake will try to determine your current operating system.
107
107
108
108
======================
109
109
==== Architecture ====
110
110
======================
111
- -Darch =32|32e|arm|ppc64|ppc64le|aarch64|mic
111
+ -DLIBOMP_ARCH =32|32e|arm|ppc64|ppc64le|aarch64|mic
112
112
* Architecture can be 32 (IA-32 architecture), 32e (Intel(R) 64 architecture),
113
113
arm (ARM architecture), aarch64 (ARMv8 architecture), ppc64 (PPC64 architecture),
114
114
or ppc64le (little endian PPC64 architecture).
115
115
* This option, by default is chosen based on the probing the compiler for
116
116
architecture macros (e.g., is __x86_64__ predefined by compiler?).
117
117
118
118
---- First values listed are the default value ----
119
- -Dlib_type =normal|profile|stubs
119
+ -DLIBOMP_LIB_TYPE =normal|profile|stubs
120
120
Library type can be normal, profile, or stubs.
121
121
122
122
-DCMAKE_BUILD_TYPE=Release|Debug|RelWithDebInfo
123
123
Build type can be Release, Debug, or RelWithDebInfo.
124
- See below for interaction when -DUSE_BUILDPL_RULES is on.
125
124
126
- -Dversion =5|4
125
+ -DLIBOMP_VERSION =5|4
127
126
libiomp5 version can be 5 or 4.
128
127
129
- -Domp_version =40|30
128
+ -DLIBOMP_OMP_VERSION =40|30
130
129
OpenMP version can be either 40 or 30.
131
130
132
- -Dmic_arch =knc|knf
131
+ -DLIBOMP_MIC_ARCH =knc|knf
133
132
Intel(R) MIC Architecture, can be knf or knc.
134
- This value is ignored if os != mic
133
+ This value is ignored if LIBOMP_ARCH != mic
135
134
136
- -Dcreate_fortran_modules =off|on
135
+ -DLIBOMP_FORTRAN_MODULES =off|on
137
136
Should the Fortran modules be created (requires Fortran compiler)
138
137
139
- -Dstats =off|on
138
+ -DLIBOMP_STATS =off|on
140
139
Should include stats-gathering code?
141
140
142
- -Dompt_support =off|on
141
+ -DLIBOMP_OMPT_SUPPORT =off|on
143
142
Should OMPT support be turned on?
144
143
If ompt_support is off, then both ompt_blame and ompt_trace are ignored.
145
144
146
- -Dompt_blame =on|off
145
+ -DLIBOMP_OMPT_BLAME =on|off
147
146
should OMPT blame functionality be turned on?
148
147
149
- -Dompt_trace =on|off
148
+ -DLIBOMP_OMPT_TRACE =on|off
150
149
should OMPT trace functionality be turned on?
151
150
152
151
=====================
@@ -155,14 +154,14 @@ should OMPT trace functionality be turned on?
155
154
After the library has been built, there are five optional microtests that
156
155
can be performed. Some will be skipped based upon the platform.
157
156
These tests can be turned on (default) or off with the following options:
158
- -Dtest_touch =on|off -- Should the touch test be done?
159
- -Dtest_relo =on|off -- Should the position independent code test be done?
160
- -Dtest_execstack =on|off -- Should the stack be checked for executability?
161
- -Dtest_instr =on|off -- Should the Intel(R) MIC Libraries be checked
157
+ -DLIBOMP_TEST_TOUCH =on|off -- Should the touch test be done?
158
+ -DLIBOMP_TEST_RELO =on|off -- Should the position independent code test be done?
159
+ -DLIBOMP_TEST_EXECSTACK =on|off -- Should the stack be checked for executability?
160
+ -DLIBOMP_TEST_INSTR =on|off -- Should the Intel(R) MIC Libraries be checked
162
161
for correct instruction set?
163
- -Dtest_deps =on|off -- Should libiomp5's dependencies be checked?
164
- -Dtests =off|on -- Should any of the above tests be done?
165
- If -Dtests =on is specified, the user can then call:
162
+ -DLIBOMP_TEST_DEPS =on|off -- Should libiomp5's dependencies be checked?
163
+ -DLIBOMP_MICRO_TESTS =off|on -- Should any of the above tests be done?
164
+ If -DLIBOMP_MICRO_TESTS =on is specified, the user can then call:
166
165
$ make libiomp-micro-tests
167
166
which runs the tests.
168
167
@@ -171,45 +170,45 @@ which runs the tests.
171
170
============================================
172
171
- These flags are *appended*. They do not
173
172
overwrite any of the preset flags.
174
- -DLIBIOMP_CPPFLAGS =<space-separated flags> -- Additional C Preprocessor flags
173
+ -DLIBOMP_CPPFLAGS =<space-separated flags> -- Additional C Preprocessor flags
175
174
(typically additional -Ddef=val flags)
176
- -DLIBIOMP_CFLAGS =<space-separated flags> -- Additional C compiler flags
177
- -DLIBIOMP_CXXFLAGS =<space-separated flags> -- Additional C++ compiler flags
178
- -DLIBIOMP_ASMFLAGS =<space-separated flags> -- Additional assembly flags
179
- -DLIBIOMP_LDFLAGS =<space-separated flags> -- Additional linker flags
180
- -DLIBIOMP_LIBFLAGS =<space-separated flags> -- Additional libraries to link
175
+ -DLIBOMP_CFLAGS =<space-separated flags> -- Additional C compiler flags
176
+ -DLIBOMP_CXXFLAGS =<space-separated flags> -- Additional C++ compiler flags
177
+ -DLIBOMP_ASMFLAGS =<space-separated flags> -- Additional assembly flags
178
+ -DLIBOMP_LDFLAGS =<space-separated flags> -- Additional linker flags
179
+ -DLIBOMP_LIBFLAGS =<space-separated flags> -- Additional libraries to link
181
180
to during link phase
182
- -DLIBIOMP_FFLAGS =<space-separated flags> -- Additional Fortran compiler flags
181
+ -DLIBOMP_FFLAGS =<space-separated flags> -- Additional Fortran compiler flags
183
182
184
183
===================================
185
184
==== Feature Based Compilation ====
186
185
===================================
187
- -DUSE_BUILDPL_RULES =false|true
186
+ -DLIBOMP_USE_BUILDPL_RULES =false|true
188
187
Should the build imitate build.pl's build process.
189
188
When this is true, the Unix* Release builds will build libiomp5
190
189
with -O2 and -g flags activated (same as RelWithDebInfo). Then,
191
190
the debug info is stripped out of the library and put into libiomp5.dbg
192
191
This is done for interaction with Intel(R) Parallel Amplifier.
193
192
194
- -DUSE_ADAPTIVE_LOCKS =true|false
193
+ -DLIBOMP_USE_ADAPTIVE_LOCKS =true|false
195
194
Should adaptive (TSX-based) locks be included?
196
195
These are x86 specific. This feature is turned on by default
197
196
for IA-32 architecture and Intel(R) 64 architecture.
198
197
Otherwise, it is turned off.
199
198
200
- -DUSE_INTERNODE_ALIGNMENT =false|true
199
+ -DLIBOMP_USE_INTERNODE_ALIGNMENT =false|true
201
200
Should 4096-byte alignment be used for certain data structures?
202
201
This option is useful on multinode systems where a small CACHE_LINE
203
202
setting leads to false sharing. This option is off by default.
204
203
205
- -DUSE_VERSION_SYMBOLS =true|false
204
+ -DLIBOMP_USE_VERSION_SYMBOLS =true|false
206
205
Should versioned symbols be used for building the library?
207
206
This option only makes sense for ELF based libraries where version
208
207
symbols are supported (Linux, some BSD* variants). It is off
209
208
by default for Windows and Mac, but on for other Unix based operating
210
209
systems.
211
210
212
- -DUSE_PREDEFINED_LINKER_FLAGS =true|false
211
+ -DLIBOMP_USE_PREDEFINED_LINKER_FLAGS =true|false
213
212
Should the predefined linker flags in CommonFlags.cmake be included
214
213
in the link command? This is true by default and should work for
215
214
Linux*, Mac*, and Windows*. The --version-script flag on Unix* based
@@ -225,22 +224,22 @@ cmake -DCMAKE_C_COMPILER=clang -DCMAKE_CXX_COMPILER=clang++ ..
225
224
226
225
---- With Various Options ----
227
226
- Build the 32 bit Linux library using GCC*
228
- cmake -DCMAKE_C_COMPILER=gcc -DCMAKE_CXX_COMPILER=g++ -Dos =lin -Darch =32 ..
227
+ cmake -DCMAKE_C_COMPILER=gcc -DCMAKE_CXX_COMPILER=g++ -DLIBOMP_OS =lin -DLIBOMP_ARCH =32 ..
229
228
230
229
- Build the 32 bit debug Mac library using Clang*
231
- cmake -DCMAKE_C_COMPILER=clang -DCMAKE_CXX_COMPILER=clang++ -Dos =mac -Darch =32 -DCMAKE_BUILD_TYPE=Debug ..
230
+ cmake -DCMAKE_C_COMPILER=clang -DCMAKE_CXX_COMPILER=clang++ -DLIBOMP_OS =mac -DLIBOMP_ARCH =32 -DCMAKE_BUILD_TYPE=Debug ..
232
231
233
232
- Build the library (architecture determined by probing compiler) using the
234
233
Intel(R) C Compiler and the Intel(R) C++ Compiler. Also, create the fortran modules using
235
234
the Intel(R) Fortran Compiler, enabling the libiomp-micro-tests target and using similar rules that build.pl
236
235
would use to build the library.
237
- cmake -DCMAKE_C_COMPILER=icc -DCMAKE_CXX_COMPILER=icpc -DCMAKE_Fortran_COMPILER=ifort -Dtests =on -Dcreate_fortran_modules =on -DUSE_BUILDPL_RULES =on ..
236
+ cmake -DCMAKE_C_COMPILER=icc -DCMAKE_CXX_COMPILER=icpc -DCMAKE_Fortran_COMPILER=ifort -DLIBOMP_MICRO_TESTS =on -DLIBOMP_FORTRAN_MODULES =on -DLIBOMP_USE_BUILDPL_RULES =on ..
238
237
239
238
- Have CMake Find the C/C++ compiler, and specify additional flags for the C compiler, preprocessor, and C++ compiler.
240
- cmake -DLIBIOMP_CFLAGS ='Werror' -DLIBIOMP_CPPFLAGS ='-DNEW_FEATURE=1 -DOLD_FEATURE=0' -DLIBIOMP_CXXFLAGS ='-Werror -Wsign-compare' ..
239
+ cmake -DLIBOMP_CFLAGS ='Werror' -DLIBOMP_CPPFLAGS ='-DNEW_FEATURE=1 -DOLD_FEATURE=0' -DLIBOMP_CXXFLAGS ='-Werror -Wsign-compare' ..
241
240
242
241
---- Build the stubs library ----
243
- cmake -DCMAKE_C_COMPILER=gcc -DCMAKE_CXX_COMPILER=g++ -Dlib_type =stubs ..
242
+ cmake -DCMAKE_C_COMPILER=gcc -DCMAKE_CXX_COMPILER=g++ -DLIBOMP_LIB_TYPE =stubs ..
244
243
245
244
=========
246
245
Footnotes
0 commit comments