]> git.pld-linux.org Git - packages/gpac.git/blobdiff - gpac.spec
- up to 2.2.1
[packages/gpac.git] / gpac.spec
index 415c389b1f0d9eac4cdde596f0123d7b46051fc8..96f7ad844b73021363f0304d9c584d960439c291 100644 (file)
--- a/gpac.spec
+++ b/gpac.spec
@@ -1,65 +1,77 @@
-# TODO
-# - soname for libm4systems(?)
-# - use system mozilla includes
-# - ./configure[692]: wx-config: not found
-# - ./configure[693]: wx-config: not found
-# - CC, CFLAGS
-# - Xiph Theora: no
+# TODO:
+# - Platinum UPnP: http://www.plutinosoft.com/platinum (for platinum module)
+# - OpenSVCDecoder: http://opensvcdecoder.sourceforge.net/ (for opensvc_dec module)
+# - libopenhevc: https://github.com/OpenHEVC/openHEVC (for openhevc_dec module, replaces ffmpeg_in module)
 #
 # Conditional build:
-%bcond_with    amr
-%bcond_without faad
-%bcond_without ffmpeg
-%bcond_without freetype
-%bcond_without jpeg
-%bcond_without js
-%bcond_without mad
-%bcond_without png
-%bcond_without xvid
-%bcond_with    wx
+%bcond_with    amr             # AMR-NB and AMR-WB (floating-point) support
+%bcond_without avcap           # AVCap module
+%bcond_with    directfb        # DirectFB support
+%bcond_without faad            # AAC decoding support
+%bcond_without ffmpeg          # ffmpeg support
+%bcond_without freenect        # freenect (MS Kinect driver) module
+%bcond_without freetype        # freetype support
+%bcond_without jpeg            # JPEG support
+%bcond_with    js              # JavaScript support in Osmo4 and modules
+%bcond_without mad             # MP3 support
+%bcond_without png             # PNG support
+%bcond_without xvid            # xvid support
+%bcond_with    mozilla         # Mozilla (xulrunner/firefox/iceweasel, NPAPI+XPCOM based) plugin
+#
+%ifarch x32
+%undefine      with_mozilla
+%endif
 #
 Summary:       GPAC - an implementation of the MPEG-4 Systems standard (ISO/IEC 14496-1)
 Summary(pl.UTF-8):     GPAC - implementacja standardu MPEG-4 Systems (ISO/IEC 14496-1)
 Name:          gpac
-Version:       0.4.0
-Release:       4
-License:       LGPL
-Group:         Applications
-Source0:       http://dl.sourceforge.net/gpac/%{name}-%{version}.tar.gz
-# Source0-md5: a8b4b3206cabda946850240f1e7aea93
-Source1:       http://www.3gpp.org/ftp/Specs/archive/26_series/26.073/26073-530.zip
-# Source1-md5: 705f6993fbf890e92eb7a331e7c716d1
-Patch0:                %{name}-install.patch
-Patch1:                %{name}-wxWidgets.patch
-Patch2:                %{name}-amd64.patch
-Patch3:                %{name}-libdir.patch
-URL:           http://gpac.sourceforge.net/
+Version:       2.2.1
+Release:       1
+License:       LGPL v2+
+Group:         Applications/Multimedia
+#Source0Download: https://github.com/gpac/gpac/releases
+Source0:       https://github.com/gpac/gpac/archive/v%{version}/%{name}-%{version}.tar.gz
+# Source0-md5: a1a4a6c7f1525431b211b5ba47253ed0
+Patch0:                ffmpeg6.patch
+URL:           http://www.gpac.io/
+%{?with_directfb:BuildRequires:        DirectFB-devel}
+BuildRequires: OpenGL-GLU-devel
 BuildRequires: SDL-devel
+BuildRequires: a52dec-libs-devel
+%{?with_avcap:BuildRequires:   avcap-devel}
+BuildRequires: alsa-lib-devel >= 0.9
+%{?with_amr:BuildRequires:     amrnb-devel}
+%{?with_amr:BuildRequires:     amrwb-devel}
 %{?with_faad:BuildRequires:    faad2-devel}
-%{?with_ffmpeg:BuildRequires:  ffmpeg-devel}
+%{?with_ffmpeg:BuildRequires:  ffmpeg-devel >= 0.6}
 %{?with_freetype:BuildRequires:        freetype-devel}
-%{?with_js:BuildRequires:      js-devel}
+BuildRequires: jack-audio-connection-kit-devel
+%{?with_js:BuildRequires:      js-devel < 2:1.8.5}
+%{?with_freenect:BuildRequires:        libfreenect-devel}
 %{?with_jpeg:BuildRequires:    libjpeg-devel}
 %{?with_mad:BuildRequires:     libmad-devel}
+BuildRequires: libogg-devel
 %{?with_png:BuildRequires:     libpng-devel}
+BuildRequires: libtheora-devel
+BuildRequires: libvorbis-devel
 BuildRequires: libxml2-devel
+BuildRequires: openjpeg2-devel
+BuildRequires: openssl-devel
+BuildRequires: pkgconfig
+BuildRequires: pulseaudio-devel
 BuildRequires: rpmbuild(macros) >= 1.357
+BuildRequires: sed >= 4.0
 BuildRequires: unzip
-%{?with_wx:BuildRequires:      wxGTK2-devel >= 2.5.4}
+BuildRequires: xmlrpc-c-server-devel
+BuildRequires: xorg-lib-libXext-devel
+BuildRequires: xorg-lib-libXv-devel
+%{?with_mozilla:BuildRequires: xulrunner-devel >= 2:9.0.0}
 %{?with_xvid:BuildRequires:    xvid-devel}
-Requires:      SDL
-%{?with_faad:Requires: faad2}
-%{?with_ffmpeg:Requires:       ffmpeg}
-%{?with_freetype:Requires:     freetype}
-%{?with_js:Requires:   js}
-%{?with_jpeg:Requires: libjpeg}
-%{?with_mad:Requires:  libmad}
-%{?with_png:Requires:  libpng}
-%{?with_xvid:Requires: xvid}
+BuildRequires: xz-devel
+BuildRequires: zlib-devel
+Obsoletes:     gpac-gui < 1.0.1-1
 BuildRoot:     %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
 
-%define         _noautoreq   libm4systems.so
-
 %description
 GPAC is an implementation of the MPEG-4 Systems standard (ISO/IEC
 14496-1) developed from scratch in ANSI C.
@@ -90,6 +102,30 @@ DSP) z prostym celem: wymagać tak mało pamięci, jak to tylko możliwe.
 Projekt docelowo dostarczy odtwarzacz(e), kodery systemowe i narzędzia
 do publikacji w celu dystrybucji materiałów.
 
+%package devel
+Summary:       Header files for GPAC library
+Summary(pl.UTF-8):     Pliki nagłówkowe biblioteki GPAC
+Group:         Development/Libraries
+Requires:      %{name} = %{version}-%{release}
+
+%description devel
+Header files for GPAC library.
+
+%description devel -l pl.UTF-8
+Pliki nagłówkowe biblioteki GPAC.
+
+%package static
+Summary:       Static GPAC library
+Summary(pl.UTF-8):     Statyczna biblioteka GPAC
+Group:         Development/Libraries
+Requires:      %{name}-devel = %{version}-%{release}
+
+%description static
+Static GPAC library.
+
+%description static -l pl.UTF-8
+Statyczna biblioteka GPAC.
+
 %package -n browser-plugin-%{name}
 Summary:       GPAC browser plugin
 Summary(pl.UTF-8):     Wtyczka GPAC do przegląderek WWW
@@ -105,53 +141,54 @@ GPAC plugin for Netscape-compatible WWW browsers.
 Wtyczka GPAC dla przeglądarek WWW zgodnych z Netscape.
 
 %prep
-%setup -q -n %{name}
+%setup -q
 %patch0 -p1
-%{?with_wx:%patch1 -p1}
-%patch2 -p1
-%patch3 -p1
-%if %{with amr}
-mkdir -p Plugins/amr_dec/AMR_NB
-cd Plugins/amr_dec/AMR_NB
-unzip -j %{SOURCE1}
-unzip -j 26073-530_ANSI_C_source_code.zip
-cd ../../..
+
+%if %{without avcap}
+%{__sed} -i -e 's,has_avcap="yes",has_avcap="no",' configure
 %endif
 chmod a+x configure
 
-# files for w32 and Linux were swapped
-rm -rf applications/osmozilla/nsIOsmozilla.xpt_linux
-mv applications/osmozilla/nsIOsmozilla.xpt_w32 applications/osmozilla/nsIOsmozilla.xpt_linux
-
 %build
-%configure \
-       --extra-cflags="-fPIC" \
-       --extra-ldflags="-fPIC" \
-       --enable-oss-audio \
-       %{?with_amr:--enable-amr-nb} \
-       %{!?with_faad:--disable-faad} \
-       %{!?with_ffmpeg:--disable-ffmpeg} \
-       %{!?with_freetype:--disable-ft} \
-       %{!?with_jpeg:--disable-jpeg} \
-       %{!?with_js:--disable-js} \
-       %{!?with_mad:--disable-mad} \
-       %{!?with_png:--disable-png} \
-       %{!?with_xvid:--disable-xvid}
-
-%{__make} -j1 \
-       XLIBDIR="/usr/X11R6/%{_lib}" \
-       DESTDIR=$RPM_BUILD_ROOT
+# not autoconf configure
+./configure \
+       --verbose \
+       --prefix=%{_prefix} \
+       --libdir=%{_lib} \
+       --mandir=%{_mandir} \
+       --X11-path=/usr \
+       --cc="%{__cc}" \
+       --cxx="%{__cxx}" \
+       --disable-opt \
+       %{?with_amr:--enable-amr} \
+       --enable-pic \
+       --extra-cflags="%{rpmcflags}" \
+       --extra-ldflags="%{rpmldflags}" \
+       %{?with_mozilla:--mozdir=%{_browserpluginsdir}} \
+       %{?with_mozilla:--xulsdk-path="/usr/include/xulrunner -I/usr/include/nspr"} \
+       %{!?with_faad:--use-faad=no} \
+       %{!?with_ffmpeg:--use-ffmpeg=no} \
+       %{!?with_freenect:--use-freenect=no} \
+       %{!?with_freetype:--use-ft=no} \
+       %{!?with_jpeg:--use-jpeg=no} \
+       %{!?with_mad:--use-mad=no} \
+       %{!?with_png:--use-png=no} \
+       %{!?with_xvid:--use-xvid=no} \
+       --enable-joystick
+
+%{!?with_directfb: sed -i 's/CONFIG_DIRECTFB.*/CONFIG_DIRECTFB=no/' config.mak}
+
+%{__make}
 
 %install
 rm -rf $RPM_BUILD_ROOT
+install -d $RPM_BUILD_ROOT%{_pkgconfigdir}
+
+%{__make} -j1 install install-lib \
+       DESTDIR=$RPM_BUILD_ROOT
 
-%{__make} install \
-       bindir=$RPM_BUILD_ROOT%{_bindir} \
-       libdir=$RPM_BUILD_ROOT%{_libdir} \
-       mandir=$RPM_BUILD_ROOT%{_mandir} \
-       plugdir=$RPM_BUILD_ROOT%{_libdir}/gpac \
-       real_plugdir=%{_libdir}/gpac \
-       prefix=$RPM_BUILD_ROOT%{_prefix} \
+%{__make} -j1 -C applications install \
+       DESTDIR=$RPM_BUILD_ROOT \
        MOZILLA_DIR=$RPM_BUILD_ROOT%{_browserpluginsdir}
 
 %clean
@@ -170,14 +207,33 @@ fi
 
 %files
 %defattr(644,root,root,755)
-%doc AUTHORS BUGS Changelog README TODO
-%attr(755,root,root) %{_bindir}/*
-%attr(755,root,root) %{_libdir}/lib*.so
+%doc Changelog README.md
+%attr(755,root,root) %{_bindir}/MP4Box
+%attr(755,root,root) %{_bindir}/gpac
+%attr(755,root,root) %{_libdir}/libgpac.so.*.*.*
+%attr(755,root,root) %ghost %{_libdir}/libgpac.so.12
 %dir %{_libdir}/gpac
-%attr(755,root,root) %{_libdir}/gpac/*.so
-%{_mandir}/man1/*
+%attr(755,root,root) %{_libdir}/gpac/gm_*.so
+%{_datadir}/gpac
+%{_mandir}/man1/gpac.1*
+%{_mandir}/man1/gpac-filters.1*
+%{_mandir}/man1/mp4box.1*
+%{_desktopdir}/gpac.desktop
+%{_iconsdir}/hicolor/*x*/apps/gpac.png
+
+%files devel
+%defattr(644,root,root,755)
+%attr(755,root,root) %{_libdir}/libgpac.so
+%{_includedir}/gpac
+%{_pkgconfigdir}/gpac.pc
+
+%files static
+%defattr(644,root,root,755)
+%{_libdir}/libgpac_static.a
 
+%if %{with mozilla}
 %files -n browser-plugin-%{name}
 %defattr(644,root,root,755)
 %attr(755,root,root) %{_browserpluginsdir}/nposmozilla.so
 %{_browserpluginsdir}/nposmozilla.xpt
+%endif
This page took 0.058836 seconds and 4 git commands to generate.