name='lib32-lm_sensors' version='3.6.0' release='2' desc='32-bit hardware monitoring library' desc_ru='32-битная библиотека мониторинга оборудования' homepage='https://github.com/lm-sensors/lm-sensors' maintainer='Evgeniy Khramov ' maintainer_ru='Евгений Храмов ' license='GPL-2.0-or-later AND LGPL-2.1-or-later' architectures=('amd64') min_alr_version='v0.0.14' # Runtime dependencies deps=( 'lm_sensors' ) deps_redos=( 'lm_sensors' ) # Build dependencies build_deps=( 'gcc' 'make' 'bison' 'flex' 'glibc-devel.i686' ) build_deps_redos=("${build_deps[@]}") # Provides 32-bit lm_sensors libraries provides=( 'lm_sensors-libs.i686' 'lm_sensors-libs(x86-32)' 'libsensors.so.5' ) conflicts=( 'lm_sensors-libs.i686 < 3.6.0' ) _pkgver="${version}" sources=("https://github.com/lm-sensors/lm-sensors/archive/V${_pkgver//./-}.tar.gz") checksums=('SKIP') prepare() { cd "$srcdir/lm-sensors-${_pkgver//./-}" echo "==> Preparing lm_sensors ${version} (32-bit)..." } build() { cd "$srcdir/lm-sensors-${_pkgver//./-}" export CFLAGS="-m32 -O2 -g1" export CXXFLAGS="-m32 -O2 -g1" export LDFLAGS="-m32" echo "==> Building lm_sensors (32-bit)..." make PREFIX=/usr \ LIBDIR=/usr/lib \ MANDIR=/usr/share/man \ BUILD_STATIC_LIB=0 \ -j$(nproc) \ lib/libsensors.so } package() { cd "$srcdir/lm-sensors-${_pkgver//./-}" echo "==> Installing lm_sensors (32-bit) libraries..." # Install library install -Dm755 lib/libsensors.so.${version} "$pkgdir/usr/lib/libsensors.so.${version}" ln -sf libsensors.so.${version} "$pkgdir/usr/lib/libsensors.so.5" ln -sf libsensors.so.${version} "$pkgdir/usr/lib/libsensors.so" # Install license install -Dm644 COPYING "$pkgdir/usr/share/licenses/$name/COPYING" install -Dm644 COPYING.LGPL "$pkgdir/usr/share/licenses/$name/COPYING.LGPL" echo "==> lm_sensors ${version} (32-bit) installed" } files() { # Find all installed files if [ -d ./usr/lib ]; then find ./usr/lib -type f -printf '%p\n' find ./usr/lib -type l -printf '%p\n' fi if [ -d ./usr/share/licenses ]; then find ./usr/share/licenses -type f -printf '%p\n' fi }