diff options
author | Corentin Noël <corentin@elementary.io> | 2018-10-05 12:09:19 +0200 |
---|---|---|
committer | Corentin Noël <corentin@elementary.io> | 2018-10-05 12:09:19 +0200 |
commit | b234be9331ae73d414ce6ba214094fe513929170 (patch) | |
tree | ed37597e5ec68abdfbeca824ecd1f25de91bc7df /buildsystems | |
parent | a79d53d71eaf9508f2ef15dc8854fa2e082bcf3e (diff) | |
download | gtk-doc-b234be9331ae73d414ce6ba214094fe513929170.tar.gz |
cmake: do not hardcode the executable path
This allows to use the environment variables to specify the wanted executables
Diffstat (limited to 'buildsystems')
-rw-r--r-- | buildsystems/cmake/GtkDocConfig.cmake (renamed from buildsystems/cmake/GtkDocConfig.cmake.in) | 10 | ||||
-rw-r--r-- | buildsystems/cmake/Makefile.am | 10 | ||||
-rw-r--r-- | buildsystems/cmake/meson.build | 15 |
3 files changed, 8 insertions, 27 deletions
diff --git a/buildsystems/cmake/GtkDocConfig.cmake.in b/buildsystems/cmake/GtkDocConfig.cmake index 9d41696..23f7984 100644 --- a/buildsystems/cmake/GtkDocConfig.cmake.in +++ b/buildsystems/cmake/GtkDocConfig.cmake @@ -36,11 +36,11 @@ include(CMakeParseArguments) set(GTKDOC_FOUND 1) -set(GTKDOC_SCAN_EXE @bindir@/gtkdoc-scan) -set(GTKDOC_SCANGOBJ_EXE @bindir@/gtkdoc-scangobj) -set(GTKDOC_MKDB_EXE @bindir@/gtkdoc-mkdb) -set(GTKDOC_MKHTML_EXE @bindir@/gtkdoc-mkhtml) -set(GTKDOC_FIXXREF_EXE @bindir@/gtkdoc-fixxref) +find_program(GTKDOC_SCAN_EXE gtkdoc-scan) +find_program(GTKDOC_SCANGOBJ_EXE gtkdoc-scangobj) +find_program(GTKDOC_MKDB_EXE gtkdoc-mkdb) +find_program(GTKDOC_MKHTML_EXE gtkdoc-mkhtml) +find_program(GTKDOC_FIXXREF_EXE gtkdoc-fixxref) get_filename_component(_this_dir ${CMAKE_CURRENT_LIST_FILE} PATH) find_file(GTKDOC_SCANGOBJ_WRAPPER GtkDocScanGObjWrapper.cmake PATH ${_this_dir}) diff --git a/buildsystems/cmake/Makefile.am b/buildsystems/cmake/Makefile.am index d4f43b8..cdccd53 100644 --- a/buildsystems/cmake/Makefile.am +++ b/buildsystems/cmake/Makefile.am @@ -1,19 +1,11 @@ EXTRA_DIST = \ - GtkDocConfig.cmake.in \ + GtkDocConfig.cmake \ GtkDocConfigVersion.cmake.in \ GtkDocScanGObjWrapper.cmake CLEANFILES = \ - GtkDocConfig.cmake \ GtkDocConfigVersion.cmake -# Generate this here rather than via configure.ac so that -# bindir is substituted as an expanded path rather than -# using ${exec_prefix} as it would if substituted via -# configure.ac. -GtkDocConfig.cmake: GtkDocConfig.cmake.in - $(SED) -e 's|[@]bindir@|$(bindir)|g' < "$<" > "$@" - cmakedir = $(libdir)/cmake/GtkDoc cmake_DATA = \ GtkDocConfig.cmake \ diff --git a/buildsystems/cmake/meson.build b/buildsystems/cmake/meson.build index b5efe28..2ba7545 100644 --- a/buildsystems/cmake/meson.build +++ b/buildsystems/cmake/meson.build @@ -1,17 +1,5 @@ cmake_in = configuration_data() cmake_in.set('PACKAGE_VERSION', version) -cmake_in.set('bindir', bindir) - -configure_file( - input: 'GtkDocConfig.cmake.in', - output: 'GtkDocConfig.cmake', - configuration: cmake_in, - install: true, - install_dir: join_paths( - cmakedatadir, - 'GtkDoc', - ) -) configure_file( input: 'GtkDocConfigVersion.cmake.in', @@ -25,6 +13,7 @@ configure_file( ) gtkdoc_cmake_data = [ + 'GtkDocConfig.cmake', 'GtkDocScanGObjWrapper.cmake', ] @@ -34,4 +23,4 @@ install_data( cmakedatadir, 'GtkDoc', ) -)
\ No newline at end of file +) |