[linux-hotplug@vger.kernel.org],
[udev],
[http://www.kernel.org/pub/linux/utils/kernel/hotplug/udev.html])
-AC_CONFIG_SRCDIR([udev/udevd.c])
+AC_CONFIG_SRCDIR([src/udevd.c])
AC_CONFIG_AUX_DIR([build-aux])
-AM_INIT_AUTOMAKE([check-news foreign 1.11 -Wall -Wno-portability silent-rules tar-pax dist-xz subdir-objects])
+AM_INIT_AUTOMAKE([check-news foreign 1.11 -Wall -Wno-portability silent-rules tar-pax no-dist-gzip dist-xz subdir-objects])
AC_USE_SYSTEM_EXTENSIONS
AC_SYS_LARGEFILE
AC_CONFIG_MACRO_DIR([m4])
AC_SEARCH_LIBS([clock_gettime], [rt], [], [AC_MSG_ERROR([POSIX RT library not found])])
+PKG_CHECK_MODULES(BLKID, blkid >= 2.20)
+
+PKG_CHECK_MODULES(KMOD, libkmod >= 3)
+
+if test "x$cross_compiling" = "xno" ; then
+ AC_CHECK_FILES([/usr/share/pci.ids], [pciids=/usr/share/pci.ids])
+ AC_CHECK_FILES([/usr/share/hwdata/pci.ids], [pciids=/usr/share/hwdata/pci.ids])
+ AC_CHECK_FILES([/usr/share/misc/pci.ids], [pciids=/usr/share/misc/pci.ids])
+fi
+
+AC_ARG_WITH(usb-ids-path,
+ [AS_HELP_STRING([--with-usb-ids-path=DIR], [Path to usb.ids file])],
+ [USB_DATABASE=${withval}],
+ [if test -n "$usbids" ; then
+ USB_DATABASE="$usbids"
+ else
+ PKG_CHECK_MODULES(USBUTILS, usbutils >= 0.82)
+ AC_SUBST([USB_DATABASE], [$($PKG_CONFIG --variable=usbids usbutils)])
+ fi])
+AC_MSG_CHECKING([for USB database location])
+AC_MSG_RESULT([$USB_DATABASE])
+AC_SUBST(USB_DATABASE)
+
+AC_ARG_WITH(pci-ids-path,
+ [AS_HELP_STRING([--with-pci-ids-path=DIR], [Path to pci.ids file])],
+ [PCI_DATABASE=${withval}],
+ [if test -n "$pciids" ; then
+ PCI_DATABASE="$pciids"
+ else
+ AC_MSG_ERROR([pci.ids not found, try --with-pci-ids-path=])
+ fi])
+AC_MSG_CHECKING([for PCI database location])
+AC_MSG_RESULT([$PCI_DATABASE])
+AC_SUBST(PCI_DATABASE)
+
+AC_ARG_WITH([rootprefix],
+ AS_HELP_STRING([--with-rootprefix=DIR], [rootfs directory prefix for config files and kernel modules]),
+ [], [with_rootprefix=${ac_default_prefix}])
+AC_SUBST([rootprefix], [$with_rootprefix])
+
AC_ARG_WITH([rootlibdir],
AS_HELP_STRING([--with-rootlibdir=DIR], [rootfs directory to install shared libraries]),
[], [with_rootlibdir=$libdir])
AC_ARG_WITH(firmware-path,
AS_HELP_STRING([--with-firmware-path=DIR[[[:DIR[...]]]]],
[Firmware search path (default=/lib/firmware/updates:/lib/firmware)]),
- [], [with_firmware_path="/lib/firmware/updates:/lib/firmware"])
+ [], [with_firmware_path="$rootprefix/lib/firmware/updates:$rootprefix/lib/firmware"])
OLD_IFS=$IFS
IFS=:
for i in $with_firmware_path; do
AS_IF([test "x$with_systemdsystemunitdir" != "xno"], [ AC_SUBST([systemdsystemunitdir], [$with_systemdsystemunitdir]) ])
AM_CONDITIONAL(WITH_SYSTEMD, [test -n "$with_systemdsystemunitdir" -a "x$with_systemdsystemunitdir" != "xno" ])
-PKG_CHECK_MODULES(BLKID, blkid >= 2.20)
-
# ------------------------------------------------------------------------------
# GUdev - libudev gobject interface
# ------------------------------------------------------------------------------
AM_CONDITIONAL([ENABLE_INTROSPECTION], [test "x$enable_introspection" = "xyes"])
AM_CONDITIONAL([ENABLE_GUDEV], [test "x$enable_gudev" = "xyes"])
-# ------------------------------------------------------------------------------
-# usb/pci-db - read vendor/device string database
-# ------------------------------------------------------------------------------
-AC_ARG_ENABLE([hwdb],
- AS_HELP_STRING([--disable-hwdb], [disable hardware database support @<:@default=enabled@:>@]),
- [], [enable_hwdb=yes])
-AS_IF([test "x$enable_hwdb" = "xyes"], [
- if test "x$cross_compiling" = "xno" ; then
- AC_CHECK_FILES([/usr/share/pci.ids], [pciids=/usr/share/pci.ids])
- AC_CHECK_FILES([/usr/share/hwdata/pci.ids], [pciids=/usr/share/hwdata/pci.ids])
- AC_CHECK_FILES([/usr/share/misc/pci.ids], [pciids=/usr/share/misc/pci.ids])
- fi
-
- AC_ARG_WITH(usb-ids-path,
- [AS_HELP_STRING([--with-usb-ids-path=DIR], [Path to usb.ids file])],
- [USB_DATABASE=${withval}],
- [if test -n "$usbids" ; then
- USB_DATABASE="$usbids"
- else
- PKG_CHECK_MODULES(USBUTILS, usbutils >= 0.82)
- AC_SUBST([USB_DATABASE], [$($PKG_CONFIG --variable=usbids usbutils)])
- fi])
- AC_MSG_CHECKING([for USB database location])
- AC_MSG_RESULT([$USB_DATABASE])
- AC_SUBST(USB_DATABASE)
-
- AC_ARG_WITH(pci-ids-path,
- [AS_HELP_STRING([--with-pci-ids-path=DIR], [Path to pci.ids file])],
- [PCI_DATABASE=${withval}],
- [if test -n "$pciids" ; then
- PCI_DATABASE="$pciids"
- else
- AC_MSG_ERROR([pci.ids not found, try --with-pci-ids-path=])
- fi])
- AC_MSG_CHECKING([for PCI database location])
- AC_MSG_RESULT([$PCI_DATABASE])
- AC_SUBST(PCI_DATABASE)
-])
-AM_CONDITIONAL([ENABLE_HWDB], [test "x$enable_hwdb" = "xyes"])
-
# ------------------------------------------------------------------------------
# keymap - map custom hardware's multimedia keys
# ------------------------------------------------------------------------------
[], [enable_edd=no])
AM_CONDITIONAL([ENABLE_EDD], [test "x$enable_edd" = "xyes"])
+my_CFLAGS="-Wall \
+-Wmissing-declarations -Wmissing-prototypes \
+-Wnested-externs -Wpointer-arith \
+-Wpointer-arith -Wsign-compare -Wchar-subscripts \
+-Wstrict-prototypes -Wshadow \
+-Wformat-security -Wtype-limits"
+AC_SUBST([my_CFLAGS])
+
AC_CONFIG_HEADERS(config.h)
AC_CONFIG_FILES([
Makefile
- libudev/docs/Makefile
- libudev/docs/version.xml
- extras/gudev/docs/Makefile
- extras/gudev/docs/version.xml
+ src/docs/Makefile
+ src/docs/version.xml
+ src/extras/gudev/docs/Makefile
+ src/extras/gudev/docs/version.xml
])
AC_OUTPUT
========
prefix: ${prefix}
+ rootprefix: ${rootprefix}
sysconfdir: ${sysconfdir}
bindir: ${bindir}
- sbindir: ${sbindir}
libdir: ${libdir}
rootlibdir: ${rootlib_execdir}
libexecdir: ${libexecdir}
include_prefix: ${INCLUDE_PREFIX}
systemdsystemunitdir: ${systemdsystemunitdir}
firmware path: ${FIRMWARE_PATH}
+ usb.ids: ${USB_DATABASE}
+ pci.ids: ${PCI_DATABASE}
compiler: ${CC}
cflags: ${CFLAGS}
gudev: ${enable_gudev}
gintrospection: ${enable_introspection}
keymap: ${enable_keymap}
- hwdb: ${enable_hwdb}
- usb.ids: ${USB_DATABASE}
- pci.ids: ${PCI_DATABASE}
mtd_probe: ${enable_mtd_probe}
rule_generator: ${enable_rule_generator}
udev_acl: ${enable_udev_acl}