# $Id$ PNAME="hwinfo" PVER="21.56" PBUILD="r1" PCAT="sys-apps" DESCRIPTION="hwinfo is the hardware detection tool used in SuSE Linux." HOMEPAGE="http://www.suse.com/" DEPEND=">= sys-libs/libx86emu-1.1" SDEPEND=">= sys-apps/dbus-1.10" SRCFILE="${PVER}.tar.gz" SRCDIR="${BUILDDIR}/${PNAME}-${PVER}" sminclude mtools SRC_URI=( https://github.com/openSUSE/${PNAME}/archive/${SRCFILE} mirror://${PNAME}/${SRCFILE} mirror://${PNAME}/${PNAME}-18.1-add-intel-pineview-x11-drivers-i386.patch mirror://${PNAME}/${PNAME}-18.1-use-r128-module-for-ati-rage-cards-i386.patch mirror://${PNAME}/${PNAME}-18.1-use-mach64-module-for-ati-mach64-cards-i386.patch mirror://${PNAME}/${PNAME}-18.1-add-openchrome-x11-drivers-i386.patch mirror://${PNAME}/${PNAME}-18.5-no-xen.patch mirror://${PNAME}/${PNAME}-18.5-tiocgdev-undefined.patch mirror://${PNAME}/${PNAME}-21.23-add-intel-haswell-ult-intefrated-graphic-controller-x11-drivers-i386-amd64.patch ) UP2SEPERATOR="\/" UP2DATE="updatecmd https://github.com/openSUSE/${PNAME}/releases | highesttarball gz" src_prepare() { munpack ${SRCFILE} || die cd ${SRCDIR} # disable xen checks which are broken atm mpatch ${PNAME}-18.5-no-xen.patch || die # TIOCGDEV isn't supported in the mainline kernel mpatch ${PNAME}-18.5-tiocgdev-undefined.patch || die # add intel pineview to known x11 drivers mpatch -Np1 ${PNAME}-18.1-add-intel-pineview-x11-drivers-i386.patch # use r128 module for all ati rage cards mpatch -Np1 ${PNAME}-18.1-use-r128-module-for-ati-rage-cards-i386.patch # use mach64 module for all ati mach64 cards mpatch -Np1 ${PNAME}-18.1-use-mach64-module-for-ati-mach64-cards-i386.patch || die # add a bunch of via drivers to known x11 drivers mpatch -Np1 ${PNAME}-18.1-add-openchrome-x11-drivers-i386.patch || die # add intel haswell ult graphic support mpatch -Np1 ${PNAME}-21.23-add-intel-haswell-ult-intefrated-graphic-controller-x11-drivers-i386-amd64.patch || die # add missing VERSION echo "${PVER}" > ${SRCDIR}/VERSION || die } src_compile() { cd ${SRCDIR} mmake -j1 EXTRA_FLAGS="${CFLAGS}" LIBDIR=/usr/$(mlibdir) GIT2LOG=true || die } src_install() { cd ${SRCDIR} mmake DESTDIR=${BINDIR} LIBDIR=/usr/$(mlibdir) GIT2LOG=true install || die mkeepdir /var/lib/hardware/udi || die minstallman doc/hwinfo.8 || die minstalldocs Changelog COPYING README VERSION || die # broken Makefile, remove an empty dir rmdir ${BINDIR}/sbin || die }