Skip to content

Commit 8371a43

Browse files
Gachapencdunn2001
authored andcommitted
CMake: Remove set(CMAKE_*_OUTPUT_DIRECTORY)
With set(CMAKE_*_OUTPUT_DIRECTORY) when using jsoncpp as a sub project, the parent project's executables and libraries will also be outputed to jsoncpp's directory. By removing this, it is up to the parent projects to decide where to put their and jsoncpp's executables and libraries.
1 parent dc2e1c9 commit 8371a43

File tree

1 file changed

+0
-10
lines changed

1 file changed

+0
-10
lines changed

CMakeLists.txt

Lines changed: 0 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -31,16 +31,6 @@ SET(PACKAGE_INSTALL_DIR lib${LIB_SUFFIX}/cmake
3131
CACHE PATH "Install dir for cmake package config files")
3232
MARK_AS_ADVANCED( RUNTIME_INSTALL_DIR ARCHIVE_INSTALL_DIR INCLUDE_INSTALL_DIR PACKAGE_INSTALL_DIR )
3333

34-
# This ensures shared DLL are in the same dir as executable on Windows.
35-
# Put all executables / libraries are in a project global directory.
36-
SET(CMAKE_ARCHIVE_OUTPUT_DIRECTORY ${PROJECT_BINARY_DIR}/lib
37-
CACHE PATH "Single directory for all static libraries.")
38-
SET(CMAKE_LIBRARY_OUTPUT_DIRECTORY ${PROJECT_BINARY_DIR}/lib
39-
CACHE PATH "Single directory for all dynamic libraries on Unix.")
40-
SET(CMAKE_RUNTIME_OUTPUT_DIRECTORY ${PROJECT_BINARY_DIR}/bin
41-
CACHE PATH "Single directory for all executable and dynamic libraries on Windows.")
42-
MARK_AS_ADVANCED( CMAKE_RUNTIME_OUTPUT_DIRECTORY CMAKE_LIBRARY_OUTPUT_DIRECTORY CMAKE_ARCHIVE_OUTPUT_DIRECTORY )
43-
4434
# Set variable named ${VAR_NAME} to value ${VALUE}
4535
FUNCTION(set_using_dynamic_name VAR_NAME VALUE)
4636
SET( "${VAR_NAME}" "${VALUE}" PARENT_SCOPE)

0 commit comments

Comments
 (0)