Skip to content

Commit

Permalink
CMake files formatted.
Browse files Browse the repository at this point in the history
  • Loading branch information
Beep6581 committed Mar 16, 2018
1 parent f19e482 commit bba76ca
Show file tree
Hide file tree
Showing 2 changed files with 29 additions and 29 deletions.
54 changes: 27 additions & 27 deletions CMakeLists.txt
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
cmake_minimum_required(VERSION 3.4)

CMAKE_POLICY(SET CMP0025 NEW)
cmake_policy(SET CMP0025 NEW)

project(hdrmerge)

Expand Down Expand Up @@ -59,7 +59,7 @@ include_directories(
"${EXIV2_INCLUDE_DIR}"
"${ZLIB_INCLUDE_DIRS}"
"${ALGLIB_INCLUDES}"
)
)

if(NOT(CMAKE_BUILD_TYPE))
set(CMAKE_BUILD_TYPE Release)
Expand All @@ -84,7 +84,7 @@ set(HDRMERGE_VERSION ${HDRMERGE_VERSION_MAJOR}.${HDRMERGE_VERSION_MINOR}.${HDRME
configure_file(
"${PROJECT_SOURCE_DIR}/src/config.h.in"
"${PROJECT_BINARY_DIR}/config.h"
)
)

This comment has been minimized.

Copy link
@Floessie

Floessie Mar 19, 2018

Contributor

@Beep6581 Was that change intended?

This comment has been minimized.

Copy link
@Beep6581

Beep6581 Mar 19, 2018

Author Collaborator

@Floessie it was auto-formatted like that by Vim, which I used to fix a lot of indentation issues with the files in the cmake folder, but I ended up not committing them as that would make diffing changes in future updates more difficult.

I prefer it when the braces are aligned to the left as they were originally, how about you?

This comment has been minimized.

Copy link
@Floessie

Floessie Mar 19, 2018

Contributor

I prefer it when the braces are aligned to the left as they were originally, how about you?

Me, too.

This comment has been minimized.

Copy link
@Beep6581

Beep6581 Mar 19, 2018

Author Collaborator

Ok, will fix.

This comment has been minimized.

This comment has been minimized.

Copy link
@Floessie

Floessie Mar 19, 2018

Contributor

@Beep6581 Perfect! 👍


# add the binary tree to the search path for include files so that we will find config.h
include_directories("${PROJECT_BINARY_DIR}")
Expand All @@ -97,7 +97,7 @@ if(WIN32)
configure_file(
"${PROJECT_SOURCE_DIR}/data/winres.rc"
"${PROJECT_BINARY_DIR}/winres.rc"
)
)
set(PLATFORM_SOURCES "${PROJECT_BINARY_DIR}/winres.rc")
elseif(APPLE)
set(PLATFORM MACOSX_BUNDLE)
Expand All @@ -123,7 +123,7 @@ set(hdrmerge_sources
src/BoxBlur.cpp
src/ExifTransfer.cpp
src/ImageIO.cpp
)
)

set(hdrmerge_gui_sources
src/AboutDialog.cpp
Expand All @@ -132,7 +132,7 @@ set(hdrmerge_gui_sources
src/DraggableScrollArea.cpp
src/DngPropertiesDialog.cpp
src/LoadOptionsDialog.cpp
)
)

set(hdrmerge_qobject_headers
src/MainWindow.hpp
Expand All @@ -141,11 +141,11 @@ set(hdrmerge_qobject_headers
src/DraggableScrollArea.hpp
src/DngPropertiesDialog.hpp
src/AboutDialog.hpp
)
)

set(hdrmerge_translations
data/hdrmerge_es.ts
)
)

if(WIN32)
set(alglib_sources
Expand All @@ -162,7 +162,7 @@ if(WIN32)
${ALGLIB_ROOT}/src/solvers.cpp
${ALGLIB_ROOT}/src/specialfunctions.cpp
${ALGLIB_ROOT}/src/statistics.cpp
)
)
endif()

if(APPLE)
Expand All @@ -180,15 +180,15 @@ if(APPLE)
${ALGLIB_ROOT}/src/solvers.cpp
${ALGLIB_ROOT}/src/specialfunctions.cpp
${ALGLIB_ROOT}/src/statistics.cpp
)
)
endif()

# Libs
set(hdrmerge_libs
"${LibRaw_r_LIBRARIES}"
"${EXIV2_LIBRARY}"
"${ZLIB_LIBRARIES}"
)
)

if(WIN32)
get_filename_component(LIB_PATH "${EXIV2_LIBRARY}" PATH)
Expand All @@ -204,13 +204,13 @@ if(WIN32)
wsock32
imm32
winmm
)
)
remove_definitions(-DQT_DLL)
else()
set(hdrmerge_libs
"${hdrmerge_libs}"
"${ALGLIB_LIBRARIES}"
)
)
endif()

#QT4_ADD_TRANSLATION(hdrmerge_qm ${hdrmerge_translations})
Expand All @@ -219,24 +219,24 @@ endif()
foreach(file ${hdrmerge_qm})
get_filename_component(basename ${file} NAME)
set(HDRMERGE_QM_XML "${HDRMERGE_QM_XML}
<file>${basename}</file>")
<file>${basename}</file>")
endforeach()

configure_file(
"${PROJECT_SOURCE_DIR}/data/translations.qrc.in"
"${PROJECT_BINARY_DIR}/translations.qrc"
)
)

if(WIN32)
add_library(alglib-objects OBJECT
${alglib_sources}
)
)
endif()

if(APPLE)
add_library(alglib-objects OBJECT
${alglib_sources}
)
)
endif()

if(WIN32)
Expand All @@ -249,7 +249,7 @@ if(WIN32)
${hdrmerge_moc}
$<TARGET_OBJECTS:alglib-objects>
"${PLATFORM_SOURCES}"
)
)
elseif(APPLE)
add_executable(hdrmerge ${PLATFORM}
src/main.cpp
Expand All @@ -259,8 +259,8 @@ elseif(APPLE)
${hdrmerge_sources}
${hdrmerge_gui_sources}
${hdrmerge_moc}
"${PLATFORM_SOURCES}"
)
"${PLATFORM_SOURCES}"
)
else()
add_executable(hdrmerge ${PLATFORM}
src/main.cpp
Expand All @@ -271,7 +271,7 @@ else()
${hdrmerge_gui_sources}
${hdrmerge_moc}
"${PLATFORM_SOURCES}"
)
)
endif()

target_link_libraries(hdrmerge ${STRIP} ${hdrmerge_libs} Qt5::Widgets)
Expand All @@ -284,7 +284,7 @@ if(WIN32)
$<TARGET_OBJECTS:hdrmerge-objects>
$<TARGET_OBJECTS:alglib-objects>
"${PLATFORM_SOURCES}"
)
)
target_link_libraries(hdrmerge-nogui ${STRIP} ${hdrmerge_libs})
set_target_properties(hdrmerge-nogui PROPERTIES COMPILE_DEFINITIONS "NO_GUI")
# Create the installer with makensis
Expand All @@ -295,7 +295,7 @@ if(WIN32)
configure_file(
"${PROJECT_SOURCE_DIR}/data/setup.nsi"
"${PROJECT_BINARY_DIR}/setup.nsi" @ONLY
)
)
add_custom_command(OUTPUT ${SETUP_PROG}
COMMAND "${MAKENSIS_EXECUTABLE}" -V2 setup.nsi
MAIN_DEPENDENCY setup.nsi
Expand All @@ -320,12 +320,12 @@ else()
configure_file(
"${PROJECT_SOURCE_DIR}/data/hdrmerge.desktop"
"${PROJECT_BINARY_DIR}/hdrmerge.desktop"
)
)
install(CODE "
execute_process(COMMAND \"${XDG-ICON-RESOURCE_EXECUTABLE}\" install --novendor --size 128 \"${PROJECT_SOURCE_DIR}/data/images/icon.png\" hdrmerge-icon)
execute_process(COMMAND \"${XDG-DESKTOP-MENU_EXECUTABLE}\" install --novendor \"${PROJECT_BINARY_DIR}/hdrmerge.desktop\")"
execute_process(COMMAND \"${XDG-ICON-RESOURCE_EXECUTABLE}\" install --novendor --size 128 \"${PROJECT_SOURCE_DIR}/data/images/icon.png\" hdrmerge-icon)
execute_process(COMMAND \"${XDG-DESKTOP-MENU_EXECUTABLE}\" install --novendor \"${PROJECT_BINARY_DIR}/hdrmerge.desktop\")"

This comment has been minimized.

Copy link
@Floessie

Floessie Mar 19, 2018

Contributor

This looks wrong.

)
endif()
endif()
endif()

if(Boost_FOUND)
Expand Down
4 changes: 2 additions & 2 deletions test/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -9,12 +9,12 @@ set(
testBoxBlur.cpp
testArray2D.cpp
testDngFloatWriter.cpp
)
)

#add_executable(hdrmerge-test ${test_sources} $<TARGET_OBJECTS:hdrmerge-objects> $<TARGET_OBJECTS:hdrmerge-gui-objects>)
add_executable(hdrmerge-test
${test_sources}
)
)

if(APPLE)
target_link_libraries(hdrmerge-test ${hdrmerge_libs} alglib-objects ${Boost_LIBRARIES} Qt5::Widgets)
Expand Down

0 comments on commit bba76ca

Please sign in to comment.