Magellan Linux

Contents of /trunk/extras/nas/nas-1.9.4-r1.smage2

Parent Directory Parent Directory | Revision Log Revision Log


Revision 28377 - (show annotations) (download)
Wed Aug 24 08:04:14 2016 UTC (7 years, 9 months ago) by niro
File size: 2115 byte(s)
-fixed cpan author
1 # $Id$
2
3 PNAME="nas"
4 PVER="1.9.4"
5 PBUILD="r2"
6
7 SPLIT_PACKAGES="libaudio nas"
8 PCAT="media-libs"
9
10 DESCRIPTION="The Network Audio System is a network transparent, client/server audio transport system."
11 HOMEPAGE="http://radscan.com/nas.html"
12
13 DEPEND=">= x11-libs/libXt-1
14 >= x11-libs/libXau-1
15 >= x11-libs/libXaw-1
16 >= x11-libs/libX11-1
17 >= x11-libs/libXres-1"
18
19 SDEPEND=">= x11-misc/gccmakedep-1
20 >= x11-misc/imake-1"
21
22 SRCFILE="${PNAME}-${PVER}.src.tar.gz"
23 SRCDIR="${BUILDDIR}/${PNAME}-${PVER}"
24
25 sminclude xorg mtools iconv systemd
26 msetfeature "!check" # no check target in Makefile
27
28 SRC_URI=(
29 sourceforge://${PNAME}/${SRCFILE}
30 mirror://${PNAME}/${SRCFILE}
31 mirror://${PNAME}/nas.confd
32 mirror://${PNAME}/nas.service
33 )
34
35 UP2SUBSTITUTE=".src"
36 UP2DATE="updatecmd ${HOMEPAGE} | sed 's:\ (.*)::g' | firsttarball gz"
37
38 split_info_libaudio()
39 {
40 DESCRIPTION="."
41 DEPEND="${LIB_DEPEND}"
42 }
43
44 split_info_nas()
45 {
46 DESCRIPTION="The Network Audio System is a network transparent, client/server audio transport system."
47 DEPEND="== media-libs/libaudio-${PVER}
48 ${NAS_DEPEND}"
49 }
50
51 src_prepare()
52 {
53 munpack ${SRCFILE} || die
54 cd ${SRCDIR}
55
56 # convert to utf-8
57 miconvutf8 HISTORY || die
58 }
59
60 src_compile()
61 {
62 cd ${SRCDIR}
63 xmkmf || die
64 # build without libXp
65 mmake World XPLIB="" || die
66 }
67
68 src_install()
69 {
70 cd ${SRCDIR}
71
72 mmake DESTDIR=${BINDIR} install || die
73 mmake DESTDIR=${BINDIR} DOCHTMLDIR=/usr/share/doc-to-remove install.man || die
74
75 # rename example conf
76 mv ${BINDIR}/etc/nas/nasd.conf.eg ${BINDIR}/etc/nas/nasd.conf || die
77
78 # set mixer init off, so nas doesn't change the mixer settings
79 sed -i 's,\(MixerInit.*\)"\(.*\)",\1"no",' ${BINDIR}/etc/nas/nasd.conf || die
80
81 # remove html docs, not needed and way too big
82 rm -rf ${BINDIR}/usr/share/doc-to-remove || die
83
84 # we don't need the static lib
85 rm ${BINDIR}/usr/$(mlibdir)/libaudio.a || die
86
87 # install init scripts and configs
88 minstallunit nas.service || die
89 minstallconf nas.confd nas || die
90
91 # docs
92 minstalldocs BUGS BUILDNOTES FAQ HISTORY README RELEASE TODO || die
93 }
94
95 postinstall()
96 {
97 mstartunit nas.service nasd
98 }
99
100 postremove()
101 {
102 mstopunit nas.service nasd
103 }
104