Debian Codegraph @

mklove/modules/configure.builtin

raw
1 #!/bin/bash
2 #
3 # mklove builtin checks and options
4 # Sets:
5 # prefix, etc..
6
7
8 mkl_option "Standard" prefix "--prefix=PATH" \
9 "Install arch-independent files in PATH" "/usr/local"
10 mkl_option "Standard" exec_prefix "--exec-prefix=PATH" \
11 "Install arch-dependent files in PATH" "\$prefix"
12 mkl_option "Standard" bindir "--bindir=PATH" "User executables" "\$exec_prefix/bin"
13 mkl_option "Standard" sbindir "--sbindir=PATH" "System admin executables" \
14 "\$exec_prefix/sbin"
15 mkl_option "Standard" libexecdir "--libexecdir=PATH" "Program executables" \
16 "\$exec_prefix/libexec"
17 mkl_option "Standard" datadir "--datadir=PATH" "Read-only arch-independent data" \
18 "\$prefix/share"
19 mkl_option "Standard" sysconfdir "--sysconfdir=PATH" "Configuration data" \
20 "\$prefix/etc"
21 mkl_option "Standard" sharedstatedir "--sharedstatedir=PATH" \
22 "Modifiable arch-independent data" "\$prefix/com"
23 mkl_option "Standard" localstatedir "--localstatedir=PATH" \
24 "Modifiable local state data" "\$prefix/var"
25 mkl_option "Standard" runstatedir "--runstatedir=PATH" \
26 "Modifiable per-process data" "\$prefix/var/run"
27 mkl_option "Standard" libdir "--libdir=PATH" "Libraries" "\$exec_prefix/lib"
28 mkl_option "Standard" includedir "--includedir=PATH" "C/C++ header files" \
29 "\$prefix/include"
30 mkl_option "Standard" infodir "--infodir=PATH" "Info documentation" "\$prefix/info"
31 mkl_option "Standard" mandir "--mandir=PATH" "Manual pages" "\$prefix/man"
32
33 mkl_option "Configure tool" "" "--list-modules" "List loaded mklove modules"
34 mkl_option "Configure tool" "" "--list-checks" "List checks"
35 mkl_option "Configure tool" env:MKL_FAILFATAL "--fail-fatal" "All failures are fatal"
36 mkl_option "Configure tool" env:MKL_NOCACHE "--no-cache" "Dont use or generate config.cache"
37 mkl_option "Configure tool" env:MKL_DEBUG "--debug" "Enable configure debugging"
38 mkl_option "Configure tool" env:MKL_CLEAN "--clean" "Remove generated configure files"
39 mkl_option "Configure tool" "" "--reconfigure" "Rerun configure with same arguments as last run"
40 mkl_option "Configure tool" env:MKL_NO_DOWNLOAD "--no-download" "Disable downloads of required mklove modules"
41 mkl_option "Configure tool" env:MKL_UPDATE_MODS "--update-modules" "Update modules from global repository"
42 mkl_option "Configure tool" env:MKL_REPO_URL "--repo-url=URL_OR_PATH" "Override mklove modules repo URL" "$MKL_REPO_URL"
43 mkl_option "Configure tool" "" "--help" "Show configure usage"
44
45
46 # These autoconf compatibility options are ignored by mklove
47 mkl_toggle_option "Compatibility" "mk:COMPAT_MAINT_MODE" "--enable-maintainer-mode" "Maintainer mode (no-op)"
48 mkl_option "Compatibility" "mk:PROGRAM_PREFIX" "--program-prefix=PFX" "Program prefix (no-op)"
49 mkl_option "Compatibility" "mk:COMPAT_DISABLE_DEP_TRACK" "--disable-dependency-tracking" "Disable dependency tracking (no-op)"
50 mkl_option "Compatibility" "mk:COMPAT_DISABLE_SILENT_RULES" "--disable-silent-rules" "Verbose build output (no-op)"
51 mkl_option "Compatibility" "mk:COMPAT_SILENT" "--silent" "Less verbose build output (no-op)"
52 mkl_toggle_option "Compatibility" "mk:COMPAT_ENABLE_SHARED" "--enable-shared" "Build shared library (no-op)"
53 mkl_toggle_option "Compatibility" "mk:COMPAT_DISABLE_OPT_CHECK" '--enable-option-checking=*' "Disable configure option checking (no-op)"
54
55
56 mkl_option "Dependency" env:MKL_INSTALL_DEPS "--install-deps" "Attempt to install missing dependencies"
57 mkl_option "Dependency" env:MKL_SOURCE_DEPS_ONLY "--source-deps-only" "Only perform source builds of dependencies, not using any package managers"
58
59
60 function checks {
61
62 if [[ ! -z $libdir ]]; then
63 mkl_mkvar_append "libdir" LDFLAGS "-L${libdir}"
64 fi
65
66 if [[ ! -z $includedir ]]; then
67 mkl_mkvar_append "includedir" CPPFLAGS "-I${includedir}"
68 fi
69
70 }