From e56b2dce7e89a92e1b9b35caa13b3e938c4cedea Mon Sep 17 00:00:00 2001 From: Cole Mickens Date: Sun, 26 Jan 2020 01:27:08 -0800 Subject: [PATCH] CMakeLists.txt: output date.pc for pkg-config --- CMakeLists.txt | 15 +++++++++++++++ date.pc.in | 10 ++++++++++ 2 files changed, 25 insertions(+) create mode 100644 date.pc.in diff --git a/CMakeLists.txt b/CMakeLists.txt index f30c473..fe778e8 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -128,6 +128,15 @@ if( BUILD_TZ_LIB ) endif( ) endif( ) +if ( BUILD_TZ_LIB ) + # Cflags: -I${includedir} @TZ_COMPILE_DEFINITIONS@ + set( TZ_COMPILE_DEFINITIONS "$,-D$, -D>,>" ) + configure_file(date.pc.in date.pc.cf @ONLY) + file( GENERATE OUTPUT "${CMAKE_CURRENT_BINARY_DIR}/date.pc" + INPUT "${CMAKE_CURRENT_BINARY_DIR}/date.pc.cf" ) + +endif( ) + #[===================================================================[ installation #]===================================================================] @@ -171,6 +180,12 @@ install ( FILES cmake/dateConfig.cmake "${version_config}" DESTINATION ${CONFIG_LOC}) +if ( BUILD_TZ_LIB ) + install( + FILES ${CMAKE_BINARY_DIR}/date.pc + DESTINATION ${CMAKE_INSTALL_LIBDIR}/pkgconfig) +endif( ) + #[===================================================================[ testing #]===================================================================] diff --git a/date.pc.in b/date.pc.in new file mode 100644 index 0000000..b9c4623 --- /dev/null +++ b/date.pc.in @@ -0,0 +1,10 @@ +prefix=@CMAKE_INSTALL_PREFIX@ +exec_prefix=@CMAKE_INSTALL_BINDIR@ +libdir=@CMAKE_INSTALL_LIB@ +includedir=@CMAKE_INSTALL_INCLUDE@ + +Name: date +Description: A date and time library based on the C++11/14/17 header +Version: @PACKAGE_VERSION@ +Libs: -L${libdir} -ltz +Cflags: -I${includedir} @TZ_COMPILE_DEFINITIONS@
AgeCommit message (Collapse)Author
2022-06-04nls: Update translations.Julien Lepiller
po/packages/tr.po: New file. po/packages/LINGUAS: Add it.
2022-04-02nls: Update translations.Julien Lepiller
* po/packages/fi.po: New file. * po/packages/LINGUAS: Add it.
2021-09-02nls: Update translations.Julien Lepiller
* po/packages/it.po: New file. * po/packages/LINGUAS: Add `it'. * po/*/*.po: Update translations.
2021-05-10nls: New nl and oc translations for the 'packages' component.Maxim Cournoyer
* po/packages/nl.po: New file. * po/packages/oc.po: Likewise. * po/packages/LINGUAS: Register them.
2021-04-18nls: Remove 'vi' in LINGUASJulien Lepiller
The po file is no longer available. * po/packages/LINGUAS: Remove 'vi'.
2021-04-18nls: Add Korean translation.Julien Lepiller
* po/doc/guix-cookbook.ko.po: New file. * po/doc/guix-manual.ko.po: New file. * doc/local.mk (info_TEXINFOS): Add them. * po/doc/local.mk (DOC_PO_FILES, DOC_COOKBOOK_PO_FILES): Add them. * po/guix/ko.po: New file. * po/guix/LINGUAS: Add 'ko'. * po/packages/ko.po: New file. * po/packages/LINGUAS: Add 'ko'.
2021-04-18nls: Add Persian translation.Julien Lepiller
* po/packages/fa.po: New file. * po/packages/LINGUAS: Add 'fa'. * po/doc/guix-cookbook.fa.po: New file. * po/doc/guix-manual.fa.po: New file. * po/doc/local.mk (DOC_PO_FILES, DOC_COOKBOOK_PO_FILES): Add them. * doc/local.mk (info_TEXINFOS): Add them.
2021-04-18nls: Add Slovak translation.Julien Lepiller
* po/packages/sk.po: New file. * po/packages/LINGUAS: Add 'sk'. * po/doc/guix-manual.sk.po: New file. * doc/local.mk (info_TEXINFOS): Add it. * po/doc/local.mk (DOC_PO_FILES): Add it.