aboutsummaryrefslogtreecommitdiffstats
path: root/main/lm_sensors/APKBUILD
diff options
context:
space:
mode:
authorNatanael Copa <ncopa@alpinelinux.org>2009-07-24 08:01:31 +0000
committerNatanael Copa <ncopa@alpinelinux.org>2009-07-24 08:01:31 +0000
commitb70981b68efcce5256eb11c6cd26ae123b10b6ea (patch)
treea38be6efae5e2ba15c2e839504632f9b7bfd5f91 /main/lm_sensors/APKBUILD
parent2b4df81538b8398442d5296650905c70341dd8d3 (diff)
downloadaports-b70981b68efcce5256eb11c6cd26ae123b10b6ea.tar.gz
aports-b70981b68efcce5256eb11c6cd26ae123b10b6ea.tar.bz2
aports-b70981b68efcce5256eb11c6cd26ae123b10b6ea.tar.xz
moved extra/* to main/
and fixed misc build issues
Diffstat (limited to 'main/lm_sensors/APKBUILD')
-rw-r--r--main/lm_sensors/APKBUILD63
1 files changed, 63 insertions, 0 deletions
diff --git a/main/lm_sensors/APKBUILD b/main/lm_sensors/APKBUILD
new file mode 100644
index 0000000000..0327dc7751
--- /dev/null
+++ b/main/lm_sensors/APKBUILD
@@ -0,0 +1,63 @@
+# Maintainer: Natanael Copa <ncopa@alpinelinux.org>
+pkgname=lm_sensors
+pkgver=3.1.1
+pkgrel=0
+pkgdesc="Collection of user space tools for general SMBus access and hardware monitoring."
+url="http://www.lm-sensors.org/"
+license="GPL"
+depends="sysfsutils rrdtool"
+makedepends="perl rrdtool-dev bison flex"
+subpackages="$pkgname-dev $pkgname-doc $pkgname-detect"
+#install=sensors.install
+source="http://dl.lm-sensors.org/lm-sensors/releases/$pkgname-$pkgver.tar.bz2
+ lm_sensors-3.1.0-sensors-detect-alpine.patch
+ fancontrol.initd
+ lm_sensors.initd
+ sensord.confd
+ sensord.initd
+ "
+
+build ()
+{
+ cd "$srcdir"/$pkgname-$pkgver
+
+ sed -i -e 's:^# \(PROG_EXTRA\):\1:' Makefile
+ # Respect LDFLAGS
+ sed -i -e 's/\$(LIBDIR)$/\$(LIBDIR) \$(LDFLAGS)/g' Makefile
+ sed -i -e 's/\$(LIBSHSONAME) -o/$(LIBSHSONAME) \$(LDFLAGS) -o/g' \
+ lib/Module.mk
+
+ export CFLAGS="$CFLAGS -fno-stack-protector"
+
+ for i in ../*.patch; do
+ msg "Applying $i"
+ patch -p1 < $i || return 1
+ done
+ make PREFIX=/usr user || return 1
+ make user_install \
+ PREFIX=/usr \
+ MANDIR=/usr/share/man \
+ DESTDIR="$pkgdir" || return 1
+
+ cd "$srcdir"
+ install -Dm755 fancontrol.initd "$pkgdir"/etc/init.d/fancontrol
+ install -Dm755 lm_sensors.initd "$pkgdir"/etc/init.d/lm_sensors
+ install -Dm755 sensord.initd "$pkgdir"/etc/init.d/sensord
+ install -Dm755 sensord.confd "$pkgdir"/etc/conf.d/sensord
+}
+
+detect() {
+ depends="perl"
+ pkgdesc="Detection/migration scripts for lm_sensors"
+ mkdir -p "$subpkgdir"/usr/bin "$subpkgdir"/usr/sbin
+ cd "$pkgdir"
+ mv usr/bin/sensors-conf-convert "$subpkgdir"/usr/bin/
+ mv usr/sbin/sensors-detect "$subpkgdir"/usr/bin/
+}
+
+md5sums="613d7cfa23b70c0abae3fabb0a72ff5f lm_sensors-3.1.1.tar.bz2
+b6e7de1a1768f7a6ea2e00c226331877 lm_sensors-3.1.0-sensors-detect-alpine.patch
+58f4c9193a903711ace7fa0754693bd2 fancontrol.initd
+2c7e97203da2c39bc9fbfc2a4849cfd4 lm_sensors.initd
+82e075236a61334abb3adf46280380d3 sensord.confd
+6f3a880988e7cdbcb20870e3c6d1e554 sensord.initd"