# $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-dev-1.12 >= sys-libs/libx86emu-dev-1.1" SRCFILE="${PVER}.tar.gz" SRCDIR="${BUILDDIR}/${PNAME}-${PVER}" ALX_PKG_KEEP="etc/conf.d/hwsetup usr/sbin/hwinfo usr/sbin/hwsetup usr/sbin/ddcxinfo-knoppix usr/$(mlibdir)/*.so usr/$(mlibdir)/*.so.* var/lib/hardware" sminclude mtools alx-split EMHW_SVN_REV="2677" EDDCX_REV="1.3" 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 mirror://${PNAME}/emulate-hwsetup.sh-${EMHW_SVN_REV} mirror://${PNAME}/emulate-ddcxinfo-knoppix.sh-${EDDCX_REV} ) 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 using xf86-video-openchrome 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 } alx_generic_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 # install hwsetup emulation script minstalldir /usr/sbin || die minstallexec -s emulate-hwsetup.sh-${EMHW_SVN_REV} /usr/sbin/hwsetup || die # install ddcxinfo emulation script minstalldir /usr/sbin || die minstallexec -s emulate-ddcxinfo-knoppix.sh-${EDDCX_REV} /usr/sbin/ddcxinfo-knoppix || die }