--- trunk/extras/bcache-tools/bcache-tools-1.0.8-r1.smage2 2019/03/22 23:42:09 32074 +++ trunk/extras/bcache-tools/bcache-tools-1.0.8-r1.smage2 2019/03/22 23:49:49 32075 @@ -11,11 +11,13 @@ DEPEND=">= sys-apps/util-linux-2" +SDEPEND=">= dev-util/pkgconfig-0.25" + SRCFILE="v${PVER}.tar.gz" SRCDIR="${BUILDDIR}/${PNAME}-${PVER}" msetfeature "!check" # no check target in makefile -sminclude mbuild +sminclude mtools udev dracut SRC_URI=( https://github.com/g2p/${PNAME}/archive/${SRCFILE} @@ -32,6 +34,11 @@ # fix CFLAGS and fixed compile issues sed -i -e '/^CFLAGS/s:-O2::' -e '/^CFLAGS/s:-g:-std=gnu89:' Makefile || die + + # fix udev and dracut dir + sed -i -e "s:^\(UDEVLIBDIR=\).*:\1$(mget-udev-dir):" \ + -e "s:^\(DRACUTLIBDIR=\).*:\1$(mget-dracut-dir):" \ + Makefile || die } src_compile() @@ -39,3 +46,20 @@ cd ${SRCDIR} mmake || die } + +src_install() +{ + cd ${SRCDIR} + + # Makefile does not create these + minstalldir /usr/sbin || die + minstalldir /usr/share/man/man8/ || die + minstalldir $(mget-udev-dir)/rules.d || die + + mmake DESTDIR=${BINDIR} install || die + + # we do not support initcpio + mdelete -r /usr/lib/initcpio || die + + minstalldocs COPYING README || die +}