Commit Graph

105 Commits

Author SHA1 Message Date
Violet Purcell
f439598036 Remove LFS64 calls and set _FILE_OFFSET_BITS=64
Musl 1.2.4 made the LFS64 interfaces only available when
_LARGEFILE64_SOURCE is defined, and they will be removed altogether in
Musl 1.2.5. This commit replaces the LFS64 calls with their non-LFS64
versions and defines _FILE_OFFSET_BITS=64, which makes all interfaces
64-bit.

Bug: https://bugs.gentoo.org/905999
2023-06-09 01:43:27 +00:00
Lee Thomason
1dee28e51f setting the version to 9.0.0 2021-06-06 17:10:24 -07:00
Lee Thomason
9c6752a641 setting the version to 8.1.0 2021-05-15 20:21:47 -07:00
Alex Reinking
7df6b3ff4a Overhaul CMake build 2021-05-08 11:30:29 -07:00
Mark Mossberg
4001a468b7 cmake: Use a namespace for the tinyxml2 target in local export
Previously in the locally (cmake build dir) exported cmake script,
there was no namespace, so the targets would directly be available
in the global namespace. Users would do something like:

    include(cmake/tinyxml2Targets.cmake)
    target_link_libraries(main tinyxml2)

Now, a namespace is used (just like the cmake export that is exported
to the system at the `install(EXPORT...)` command at the bottom of this
file. Uses will now look like:

    include(cmake/tinyxml2Targets.cmake)
    target_link_libraries(main tinyxml2::tinyxml2)

This is technically a minor breaking change. It will only affect users
that actually use the *locally* export cmake targets script, which I
expect to be fairly few (note that this is different from the system
exported script). Also, it will only affect users that freshly
build at this commit of tinyxml2, and have the cmake for their
downstream project configured to load it. That cmake will need to be
changed from the first snippet to the second snippet above.
2020-09-27 00:50:23 -04:00
Lee Thomason
1aeb57d26b Merge pull request #823 from c72578/2020-06-17_Fix_pkgconfig_lib_postfix
cmake: Fix debug postfix in pkgconfig file
2020-09-17 13:55:47 -07:00
Lee Thomason
a0ce5527ab Merge pull request #789 from offlinemark/mark/cmake-clean
cmake: Refactor targets export variable and improve comments
2020-09-17 13:28:16 -07:00
Wolfgang Stöggl
1e384d5031 Fix debug postfix in pkgconfig file
CMakeLists.txt uses set(CMAKE_DEBUG_POSTFIX "d") to distinguish
between debug and release lib. Use this postfix also in the
generated tinyxml2.pc file in case of a CMake Debug build.
This results in the following contents of tinyxml2.pc
- Release:
  Libs: -L${libdir} -ltinyxml2
- Debug:
  Libs: -L${libdir} -ltinyxml2d
2020-06-17 06:22:09 +02:00
Owen Rudge
b341e66e3c cmake: Don't export symbols if building static library 2020-06-01 14:57:53 +01:00
Lee Thomason
bf15233ad8 Setting the version to 8.0.0 2020-03-01 17:40:07 -08:00
Mark Mossberg
60e96163ca cmake: Move TARGETS_EXPORT_NAME to top 2019-12-03 22:35:33 +00:00
Mark Mossberg
588c6577dd cmake: Clarify comment around exported cmake script
The `export()` command purely exports a cmake script into the build
directory; it is not related to find_package at all. It is technically
not necessary. The main use case would be a user copying it into their
internal cmake/ dir in their project, and then using `include()`'ing
that file in their cmake.

The `install(EXPORT...` command is what actually generates a cmake
module that is put on the filesystem in a location that can be found by
`find_package` when in config mode.
2019-12-03 22:27:03 +00:00
Mark Mossberg
57cd52b046 cmake: Use TARGETS_EXPORT_NAME var throughout file
Previously, it was totally unused.
2019-12-03 17:11:43 -05:00
Mark Mossberg
e86e947cb2 cmake: Use CMAKE_PROJECT_NAME instead of PROJECT_NAME
This is consistent with other usages of the file.
PROJECT_NAME is only useful if there are subprojects, and there
aren't any here.
2019-12-03 17:09:24 -05:00
Lee Thomason
ff61650517 Merge branch 'master' of github.com:leethomason/tinyxml2 2019-08-10 18:05:53 -07:00
Lee Thomason
9c740e8d23 setting the version to 7.1.0 2019-08-10 18:05:22 -07:00
Lionel Untereiner
d39b13bbb7 Add COMPONENT support at cmake install stage
It enables a per component install / packaging with cmake / cpack (but not mandatory)
2019-07-24 12:56:51 +02:00
Aaron Yong
f5641e5470 CMakeList.txt: fix wrong version
Using find_package() with version argument, CMake return wrong version error. This commit resolves this.
2019-01-15 10:52:59 +08:00
Lee Thomason
de6d164822 fix export issue and cmake. version to 7.0.1 2018-11-17 19:53:46 -08:00
Lee Thomason
397f22581b setting the version to 7.0.0 2018-11-06 09:37:43 -08:00
Lee Thomason
b894947c94 Merge pull request #714 from Masadow/pic
Add support for position independant code compilation
2018-11-06 09:08:35 -08:00
Masadow
4be5bc8059 Add support for position independant code compilation 2018-10-09 14:57:44 +02:00
Jacob Schloss
ade41cdfe9 Make resources folder for xml test relative to current source and binary directory 2018-09-20 13:27:40 -07:00
orbitcowboy
22b21ec9bc Fixed typos in comments. There are no functional changes intended. 2018-07-17 11:52:57 +02:00
Lee Thomason
9f14aca07f Merge pull request #645 from jasjuang/master
fix sidenote on issue #588
2018-06-29 15:48:03 -07:00
Lukas Solanka
1b029f2bdd add target_compile_definitions 2018-06-25 23:01:22 +01:00
Lukas Solanka
392ec18324 use configure_package_config_file() 2018-06-25 23:01:22 +01:00
Lukas Solanka
b7c169ccbc Replace absolute installation paths with relative 2018-06-25 23:01:22 +01:00
John Butterfield
d89d6d9551 Updated CMakeLists.txt for relocatable installs
Forcing CMAKE_INSTALL_LIBDIR and CMAKE_INSTALL_INCLUDEDIR to be absolute is unnecessary and results in absolute paths in the installation. This prevents relocatable prefix installations.
2018-06-20 18:58:09 -07:00
John Butterfield
b54cf3cb45 Made CMakeLists.txt installation relocatable.
The installation interface should really be a relative path.
2018-06-20 18:52:24 -07:00
Lee Thomason
c1424ee4e1 setting the version to 6.2.0 2018-04-05 23:09:23 -07:00
jasjuang
ecbc16ae48 add namespace for cmake export 2018-03-23 09:52:19 -07:00
mschmieder
3c9370561c fixed issue where CTest is executed in the wrong directory 2018-03-08 08:31:12 +01:00
François Cami
59785ec384 fix installation path for *.cmake 2018-01-22 23:58:42 +01:00
Peter Matula
50689919b7 rename DEBUG define to TINYXML2_DEBUG
The original name is to general. This prevents possible name collisions with other defines, enums, etc. from projects where tinyxml2 is used.
2018-01-09 12:52:26 +01:00
Lee Thomason
f26a547fdc sync the version 2017-12-29 09:30:39 -08:00
Lee Thomason
8c8293ba89 setting the version to 6.0.0 2017-12-10 19:55:35 -08:00
Lee Thomason
37bc3aca42 upping the version to 5.0.1 to fix release vs. source problem 2017-06-26 16:56:16 -07:00
Lee Thomason
563ee82093 Merge pull request #571 from hyperair/cmake-add-test
Use CTest to add xmltest as a testcase so `make test` works
2017-06-26 16:40:06 -07:00
Chow Loong Jin
5381145957 Use CTest to add xmltest as a testcase so make test works 2017-06-22 01:14:07 +08:00
jasjuang
a5ab98a582 fix issue #516 2017-06-20 17:25:42 -07:00
Robert J
dfcf5488ea CMake fix for static library only build 2017-06-20 13:41:17 +02:00
jasjuang
f66441e3e7 add in support for cmake export, manual Findtinyxml2.cmake is no longer needed 2017-06-01 17:25:30 -07:00
Lee Thomason
7538286750 Merge pull request #535 from jnguyen75/build-tests-option
Added BUILD_TESTS option to enable/disable xmltest
2017-05-18 20:57:41 -07:00
Jimmy Nguyen
105f32f64d Merge remote-tracking branch 'origin/master' into build-tests-option 2017-05-11 16:19:30 -07:00
Brad Anderson
9333cfd394 Add "d" library suffix for debug builds 2017-05-04 12:25:56 -06:00
Lee Thomason
7b40ce1942 Merge pull request #534 from jnguyen75/ref-test-resources
Refactor test resources: Use CMake to replace mkdir()
2017-04-28 11:21:39 -07:00
Jimmy Nguyen
1e0b4e6b8a Use generator expression to specify target output directory for resources directory 2017-02-21 12:31:23 -08:00
Jimmy Nguyen
6bf64fb149 Use CMake to create resources/out directory 2017-02-21 12:00:38 -08:00
Jimmy Nguyen
47c7d70064 Added BUILD_TESTS option to enable/disable building of xmltest 2017-02-21 11:29:24 -08:00