Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
J
json
Project
Overview
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Chen Yisong
json
Commits
d9446b0e
Unverified
Commit
d9446b0e
authored
Jan 14, 2018
by
Niels Lohmann
Committed by
GitHub
Jan 14, 2018
Browse files
Options
Browse Files
Download
Plain Diff
Merge pull request #911 from theodelrieu/fix/cmake_install
Fix/cmake install
parents
06cddd37
5775084f
Hide whitespace changes
Inline
Side-by-side
Showing
8 changed files
with
9 additions
and
4 deletions
+9
-4
.gitignore
.gitignore
+0
-1
CMakeLists.txt
CMakeLists.txt
+8
-2
Makefile
Makefile
+1
-1
CHANGES.md
third_party/amalgamate/CHANGES.md
+0
-0
LICENSE.md
third_party/amalgamate/LICENSE.md
+0
-0
README.md
third_party/amalgamate/README.md
+0
-0
amalgamate.py
third_party/amalgamate/amalgamate.py
+0
-0
config.json
third_party/amalgamate/config.json
+0
-0
No files found.
.gitignore
View file @
d9446b0e
...
@@ -21,4 +21,3 @@ benchmarks/files/numbers/*.json
...
@@ -21,4 +21,3 @@ benchmarks/files/numbers/*.json
cmake-build-debug
cmake-build-debug
test/test-*
test/test-*
third_party/Amalgamate
CMakeLists.txt
View file @
d9446b0e
...
@@ -16,12 +16,12 @@ include(ExternalProject)
...
@@ -16,12 +16,12 @@ include(ExternalProject)
## OPTIONS
## OPTIONS
##
##
option
(
JSON_BuildTests
"Build the unit tests when BUILD_TESTING is enabled."
ON
)
option
(
JSON_BuildTests
"Build the unit tests when BUILD_TESTING is enabled."
ON
)
option
(
JSON_MultipleHeaders
"Use non-amalgamated version of the library."
OFF
)
##
##
## CONFIGURATION
## CONFIGURATION
##
##
set
(
NLOHMANN_JSON_TARGET_NAME
${
PROJECT_NAME
}
)
set
(
NLOHMANN_JSON_TARGET_NAME
${
PROJECT_NAME
}
)
set
(
NLOHMANN_JSON_SOURCE_DIR
"src"
)
set
(
NLOHMANN_JSON_CONFIG_INSTALL_DIR
"lib/cmake/
${
PROJECT_NAME
}
"
)
set
(
NLOHMANN_JSON_CONFIG_INSTALL_DIR
"lib/cmake/
${
PROJECT_NAME
}
"
)
set
(
NLOHMANN_JSON_INCLUDE_INSTALL_DIR
"include"
)
set
(
NLOHMANN_JSON_INCLUDE_INSTALL_DIR
"include"
)
set
(
NLOHMANN_JSON_HEADER_INSTALL_DIR
"
${
NLOHMANN_JSON_INCLUDE_INSTALL_DIR
}
/nlohmann"
)
set
(
NLOHMANN_JSON_HEADER_INSTALL_DIR
"
${
NLOHMANN_JSON_INCLUDE_INSTALL_DIR
}
/nlohmann"
)
...
@@ -31,6 +31,12 @@ set(NLOHMANN_JSON_CMAKE_CONFIG_DIR "${CMAKE_CURRENT_BINARY_DIR}/cmake_c
...
@@ -31,6 +31,12 @@ set(NLOHMANN_JSON_CMAKE_CONFIG_DIR "${CMAKE_CURRENT_BINARY_DIR}/cmake_c
set
(
NLOHMANN_JSON_CMAKE_VERSION_CONFIG_FILE
"
${
NLOHMANN_JSON_CMAKE_CONFIG_DIR
}
/
${
PROJECT_NAME
}
ConfigVersion.cmake"
)
set
(
NLOHMANN_JSON_CMAKE_VERSION_CONFIG_FILE
"
${
NLOHMANN_JSON_CMAKE_CONFIG_DIR
}
/
${
PROJECT_NAME
}
ConfigVersion.cmake"
)
set
(
NLOHMANN_JSON_CMAKE_PROJECT_CONFIG_FILE
"
${
NLOHMANN_JSON_CMAKE_CONFIG_DIR
}
/
${
PROJECT_NAME
}
Config.cmake"
)
set
(
NLOHMANN_JSON_CMAKE_PROJECT_CONFIG_FILE
"
${
NLOHMANN_JSON_CMAKE_CONFIG_DIR
}
/
${
PROJECT_NAME
}
Config.cmake"
)
if
(
JSON_MultipleHeaders
)
set
(
NLOHMANN_JSON_SOURCE_DIR
"develop/"
)
else
()
set
(
NLOHMANN_JSON_SOURCE_DIR
"src/"
)
endif
()
##
##
## TARGET
## TARGET
## create target and add include path
## create target and add include path
...
@@ -40,7 +46,7 @@ add_library(${NLOHMANN_JSON_TARGET_NAME} INTERFACE)
...
@@ -40,7 +46,7 @@ add_library(${NLOHMANN_JSON_TARGET_NAME} INTERFACE)
target_include_directories
(
target_include_directories
(
${
NLOHMANN_JSON_TARGET_NAME
}
${
NLOHMANN_JSON_TARGET_NAME
}
INTERFACE
INTERFACE
$<BUILD_INTERFACE:
${
PROJECT_SOURCE_DIR
}
/
src
>
$<BUILD_INTERFACE:
${
PROJECT_SOURCE_DIR
}
/
${
NLOHMANN_JSON_SOURCE_DIR
}
>
$<INSTALL_INTERFACE:include>
$<INSTALL_INTERFACE:include>
)
)
...
...
Makefile
View file @
d9446b0e
...
@@ -254,7 +254,7 @@ pretty:
...
@@ -254,7 +254,7 @@ pretty:
amalgamate
:
src/json.hpp
amalgamate
:
src/json.hpp
src/json.hpp
:
$(SRCS)
src/json.hpp
:
$(SRCS)
develop/amalgamate/amalgamate.py
-c
develop
/amalgamate/config.json
-s
develop
--verbose
=
yes
third_party/amalgamate/amalgamate.py
-c
third_party
/amalgamate/config.json
-s
develop
--verbose
=
yes
$(MAKE)
pretty
$(MAKE)
pretty
# check if src/json.hpp has been amalgamated from the develop sources
# check if src/json.hpp has been amalgamated from the develop sources
...
...
develop
/amalgamate/CHANGES.md
→
third_party
/amalgamate/CHANGES.md
View file @
d9446b0e
File moved
develop
/amalgamate/LICENSE.md
→
third_party
/amalgamate/LICENSE.md
View file @
d9446b0e
File moved
develop
/amalgamate/README.md
→
third_party
/amalgamate/README.md
View file @
d9446b0e
File moved
develop
/amalgamate/amalgamate.py
→
third_party
/amalgamate/amalgamate.py
100755 → 100644
View file @
d9446b0e
File moved
develop
/amalgamate/config.json
→
third_party
/amalgamate/config.json
View file @
d9446b0e
File moved
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment