Skip to content

Commit 62917d4

Browse files
committed
fix indentation in src/CMakeLists.txt
- Replace all heading spaces with tabs as already done - Add spaces before and after all braces as already done
1 parent b43cc61 commit 62917d4

File tree

1 file changed

+61
-62
lines changed

1 file changed

+61
-62
lines changed

src/CMakeLists.txt

Lines changed: 61 additions & 62 deletions
Original file line numberDiff line numberDiff line change
@@ -36,15 +36,15 @@ project( clFFT )
3636

3737
# Define a version for the code
3838
if( NOT DEFINED CLFFT_VERSION_MAJOR )
39-
set( CLFFT_VERSION_MAJOR 2 )
39+
set( CLFFT_VERSION_MAJOR 2 )
4040
endif( )
4141

4242
if( NOT DEFINED CLFFT_VERSION_MINOR )
43-
set( CLFFT_VERSION_MINOR 12 )
43+
set( CLFFT_VERSION_MINOR 12 )
4444
endif( )
4545

4646
if( NOT DEFINED CLFFT_VERSION_PATCH )
47-
set( CLFFT_VERSION_PATCH 1 )
47+
set( CLFFT_VERSION_PATCH 1 )
4848
endif( )
4949

5050
set( CLFFT_VERSION "${CLFFT_VERSION_MAJOR}.${CLFFT_VERSION_MINOR}.${CLFFT_VERSION_PATCH}")
@@ -62,16 +62,16 @@ endif( )
6262

6363
# Set the default of CMAKE_BUILD_TYPE to be release, unless user specifies with -D. MSVC_IDE does not use CMAKE_BUILD_TYPE
6464
if( NOT MSVC_IDE AND NOT CMAKE_BUILD_TYPE )
65-
set( CMAKE_BUILD_TYPE Release CACHE STRING "Choose the type of build, options are: None Debug Release RelWithDebInfo MinSizeRel." FORCE )
65+
set( CMAKE_BUILD_TYPE Release CACHE STRING "Choose the type of build, options are: None Debug Release RelWithDebInfo MinSizeRel." FORCE )
6666
endif()
6767

6868
# Options that the user or driver program can set to control various components of the build
6969
option( BUILD_RUNTIME "Build the FFT runtime library" ON )
7070
option( BUILD_CLIENT "Build a command line clFFT client program with a variety of configurable parameters (dependency on Boost)" OFF )
7171
option( BUILD_TEST "Build the library testing suite (dependency on google test, Boost, and FFTW)" OFF )
7272
option( BUILD_LOADLIBRARIES "Build the optional dynamic load libraries that the FFT runtime will search for" ON )
73-
option( BUILD_SHARED_LIBS "Build shared libraries." ON)
74-
option( BUILD_EXAMPLES "Build examples." ON)
73+
option( BUILD_SHARED_LIBS "Build shared libraries." ON )
74+
option( BUILD_EXAMPLES "Build examples." ON )
7575
option( BUILD_CALLBACK_CLIENT "Build a command line clFFT client program that tests callback functionality (dependency on Boost)" OFF )
7676

7777
# If BOOST_ROOT is defined as an environment value, use that value and cache it so it's visible in the cmake-gui.
@@ -87,14 +87,13 @@ if( WIN32 )
8787
if( UNICODE )
8888
message( STATUS "UNICODE build" )
8989
endif( )
90-
else()
90+
else( )
9191
set( UNICODE OFF )
9292
message( STATUS "UNICODE feature disabled on linux" )
9393
endif()
9494

9595
if( MSVC_IDE )
96-
set_property( GLOBAL PROPERTY USE_FOLDERS TRUE )
97-
96+
set_property( GLOBAL PROPERTY USE_FOLDERS TRUE )
9897
set( BUILD64 ${CMAKE_CL_64} )
9998
else()
10099
option( BUILD64 "Build a 64-bit product" ON )
@@ -117,9 +116,9 @@ set( SUFFIX_BIN_DEFAULT "" )
117116
if( BUILD64 )
118117
set_property( GLOBAL PROPERTY FIND_LIBRARY_USE_LIB64_PATHS TRUE )
119118
message( STATUS "64bit build - FIND_LIBRARY_USE_LIB64_PATHS TRUE" )
120-
if( NOT APPLE )
121-
set( SUFFIX_LIB_DEFAULT "64" )
122-
endif()
119+
if( NOT APPLE )
120+
set( SUFFIX_LIB_DEFAULT "64" )
121+
endif()
123122
else( )
124123
set_property( GLOBAL PROPERTY FIND_LIBRARY_USE_LIB64_PATHS FALSE )
125124
message( STATUS "32bit build - FIND_LIBRARY_USE_LIB64_PATHS FALSE" )
@@ -137,19 +136,19 @@ set( SUFFIX_BIN ${SUFFIX_BIN_DEFAULT} CACHE STRING "String to append to 'bin' in
137136
# Client is built only if boost is found; on windows, we need vs10 or higher
138137
# Find Boost on the system, and configure the type of boost build we want
139138
if( NOT DEFINED Boost_USE_STATIC_LIBS )
140-
set( Boost_USE_STATIC_LIBS ON )
139+
set( Boost_USE_STATIC_LIBS ON )
141140
endif( )
142141

143142
if( NOT DEFINED Boost_USE_STATIC_RUNTIME )
144-
set( Boost_USE_STATIC_RUNTIME OFF )
143+
set( Boost_USE_STATIC_RUNTIME OFF )
145144
endif( )
146145

147146
# This will define Boost_FOUND
148147
find_package( Boost 1.33.0 COMPONENTS program_options )
149148
if( Boost_FOUND )
150-
message( STATUS "Boost_PROGRAM_OPTIONS_LIBRARY: ${Boost_PROGRAM_OPTIONS_LIBRARY}" )
149+
message( STATUS "Boost_PROGRAM_OPTIONS_LIBRARY: ${Boost_PROGRAM_OPTIONS_LIBRARY}" )
151150
else( )
152-
message( WARNING "Try setting Boost_DEBUG and Boost_DETAILED_FAILURE_MSG for more information" )
151+
message( WARNING "Try setting Boost_DEBUG and Boost_DETAILED_FAILURE_MSG for more information" )
153152
endif( )
154153

155154
# This will define OPENCL_FOUND
@@ -168,12 +167,12 @@ endif( )
168167
# Enable building of the googletest unit test framework if requested and all dependencies are found
169168
set( UNIT_TEST OFF )
170169
if( BUILD_TEST )
171-
include(gtest.cmake)
172-
if( GTEST_FOUND AND Boost_FOUND AND FFTW_FOUND )
170+
include(gtest.cmake)
171+
if( GTEST_FOUND AND Boost_FOUND AND FFTW_FOUND )
173172
set( UNIT_TEST ON )
174173
else( )
175174
message( "GoogleTest unit testing will NOT be built" )
176-
endif( )
175+
endif( )
177176
endif( )
178177

179178
# Enable building of the callback client if requested and all dependencies are found
@@ -188,9 +187,9 @@ get_filename_component( C_COMPILER_NAME ${CMAKE_C_COMPILER} NAME_WE )
188187
# message( "C_COMPILER_NAME: " ${C_COMPILER_NAME} )
189188
# message( "CMAKE_C_COMPILER: " ${CMAKE_C_COMPILER} )
190189

191-
if(APPLE)
192-
# avoid warning on newer cmake versions
193-
set(CMAKE_MACOSX_RPATH 0)
190+
if( APPLE )
191+
# avoid warning on newer cmake versions
192+
set( CMAKE_MACOSX_RPATH 0 )
194193
endif()
195194

196195
# Set common compile and link options
@@ -206,11 +205,11 @@ if( MSVC )
206205
elseif( CMAKE_COMPILER_IS_GNUCXX )
207206
message( STATUS "Detected GNU fortran compiler." )
208207
EXEC_PROGRAM( ${CMAKE_CXX_COMPILER} ARGS --version OUTPUT_VARIABLE vnum )
209-
STRING(REGEX REPLACE ".*([0-9])\\.([0-9])\\.([0-9]).*" "\\1\\2\\3" vnum ${vnum})
208+
STRING( REGEX REPLACE ".*([0-9])\\.([0-9])\\.([0-9]).*" "\\1\\2\\3" vnum ${vnum} )
210209
if( ${vnum} STREQUAL "452" )
211210
# we only want c++0x if we're using gcc 4.5.2
212211
set( CMAKE_CXX_FLAGS "-std=c++0x ${CMAKE_CXX_FLAGS}" )
213-
endif()
212+
endif( )
214213

215214
set( CMAKE_CXX_FLAGS "-pthread ${CMAKE_CXX_FLAGS}" )
216215
set( CMAKE_C_FLAGS "-pthread ${CMAKE_C_FLAGS}" )
@@ -228,10 +227,10 @@ elseif( CMAKE_COMPILER_IS_GNUCXX )
228227
set( CMAKE_C_FLAGS "-m32 ${CMAKE_C_FLAGS}" )
229228
endif( )
230229

231-
if( CODE_COVERAGE )
232-
set( CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} --coverage")
233-
set( CMAKE_C_FLAGS "${CMAKE_C_FLAGS} --coverage")
234-
endif()
230+
if( CODE_COVERAGE )
231+
set( CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} --coverage" )
232+
set( CMAKE_C_FLAGS "${CMAKE_C_FLAGS} --coverage" )
233+
endif( )
235234
endif( )
236235

237236
# If UNICODE is defined for microsoft compilers, pass extra definitions
@@ -246,23 +245,23 @@ message( STATUS "CMAKE_CXX_COMPILER release flags: " ${CMAKE_CXX_FLAGS_RELEASE}
246245
message( STATUS "CMAKE_CXX_COMPILER relwithdebinfo flags: " ${CMAKE_CXX_FLAGS_RELWITHDEBINFO} )
247246
message( STATUS "CMAKE_EXE_LINKER link flags: " ${CMAKE_EXE_LINKER_FLAGS} )
248247

249-
if(NOT BUILD_SHARED_LIBS)
250-
set(CLFFT_STATIC ON)
251-
endif()
248+
if( NOT BUILD_SHARED_LIBS )
249+
set( CLFFT_STATIC ON )
250+
endif( )
252251
# configure a header file to pass the CMake version settings to the source, and package the header files in the output archive
253252
configure_file( "${PROJECT_SOURCE_DIR}/include/clFFT.version.h.in" "${PROJECT_BINARY_DIR}/include/clFFT.version.h" )
254253
install( FILES
255-
"${PROJECT_BINARY_DIR}/include/clFFT.version.h"
256-
"include/clFFT.h"
257-
"include/clAmdFft.h"
258-
"include/clAmdFft.version.h"
259-
DESTINATION
260-
"./include" )
254+
"${PROJECT_BINARY_DIR}/include/clFFT.version.h"
255+
"include/clFFT.h"
256+
"include/clAmdFft.h"
257+
"include/clAmdFft.version.h"
258+
DESTINATION
259+
"./include" )
261260

262261
# Recurse into subdirectory and start building files there
263262
if( BUILD_RUNTIME AND IS_DIRECTORY "${PROJECT_SOURCE_DIR}/library" )
264263
add_subdirectory( library )
265-
else()
264+
else( )
266265
message( "Runtime library will NOT be built" )
267266
endif( )
268267

@@ -280,7 +279,7 @@ endif( )
280279
# Recurse into subdirectory and start building files there
281280
if( BUILD_LOADLIBRARIES AND IS_DIRECTORY "${PROJECT_SOURCE_DIR}/statTimer" )
282281
add_subdirectory( statTimer )
283-
else()
282+
else( )
284283
message( "LoadLibraries will NOT be built" )
285284
endif( )
286285

@@ -299,27 +298,27 @@ else( )
299298
endif( )
300299

301300
if( BUILD_EXAMPLES )
302-
add_subdirectory( examples )
303-
endif()
301+
add_subdirectory( examples )
302+
endif( )
304303

305-
if(WIN32)
306-
set(destdir CMake)
307-
else()
308-
set(destdir lib${SUFFIX_LIB}/cmake/clFFT)
309-
endif()
310-
string(REGEX REPLACE "[^/]+" ".." reldir "${destdir}")
304+
if( WIN32 )
305+
set( destdir CMake )
306+
else( )
307+
set( destdir lib${SUFFIX_LIB}/cmake/clFFT )
308+
endif( )
309+
string( REGEX REPLACE "[^/]+" ".." reldir "${destdir}" )
311310
configure_file(
312-
${CMAKE_CURRENT_SOURCE_DIR}/clFFTConfigVersion.cmake.in
313-
${CMAKE_CURRENT_BINARY_DIR}/clFFTConfigVersion.cmake
314-
@ONLY)
311+
${CMAKE_CURRENT_SOURCE_DIR}/clFFTConfigVersion.cmake.in
312+
${CMAKE_CURRENT_BINARY_DIR}/clFFTConfigVersion.cmake
313+
@ONLY )
315314
configure_file(
316-
${CMAKE_CURRENT_SOURCE_DIR}/clFFTConfig.cmake.in
317-
${CMAKE_CURRENT_BINARY_DIR}/clFFTConfig.cmake
318-
@ONLY)
319-
install(EXPORT Library DESTINATION ${destdir} FILE clFFTTargets.cmake)
320-
install(FILES ${CMAKE_CURRENT_BINARY_DIR}/clFFTConfigVersion.cmake
321-
${CMAKE_CURRENT_BINARY_DIR}/clFFTConfig.cmake
322-
DESTINATION ${destdir})
315+
${CMAKE_CURRENT_SOURCE_DIR}/clFFTConfig.cmake.in
316+
${CMAKE_CURRENT_BINARY_DIR}/clFFTConfig.cmake
317+
@ONLY )
318+
install( EXPORT Library DESTINATION ${destdir} FILE clFFTTargets.cmake )
319+
install( FILES ${CMAKE_CURRENT_BINARY_DIR}/clFFTConfigVersion.cmake
320+
${CMAKE_CURRENT_BINARY_DIR}/clFFTConfig.cmake
321+
DESTINATION ${destdir} )
323322

324323
# The following code is setting variables to control the behavior of CPack to generate our
325324
if( WIN32 )
@@ -331,18 +330,18 @@ else( )
331330
endif( )
332331

333332
if( BUILD64 )
334-
set( CPACK_PACKAGE_FILE_NAME "${CMAKE_PROJECT_NAME}-${CLFFT_VERSION}-${CMAKE_HOST_SYSTEM_NAME}-x64")
333+
set( CPACK_PACKAGE_FILE_NAME "${CMAKE_PROJECT_NAME}-${CLFFT_VERSION}-${CMAKE_HOST_SYSTEM_NAME}-x64" )
335334
else( )
336-
set( CPACK_PACKAGE_FILE_NAME "${CMAKE_PROJECT_NAME}-${CLFFT_VERSION}-${CMAKE_HOST_SYSTEM_NAME}-x32")
335+
set( CPACK_PACKAGE_FILE_NAME "${CMAKE_PROJECT_NAME}-${CLFFT_VERSION}-${CMAKE_HOST_SYSTEM_NAME}-x32" )
337336
endif( )
338337

339-
set( CPACK_SOURCE_PACKAGE_FILE_NAME "${CMAKE_PROJECT_NAME}-${CLFFT_VERSION}-${CMAKE_HOST_SYSTEM_NAME}-Source")
338+
set( CPACK_SOURCE_PACKAGE_FILE_NAME "${CMAKE_PROJECT_NAME}-${CLFFT_VERSION}-${CMAKE_HOST_SYSTEM_NAME}-Source" )
340339

341340
set( CPACK_PACKAGE_VERSION_MAJOR ${CLFFT_VERSION_MAJOR} )
342341
set( CPACK_PACKAGE_VERSION_MINOR ${CLFFT_VERSION_MINOR} )
343342
set( CPACK_PACKAGE_VERSION_PATCH ${CLFFT_VERSION_PATCH} )
344-
set( CPACK_PACKAGE_DESCRIPTION_SUMMARY "OpenCL implementation of an FFT library")
345-
set( CPACK_PACKAGE_VENDOR "Neutral")
343+
set( CPACK_PACKAGE_DESCRIPTION_SUMMARY "OpenCL implementation of an FFT library" )
344+
set( CPACK_PACKAGE_VENDOR "Neutral" )
346345
set( CPACK_SOURCE_IGNORE_FILES "/\\\\.hg/;/\\\\.svn/;/\\\\.git/" )
347346

348347
# Define all variables that influence CPack before including CPack, such as install targets

0 commit comments

Comments
 (0)