blob: 68c64fdb0432495b06777f4734099ad0ce41746e [file] [log] [blame]
Brad Bishop6e60e8b2018-02-01 10:27:11 -05001SUMMARY = "Kernel based automounter for linux"
2SECTION = "utils"
3LICENSE = "GPL-2.0"
4LIC_FILES_CHKSUM = "file://COPYING;md5=0636e73ff0215e8d672dc4c32c317bb3"
5
Brad Bishopd7bf8c12018-02-25 22:55:05 -05006DEPENDS += "libtirpc flex-native bison-native e2fsprogs openssl libxml2 util-linux cyrus-sasl libnsl2"
Brad Bishop6e60e8b2018-02-01 10:27:11 -05007
8CFLAGS += "-I${STAGING_INCDIR}/tirpc"
9
10inherit autotools-brokensep systemd update-rc.d pkgconfig
11
12SRC_URI = "${KERNELORG_MIRROR}/linux/daemons/autofs/v5/autofs-${PV}.tar.gz \
13 file://autofs-5.0.7-include-linux-nfs.h-directly-in-rpc_sub.patch \
14 file://no-bash.patch \
15 file://cross.patch \
16 file://libtirpc.patch \
17 file://autofs-5.0.7-do-not-check-for-modprobe.patch \
18 file://fix_disable_ldap.patch \
19 file://autofs-5.0.7-fix-lib-deps.patch \
20 file://add-the-needed-stdarg.h.patch \
21 file://using-pkg-config-to-detect-libxml-2.0-and-krb5.patch \
22 file://force-STRIP-to-emtpy.patch \
23 file://remove-bashism.patch \
24 file://fix-the-YACC-rule-to-fix-a-building-failure.patch \
25 file://0001-Define-__SWORD_TYPE-and-_PATH_NSSWITCH_CONF.patch \
26 file://0002-Replace-__S_IEXEC-with-S_IEXEC.patch \
27 file://autofs-5.1.2-libtirpc-as-need.patch \
28 file://pkgconfig-libnsl.patch \
Brad Bishopd7bf8c12018-02-25 22:55:05 -050029 file://0001-modules-lookup_multi.c-Replace-__S_IEXEC-with-S_IEXE.patch \
Brad Bishop6e60e8b2018-02-01 10:27:11 -050030 "
31SRC_URI[md5sum] = "28cf88f99eff553a8500659ba5d45a76"
32SRC_URI[sha256sum] = "0d57e4138c2ec8058ca92164d035546f68ce4af93acb893369993d67c7056a10"
33
34INITSCRIPT_NAME = "autofs"
35INITSCRIPT_PARAMS = "defaults"
36
37# FIXME: modules/Makefile has crappy rules that don't obey LDFLAGS
38#CFLAGS += "${LDFLAGS}"
39
40PACKAGECONFIG[systemd] = "--with-systemd=${systemd_unitdir}/system,--without-systemd,systemd"
41
42PACKAGECONFIG ?= "${@bb.utils.filter('DISTRO_FEATURES', 'systemd', d)}"
43
44EXTRA_OEMAKE = "DONTSTRIP=1"
45EXTRA_OECONF += "--disable-mount-locking \
46 --enable-ignore-busy --with-openldap=no \
47 --with-sasl=no --with-libtirpc \
48 --with-path=${STAGING_BINDIR_NATIVE} \
49"
50CACHED_CONFIGUREVARS = "ac_cv_path_RANLIB=${RANLIB} \
51 ac_cv_path_RPCGEN=rpcgen \
52"
53
54do_configure_prepend () {
55 sed -e "s:filagdir:flagdir:" -i ${S}/configure.in
56 if [ ! -e ${S}/acinclude.m4 ]; then
57 cp ${S}/aclocal.m4 ${S}/acinclude.m4
58 fi
59}
60
61do_install_append () {
62 if [ -d ${D}/run ]; then
63 rmdir ${D}/run
64 fi
65 if [ -d ${D}${localstatedir}/run ]; then
66 rmdir ${D}${localstatedir}/run
67 fi
68}
69SECURITY_CFLAGS = "${SECURITY_NO_PIE_CFLAGS}"
70
71INSANE_SKIP_${PN} = "dev-so"
72
73RPROVIDES_${PN} += "${PN}-systemd"
74RREPLACES_${PN} += "${PN}-systemd"
75RCONFLICTS_${PN} += "${PN}-systemd"
76SYSTEMD_SERVICE_${PN} = "autofs.service"
77