wok-6.x view pifmrds/receipt @ rev 23963
Up curl (7.72.0)
author | Pascal Bellard <pascal.bellard@slitaz.org> |
---|---|
date | Fri Oct 02 10:34:57 2020 +0000 (2020-10-02) |
parents | 88c057127e4a |
children | 89c8d8b6cf48 |
line source
1 # SliTaz package receipt.
3 PACKAGE="pifmrds"
4 GITHASH="c67306ea9b8d827f45e0d90279d367e97119bcb1"
5 VERSION=${GITHASH:0:7}
6 CATEGORY="system-tools"
7 SHORT_DESC="FM-RDS transmitter using the Raspberry Pi's PWM."
8 MAINTAINER="pascal.bellard@slitaz.org"
9 LICENSE="GPL3"
10 WEB_SITE="https://github.com/ChristopheJacquet/PiFmRds"
11 TARBALL="$PACKAGE-$VERSION.zip"
12 WGET_URL="$WEB_SITE/archive/$GITHASH.zip"
13 HOST_ARCH="arm"
14 TAGS="radio FM RDS"
15 SUGGESTED="sox"
17 DEPENDS="libsndfile"
18 BUILD_DEPENDS="wget libsndfile-dev"
20 # Rules to configure and make the package.
21 compile_rules()
22 {
23 cd $src/src
24 sed -i 's|^CC|# &|;/^ifeq/d;/^else/,/^endif/d;s|-march.*$||' Makefile
25 make
26 }
28 # SliTaz package testsuite
29 testsuite() {
30 readelf -Ah $src/src/pi_fm_rds
31 }
33 # Rules to gen a SliTaz package suitable for Tazpkg.
34 genpkg_rules()
35 {
36 mkdir -p $fs/usr/sbin
37 cp $src/src/pi_fm_rds $fs/usr/sbin
38 cat > $fs/usr/sbin/pifmogg.sh <<EOT
39 #!/bin/sh
41 fifo=/tmp/pifmogg$$
42 mkfifo $fifo
43 find $@ -name '*.ogg' -or -name '*.wav' -print | while read file ; do
44 echo "RT $(basename $file .ogg)" > $FIFO
45 cat $file
46 done | pi_fm_rds -audio - -ctl $fifo -freq ${FM_FREQ:-107.9} \
47 -ps ${RDS_SERVICE:-RASP-PI} -pi ${RDS_ID:-$(printf "%04X" $RANDOM)}
48 rm -f $fifo
49 EOT
50 chmod +x $fs/usr/sbin/pifmogg.sh
51 }