77 lines
1.8 KiB
Meson
77 lines
1.8 KiB
Meson
project('pkgconf', 'c',
|
|
version : '1.4.0',
|
|
license : 'ISC',
|
|
meson_version : '>=0.40')
|
|
|
|
cc = meson.get_compiler('c')
|
|
|
|
cdata = configuration_data()
|
|
check_headers = [
|
|
['HAVE_DLFCN_H', 'dlfcn.h'],
|
|
['HAVE_INTTYPES_H', 'inttypes.h'],
|
|
['HAVE_MEMORY_H', 'memory.h'],
|
|
['HAVE_STDINT_H', 'stdint.h'],
|
|
['HAVE_STDLIB_H', 'stdlib.h'],
|
|
['HAVE_STRINGS_H', 'strings.h'],
|
|
['HAVE_STRING_H', 'string.h'],
|
|
['HAVE_SYS_STAT_H', 'sys/stat.h'],
|
|
['HAVE_SYS_TYPES_H', 'sys/types.h'],
|
|
['HAVE_UNISTD_H', 'unistd.h'],
|
|
]
|
|
|
|
foreach h : check_headers
|
|
if cc.has_header(h.get(1))
|
|
cdata.set(h.get(0), 1)
|
|
endif
|
|
endforeach
|
|
|
|
check_functions = [
|
|
['HAVE_CYGWIN_CONV_PATH', 'cygwin_conv_path', '#include<sys/cygwin.h>'],
|
|
['HAVE_STRLCAT', 'strlcat', '#include<string.h>'],
|
|
['HAVE_STRLCPY', 'strlcpy', '#include<string.h>'],
|
|
['HAVE_STRNDUP', 'strndup', '#include<string.h>'],
|
|
]
|
|
|
|
foreach f : check_functions
|
|
if cc.has_function(f.get(1), prefix : f.get(2))
|
|
cdata.set(f.get(0), 1)
|
|
endif
|
|
endforeach
|
|
|
|
cdata.set_quoted('SYSTEM_LIBDIR', '/fixme')
|
|
cdata.set_quoted('SYSTEM_INCLUDEDIR', '/fixme')
|
|
cdata.set_quoted('PKG_DEFAULT_PATH', '/fixme')
|
|
cdata.set_quoted('PACKAGE_NAME', 'pkgconf')
|
|
cdata.set_quoted('PACKAGE_VERSION', meson.project_version())
|
|
cdata.set_quoted('PACKAGE_BUGREPORT', 'http://github.com/pkgconf/pkgconf/issues')
|
|
|
|
|
|
|
|
subdir('libpkgconf')
|
|
|
|
libpkgconf = shared_library('pkgconf',
|
|
'libpkgconf/argvsplit.c',
|
|
'libpkgconf/audit.c',
|
|
'libpkgconf/bsdstubs.c',
|
|
'libpkgconf/cache.c',
|
|
'libpkgconf/client.c',
|
|
'libpkgconf/dependency.c',
|
|
'libpkgconf/fileio.c',
|
|
'libpkgconf/fragment.c',
|
|
'libpkgconf/path.c',
|
|
'libpkgconf/pkg.c',
|
|
'libpkgconf/queue.c',
|
|
'libpkgconf/tuple.c',
|
|
install : true,
|
|
version : '2.0.0',
|
|
soversion : '2',
|
|
)
|
|
|
|
pkgconf_bin = executable('pkgconf',
|
|
'main.c',
|
|
'getopt_long.c',
|
|
link_with : libpkgconf,
|
|
install : true)
|
|
|
|
install_man('pkgconf.1')
|