3 # http://wiki.birth-online.de/know-how/hardware/apple-iphone/airvideo-server-linux
4 # - clarify source files license and remove nosource
6 %include /usr/lib/rpm/macros.java
7 Summary: Air-Video Video Streaming Server
11 License: GPL v2+ with LGPL v2+ parts
12 Group: Applications/Multimedia
13 Source0: http://inmethod.com/air-video/download/ffmpeg-for-%{version}-beta6.tar.bz2
14 # NoSource0-md5: 241844e9d41bbd9f8852955291490910
17 Source2: http://inmethod.com/air-video/download/linux/alpha6/AirVideoServerLinux.jar#/avs-alpha6.jar
18 # NoSource2-md5: b619c088eea230afa92181393a36e1c0
20 Source3: test.properties
22 URL: http://www.inmethod.com/air-video/
23 BuildRequires: lame-libs-devel
24 BuildRequires: libx264-devel >= 0.1.3
25 BuildRequires: pkgconfig
26 BuildRequires: rpm-javaprov
27 BuildRequires: rpmbuild(macros) >= 1.470
28 Requires(post,preun): /sbin/chkconfig
30 Requires: jpackage-utils
31 Requires: mpeg4ip-server
33 BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
35 %define _noautoreqdep libGL.so.1 libGLU.so.1
37 %define specflags -fno-strict-aliasing
39 # -fomit-frame-pointer is always needed on x86 due to lack of registers (-fPIC takes one)
40 %define specflags_ia32 -fomit-frame-pointer
41 # -mmmx is needed to enable <mmintrin.h> code.
42 %define specflags_i586 -mmmx
43 %define specflags_i686 -mmmx
44 %define specflags_ppc -fPIC
47 Air Video can stream videos in almost any format to your iPhone, iPad
48 and iPod touch. You don't need to copy your videos to the device just
52 Summary: airvideo service configuration for avahi
53 Summary(pl.UTF-8): Konfiguracja serwisu airvideo dla avahi
55 Requires: %{name} = %{version}-%{release}
59 airvideo service configuration for avahi.
63 mv ffmpeg/{*,.??*} .; rmdir ffmpeg
67 # - it's not autoconf configure
68 # - --disable-debug, --disable-optimizations, tune=generic causes not to override our optflags
71 --arch=%{_target_base_arch} \
74 --shlibdir=%{_libdir} \
77 --extra-cflags="-D_GNU_SOURCE=1 %{rpmcppflags} %{rpmcflags}" \
78 --extra-ldflags="%{rpmcflags} %{rpmldflags}" \
80 --disable-optimizations \
88 --disable-decoder=aac \
92 %ifnarch %{ix86} %{x8664}
98 --enable-runtime-cpudetect
103 rm -rf $RPM_BUILD_ROOT
104 install -d $RPM_BUILD_ROOT{%{_sysconfdir},%{_sbindir},%{_javadir},/etc/{rc.d/init.d,avahi/services},/var/lib/airvideo}
105 install -p ffmpeg $RPM_BUILD_ROOT%{_sbindir}/%{name}
106 install -p %{SOURCE1} $RPM_BUILD_ROOT/etc/rc.d/init.d/%{name}
108 cp -p %{SOURCE2} $RPM_BUILD_ROOT%{_javadir}/AirVideoServerLinux.jar
109 cp -p %{SOURCE3} $RPM_BUILD_ROOT%{_sysconfdir}/%{name}.properties
110 cp -p %{SOURCE4} $RPM_BUILD_ROOT%{_sysconfdir}/avahi/services/%{name}.service
113 rm -rf $RPM_BUILD_ROOT
116 /sbin/chkconfig --add %{name}
117 %service %{name} restart
120 if [ "$1" = "0" ]; then
121 %service -q %{name} stop
122 /sbin/chkconfig --del %{name}
126 %defattr(644,root,root,755)
127 %attr(755,root,root) %{_sbindir}/airvideo
128 %config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/%{name}.properties
129 %attr(754,root,root) /etc/rc.d/init.d/%{name}
130 %{_javadir}/AirVideoServerLinux.jar
131 # XXX, if it really writes something, get dedicated user
132 %dir /var/lib/airvideo
135 %defattr(644,root,root,755)
136 %config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/avahi/services/%{name}.service