17 |
BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root |
BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root |
18 |
|
|
19 |
BuildRequires: ffmpeg-devel |
BuildRequires: ffmpeg-devel |
20 |
|
BuildRequires: ffmpeg-compat-devel |
21 |
|
|
22 |
%description |
%description |
23 |
libdlna aims at being the reference open-source implementation of DLNA |
libdlna aims at being the reference open-source implementation of DLNA |
37 |
|
|
38 |
%prep |
%prep |
39 |
%setup |
%setup |
40 |
|
#remove test |
41 |
%if %{!?_without_ffmpeg05:1}0 |
%{__perl} -pi.orig -e ' |
42 |
|
s|check_lib ffmpeg/avformat.h av_register_all -lavformat|echo "ok"|; |
43 |
|
s|check_lib ffmpeg/avcodec.h avcodec_register_all -lavcodec|echo "ok"|; |
44 |
|
' configure src/*.c src/*.h |
45 |
%{__perl} -pi.orig -e ' |
%{__perl} -pi.orig -e ' |
46 |
s|ffmpeg/avformat.h|libavformat/avformat.h|; |
s|ffmpeg/avformat.h|ffmpeg-compat/libavformat/avformat.h|; |
47 |
s|ffmpeg/avcodec.h|libavcodec/avcodec.h|; |
s|ffmpeg/avcodec.h|ffmpeg-compat/libavcodec/avcodec.h|; |
48 |
' configure src/*.c src/*.h |
' configure src/*.c src/*.h |
49 |
%endif |
|
50 |
|
#check_lib ffmpeg/libavformat/avformat.h av_register_all -lavformat || die "Error, can't find libavformat !" |
51 |
|
#echolog "Checking for libavcodec ..." |
52 |
|
#check_lib ffmpeg/libavcodec/avcodec.h avcodec_register_all -lavcodec || die "Error, can't find libavcodec !" |
53 |
|
|
54 |
|
# %if %{!?_without_ffmpeg05:1}0 |
55 |
|
# %{__perl} -pi.orig -e ' |
56 |
|
# s|ffmpeg/avformat.h|libavformat/avformat.h|; |
57 |
|
# s|ffmpeg/avcodec.h|libavcodec/avcodec.h|; |
58 |
|
# ' configure src/*.c src/*.h |
59 |
|
# %endif |
60 |
|
|
61 |
|
|
62 |
%build |
%build |
63 |
export CFLAGS="%{optflags}" |
export CFLAGS="%{optflags}" |
64 |
./configure \ |
./configure \ |
65 |
--disable-static \ |
--disable-static \ |
66 |
--libdir="%{_libdir}" \ |
--libdir="%{_libdir}" \ |
67 |
--prefix="%{_prefix}" |
--prefix="%{_prefix}" \ |
68 |
|
--log=/dev/stdout |
69 |
%{__make} %{?_smp_mflags} || : |
%{__make} %{?_smp_mflags} || : |
70 |
|
|
71 |
%install |
%install |