#!/bin/sh # test we are root if [ "$(id -u)" != "0" ]; then exit 1 fi export CFLAGS="-mtune=generic -Os -pipe" export CXXFLAGS="-mtune=generic -Os -pipe -fno-exceptions -fno-rtti" P=libid3tag V=0.16.3 SRC=$P-$V USER=`cat /etc/sysconfig/tcuser` LIST="compiletc submitqc cmake " for Z in $LIST do su -c "tce-load -i $Z" $USER done cd /tmp su -c "/usr/local/bin/wget -nc --no-check-certificate \ https://codeberg.org/tenacityteam/$P/archive/$V.tar.gz " $USER tar xvf $V*gz mv $P $SRC cd $SRC cmake -DCMAKE_INSTALL_PREFIX=/usr/local -S . -B build cmake --build build --parallel 4 # seconds cmake --install build # installs names pathways cd /tmp # dev ##### mkdir -p $P-dev/usr/local/lib/pkgconfig mkdir -p $P-dev/usr/local/include mv /usr/local/include/id3tag.h $P-dev/usr/local/include mv /usr/local/lib/pkgconfig/id3tag.pc $P-dev/usr/local/lib/pkgconfig mv /usr/local/lib/cmake $P-dev/usr/local/lib # main ###### mkdir -p $P/usr/local/share/doc/$P echo 'GPL v2' > $P/usr/local/share/doc/$P/COPYING mkdir -p $P/usr/local/lib mv /usr/local/lib/$P* $P/usr/local/lib strip --strip-unneeded $P/usr/local/lib/libid3tag.so.0.16.3 # TCZ them ########### LIST2="$P $P-dev " for Z in $LIST2 do mksquashfs $Z $Z.tcz md5sum $Z.tcz > $Z.tcz.md5.txt cd $Z find usr -not -type d > /tmp/$Z.tcz.list sed 's|usr|/usr|g' -i /tmp/$Z.tcz.list cd /tmp done ls -hal echo 'Title: libid3tag-dev.tcz Description: dev files Version: 0.16.3 Author: Underbit Technologies, Inc Original-site: https://codeberg.org/tenacityteam/libid3tag Copying-policy: GPL v2 Size: 8.0K Extension_by: aus9 @ linuxquestions.org Tags: id3 tag audio music Comments: Development Change-log: 2016/05/12 v 0.15.1b on 7x (Juanito) Current: 2024/04/25 v 0.16.3 on 15x (aus9) ' > $P-dev.tcz.info echo 'libid3tag.tcz ' > $P-dev.tcz.dep echo 'Title: libid3tag.tcz Description: id3 tag library Version: 0.16.3 Author: Underbit Technologies, Inc Original-site: https://codeberg.org/tenacityteam/libid3tag Copying-policy: GPL v2 Size: 36K Extension_by: aus9 @ linuxquestions.org Tags: id3 tag audio music Comments: library for reading and writing ID3 tags, both ID3v1 and ID3v2 Change-log: 2016/05/12 v 0.15.1b on 7x (Juanito) Current: 2024/04/25 v 0.16.3 on 15x (aus9) ' > $P.tcz.info readelf -d $P/usr/local/lib/*.so | grep 'NEEDED' # no dep submitqc --libs rm -rf *.zsync