summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorSebastian Pipping <sebastian@pipping.org>2021-05-20 16:07:03 +0200
committerSebastian Pipping <sebastian@pipping.org>2021-05-21 00:14:36 +0200
commit43142f0babc617123bccd2f516223c90ca9e6dbc (patch)
tree7822e623e65533fbf8ed1482861d214bd6bf7882
parent09ec4ff9c14d1859f57efcb1303d666c8232d7a9 (diff)
downloadlibexpat-git-43142f0babc617123bccd2f516223c90ca9e6dbc.tar.gz
cmake/autotools: Fix generated expat-noconfig.cmake for macOS and MinGW
-rw-r--r--expat/Makefile.am3
-rw-r--r--expat/cmake/autotools/expat-noconfig__linux.cmake.in (renamed from expat/cmake/autotools/expat-noconfig.cmake.in)0
-rw-r--r--expat/cmake/autotools/expat-noconfig__macos.cmake.in19
-rw-r--r--expat/cmake/autotools/expat-noconfig__windows.cmake.in19
-rw-r--r--expat/configure.ac6
5 files changed, 46 insertions, 1 deletions
diff --git a/expat/Makefile.am b/expat/Makefile.am
index 49d157aa..6847d083 100644
--- a/expat/Makefile.am
+++ b/expat/Makefile.am
@@ -66,6 +66,9 @@ cmakedir = $(libdir)/cmake/expat-@PACKAGE_VERSION@
_EXTRA_DIST_CMAKE = \
+ cmake/autotools/expat-noconfig__linux.cmake.in \
+ cmake/autotools/expat-noconfig__macos.cmake.in \
+ cmake/autotools/expat-noconfig__windows.cmake.in \
cmake/autotools/expat-package-init.cmake \
cmake/mingw-toolchain.cmake \
\
diff --git a/expat/cmake/autotools/expat-noconfig.cmake.in b/expat/cmake/autotools/expat-noconfig__linux.cmake.in
index 39595048..39595048 100644
--- a/expat/cmake/autotools/expat-noconfig.cmake.in
+++ b/expat/cmake/autotools/expat-noconfig__linux.cmake.in
diff --git a/expat/cmake/autotools/expat-noconfig__macos.cmake.in b/expat/cmake/autotools/expat-noconfig__macos.cmake.in
new file mode 100644
index 00000000..b6b1016c
--- /dev/null
+++ b/expat/cmake/autotools/expat-noconfig__macos.cmake.in
@@ -0,0 +1,19 @@
+#----------------------------------------------------------------
+# Generated CMake target import file.
+#----------------------------------------------------------------
+
+# Commands may need to know the format version.
+set(CMAKE_IMPORT_FILE_VERSION 1)
+
+# Import target "expat::expat" for configuration ""
+set_property(TARGET expat::expat APPEND PROPERTY IMPORTED_CONFIGURATIONS NOCONFIG)
+set_target_properties(expat::expat PROPERTIES
+ IMPORTED_LOCATION_NOCONFIG "${_IMPORT_PREFIX}/@LIBDIR_BASENAME@/libexpat.@SO_MAJOR@.@SO_MINOR@.@SO_PATCH@.dylib"
+ IMPORTED_SONAME_NOCONFIG "@rpath/libexpat.@SO_MAJOR@.dylib"
+ )
+
+list(APPEND _IMPORT_CHECK_TARGETS expat::expat )
+list(APPEND _IMPORT_CHECK_FILES_FOR_expat::expat "${_IMPORT_PREFIX}/@LIBDIR_BASENAME@/libexpat.@SO_MAJOR@.@SO_MINOR@.@SO_PATCH@.dylib" )
+
+# Commands beyond this point should not need to know the version.
+set(CMAKE_IMPORT_FILE_VERSION)
diff --git a/expat/cmake/autotools/expat-noconfig__windows.cmake.in b/expat/cmake/autotools/expat-noconfig__windows.cmake.in
new file mode 100644
index 00000000..66b2f5cb
--- /dev/null
+++ b/expat/cmake/autotools/expat-noconfig__windows.cmake.in
@@ -0,0 +1,19 @@
+#----------------------------------------------------------------
+# Generated CMake target import file.
+#----------------------------------------------------------------
+
+# Commands may need to know the format version.
+set(CMAKE_IMPORT_FILE_VERSION 1)
+
+# Import target "expat::expat" for configuration ""
+set_property(TARGET expat::expat APPEND PROPERTY IMPORTED_CONFIGURATIONS NOCONFIG)
+set_target_properties(expat::expat PROPERTIES
+ IMPORTED_IMPLIB_NOCONFIG "${_IMPORT_PREFIX}/@LIBDIR_BASENAME@/libexpat.dll.a"
+ IMPORTED_LOCATION_NOCONFIG "${_IMPORT_PREFIX}/bin/libexpat-@SO_MAJOR@.dll"
+ )
+
+list(APPEND _IMPORT_CHECK_TARGETS expat::expat )
+list(APPEND _IMPORT_CHECK_FILES_FOR_expat::expat "${_IMPORT_PREFIX}/@LIBDIR_BASENAME@/libexpat.dll.a" "${_IMPORT_PREFIX}/bin/libexpat-@SO_MAJOR@.dll" )
+
+# Commands beyond this point should not need to know the version.
+set(CMAKE_IMPORT_FILE_VERSION)
diff --git a/expat/configure.ac b/expat/configure.ac
index 6ba69a2e..84319d64 100644
--- a/expat/configure.ac
+++ b/expat/configure.ac
@@ -397,11 +397,15 @@ AC_SUBST([AM_LDFLAGS])
dnl updating _EXPAT_OUTPUT_NAME variable to effect the package name in expat.pc file (issue #361)
AC_SUBST(_EXPAT_OUTPUT_NAME, ["$PACKAGE_NAME"])
+AS_CASE("${host_os}",
+ [darwin*], [CMAKE_NOCONFIG_SOURCE=cmake/autotools/expat-noconfig__macos.cmake.in],
+ [mingw*], [CMAKE_NOCONFIG_SOURCE=cmake/autotools/expat-noconfig__windows.cmake.in],
+ [CMAKE_NOCONFIG_SOURCE=cmake/autotools/expat-noconfig__linux.cmake.in])
AC_CONFIG_FILES([Makefile]
[expat.pc]
[cmake/expat-config.cmake]
[cmake/autotools/expat-config-version.cmake]
- [cmake/autotools/expat-noconfig.cmake]
+ [cmake/autotools/expat-noconfig.cmake:${CMAKE_NOCONFIG_SOURCE}]
[doc/Makefile]
[examples/Makefile]
[lib/Makefile]