Skip to content
GitLab
Projects
Groups
Snippets
Help
Loading...
Help
What's new
7
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Open sidebar
David Cazier
CGoGN
Commits
39827e0e
Commit
39827e0e
authored
Jan 19, 2015
by
Sylvain Thery
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
tinyxml2 copy in third_party
parent
69b46a46
Changes
7
Expand all
Hide whitespace changes
Inline
Side-by-side
Showing
7 changed files
with
4512 additions
and
28 deletions
+4512
-28
CMakeLists.txt
CMakeLists.txt
+12
-3
ThirdParty/CMakeLists.txt
ThirdParty/CMakeLists.txt
+7
-24
ThirdParty/TinyXml2/CMakeLists.txt
ThirdParty/TinyXml2/CMakeLists.txt
+35
-0
ThirdParty/TinyXml2/readme.txt
ThirdParty/TinyXml2/readme.txt
+9
-0
ThirdParty/TinyXml2/tinyxml2.cpp
ThirdParty/TinyXml2/tinyxml2.cpp
+2318
-0
ThirdParty/TinyXml2/tinyxml2.h
ThirdParty/TinyXml2/tinyxml2.h
+2130
-0
include/Utils/xml.h
include/Utils/xml.h
+1
-1
No files found.
CMakeLists.txt
View file @
39827e0e
cmake_minimum_required
(
VERSION 2.8
)
project
(
CGoGN
)
cmake_policy
(
SET CMP0042 NEW
)
# rpath new policy
#SET ( CMAKE_VERBOSE_MAKEFILE 1 )
...
...
@@ -42,8 +43,15 @@ IF (NOT (${CMAKE_BUILD_TYPE} MATCHES "Debug|Release"))
ENDIF
()
# for shared or not shared
SET
(
BUILD_SHARED_LIBS OFF CACHE BOOL
"if used all library are build as shared type (.so/.dylib/.dll)"
)
# for shared or not shared (default except on windows)
if
(
WIN32
)
SET
(
BUILD_SHARED_LIBS OFF CACHE BOOL
"if used all library are build as shared type (.so/.dylib/.dll)"
)
else
()
SET
(
BUILD_SHARED_LIBS ON CACHE BOOL
"if used all library are build as shared type (.so/.dylib/.dll)"
)
endif
()
#IF(EXISTS "${CGoGN_ROOT_DIR}/ThirdParty/include/Assimp")
IF
(
EXISTS
"
${
CGoGN_ROOT_DIR
}
/lib/
${
CMAKE_BUILD_TYPE
}
/*assimp*"
)
...
...
@@ -68,9 +76,10 @@ SET ( COMPILE_BENCHES ON CACHE BOOL "compile benches" )
SET
(
COMPILE_SANDBOX ON CACHE BOOL
"compile all in sandbox"
)
#create one big lib
#create one big lib
SET
(
ONELIB OFF CACHE BOOL
"build CGoGN in one lib"
)
SET
(
WITH_GLEWMX OFF CACHE BOOL
"use multi-contex GLEW"
)
SET
(
USE_OGL_CORE_PROFILE OFF CACHE BOOL
"use OpenGL 3.3 core profile (do not work on mac)"
)
...
...
ThirdParty/CMakeLists.txt
View file @
39827e0e
cmake_minimum_required
(
VERSION 2.8
)
include
(
ExternalProject
)
project
(
CGoGN_ThirdParty
)
# for access to var CMAKE_INSTALL_LIBDIR
include
(
GNUInstallDirs
)
cmake_policy
(
SET CMP0042 NEW
)
# rpath new policy
SET
(
CGoGN_ROOT_DIR
${
CMAKE_SOURCE_DIR
}
/..
)
IF
(
WIN32
)
ENDIF
(
WIN32
)
IF
(
${
CMAKE_CURRENT_BINARY_DIR
}
MATCHES
"(.*)Debug"
)
set
(
CMAKE_BUILD_TYPE
"Debug"
CACHE STRING
"Debug/Release"
FORCE
)
...
...
@@ -24,29 +18,14 @@ IF(WIN32)
INCLUDE_DIRECTORIES
(
${
CGoGN_ROOT_DIR
}
/windows_dependencies/include/suitesparse
)
SET
(
LIBRARY_OUTPUT_PATH
${
CGoGN_ROOT_DIR
}
/lib
)
set
(
CMAKE_CONFIGURATION_TYPES Release Debug
)
SET
(
BUILD_SHARED_LIBS OFF CACHE BOOL
"if used all library are build as shared type (.so/.dylib/.dll)"
)
ELSE
()
SET
(
LIBRARY_OUTPUT_PATH
${
CGoGN_ROOT_DIR
}
/lib/
${
CMAKE_BUILD_TYPE
}
)
ExternalProject_Add
(
Tinyxml2
PREFIX
${
CMAKE_CURRENT_BINARY_DIR
}
/tinyxml2
GIT_REPOSITORY https://github.com/leethomason/tinyxml2.git
CMAKE_CACHE_ARGS
"-DCMAKE_BUILD_TYPE:string=
${
CMAKE_BUILD_TYPE
}
"
CMAKE_ARGS
"-DCMAKE_INSTALL_PREFIX=
${
CGoGN_ROOT_DIR
}
/ThirdParty/TinyXml2"
BUILD_COMMAND make
INSTALL_COMMAND make install
)
INSTALL
(
DIRECTORY TinyXml2/include/ DESTINATION
${
CGoGN_ROOT_DIR
}
/ThirdParty/include
)
INSTALL
(
DIRECTORY TinyXml2/
${
CMAKE_INSTALL_LIBDIR
}
/ DESTINATION
${
CGoGN_ROOT_DIR
}
/lib/
${
CMAKE_BUILD_TYPE
}
PATTERN
"pkgconfig"
EXCLUDE
)
SET
(
BUILD_SHARED_LIBS ON CACHE BOOL
"if used all library are build as shared type (.so/.dylib/.dll)"
)
ENDIF
()
# for shared or not shared
SET
(
BUILD_SHARED_LIBS OFF CACHE BOOL
"if used all library are build as shared type (.so/.dylib/.dll)"
)
SET
(
WITH_ASSIMP OFF CACHE BOOL
"build with Assimp"
)
SET
(
WITH_ZINRI ON CACHE BOOL
"build with Zinri libs"
)
...
...
@@ -78,3 +57,7 @@ IF (WITH_ASSIMP)
add_subdirectory
(
Assimp Assimp/build
)
INSTALL
(
DIRECTORY Assimp/include/ DESTINATION
${
CGoGN_ROOT_DIR
}
/ThirdParty/include/Assimp
)
ENDIF
(
WITH_ASSIMP
)
add_subdirectory
(
TinyXml2 TinyXml2/build
)
INSTALL
(
DIRECTORY TinyXml2/ DESTINATION
${
CGoGN_ROOT_DIR
}
/ThirdParty/include/TinyXml2 FILES_MATCHING PATTERN
"*.h"
)
ThirdParty/TinyXml2/CMakeLists.txt
0 → 100644
View file @
39827e0e
cmake_minimum_required
(
VERSION 2.6 FATAL_ERROR
)
#cmake_policy(VERSION 2.6)
project
(
tinyxml2
)
include_directories
(
"
${
CMAKE_CURRENT_SOURCE_DIR
}
/."
)
if
(
MSVC
)
add_definitions
(
-D_CRT_SECURE_NO_WARNINGS
)
endif
(
MSVC
)
option
(
BUILD_SHARED_LIBS
"build shared or static libraries"
ON
)
add_library
(
tinyxml2 tinyxml2.cpp tinyxml2.h
)
set_target_properties
(
tinyxml2 PROPERTIES COMPILE_DEFINITIONS
"TINYXML2_EXPORT"
)
#install(TARGETS tinyxml2
# RUNTIME DESTINATION ${CMAKE_INSTALL_BINDIR}
# LIBRARY DESTINATION ${CMAKE_INSTALL_LIBDIR}
# ARCHIVE DESTINATION ${CMAKE_INSTALL_LIBDIR})
#install(FILES tinyxml2.h DESTINATION ${CMAKE_INSTALL_INCLUDEDIR})
#foreach(p LIB INCLUDE)
# set(var CMAKE_INSTALL_${p}DIR)
# if(NOT IS_ABSOLUTE "${${var}}")
# set(${var} "${CMAKE_INSTALL_PREFIX}/${${var}}")
# endif()
#endforeach()
#configure_file(tinyxml2.pc.in tinyxml2.pc @ONLY)
#install(FILES ${CMAKE_CURRENT_BINARY_DIR}/tinyxml2.pc DESTINATION ${CMAKE_INSTALL_LIBDIR}/pkgconfig)
#add_test(xmltest ${SAMPLE_NAME} COMMAND $<TARGET_FILE:${SAMPLE_NAME}>)
ThirdParty/TinyXml2/readme.txt
0 → 100644
View file @
39827e0e
This is a "partial" copy of original TinyXML-2 library.
http://www.grinninglizard.com/tinyxml2/
Packaged version is not usable on all Linux distribution
Git version is not locally installabe on mac.
CMakeLists.txt has been modified for easy local installation.
Only needed files for building the library have been kept.
ThirdParty/TinyXml2/tinyxml2.cpp
0 → 100755
View file @
39827e0e
This diff is collapsed.
Click to expand it.
ThirdParty/TinyXml2/tinyxml2.h
0 → 100755
View file @
39827e0e
This diff is collapsed.
Click to expand it.
include/Utils/xml.h
View file @
39827e0e
...
...
@@ -27,7 +27,7 @@
#include <string>
#include "Utils/cgognStream.h"
#include
<
tinyxml2.h
>
#include
"TinyXml2/
tinyxml2.h
"
namespace
CGoGN
...
...
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