Name: libmm-fileinfo
Summary: Media Fileinfo
-Version: 0.6.61
+Version: 1.0.7
Release: 0
Group: System/Libraries
License: Apache-2.0
BuildRequires: pkgconfig(libavformat)
BuildRequires: pkgconfig(icu-i18n)
BuildRequires: pkgconfig(vconf)
+%if 0%{?gtests:1}
+BuildRequires: pkgconfig(gmock)
+%endif
%description
Multimedia Framework FileInfo Library
cp %{SOURCE1001} .
%build
+%if "%{tizen_profile_name}" == "tv"
+export CFLAGS+=" -DUSE_CODEC_VPX"
+%endif
export CFLAGS+=" -Wextra -Wno-array-bounds"
export CFLAGS+=" -Wno-ignored-qualifiers -Wno-unused-parameter -Wshadow"
export CFLAGS+=" -Wwrite-strings -Wswitch-default -Werror"
-export CFLAGS+=" -Wno-int-to-pointer-cast -Wno-pointer-to-int-cast -fgnu89-inline"
+export CFLAGS+=" -Wno-int-to-pointer-cast -Wno-pointer-to-int-cast -fgnu89-inline -fstack-protector-strong -D_FORTIFY_SOURCE=2"
./autogen.sh
%reconfigure \
-CFLAGS="${CFLAGS} -D_MM_PROJECT_FLOATER -DEXPORT_API=\"__attribute__((visibility(\\\"default\\\")))\" " LDFLAGS="${LDFLAGS}" ./configure --disable-testmode --disable-dump --enable-dyn --disable-iommap --prefix=/usr --disable-gtk
+CFLAGS="${CFLAGS} -DEXPORT_API=\"__attribute__((visibility(\\\"default\\\")))\" " LDFLAGS="${LDFLAGS}" \
+./configure --disable-testmode --disable-dump --enable-dyn --disable-iommap --prefix=/usr \
+%if 0%{?gtests:1}
+ --enable-tests \
+%endif
+ --disable-gtk
%__make
mkdir -p %{buildroot}%{_sysconfdir}/multimedia
cp -rf %{_builddir}/%{name}-%{version}/mm_file_config.ini %{buildroot}%{_sysconfdir}/multimedia/mm_file_config.ini
+%if 0%{?gtests:1}
+mkdir -p %{buildroot}%{_bindir}
+cp -rf %{_builddir}/%{name}-%{version}/unittest/*.mp4 %{buildroot}%{_bindir}/
+cp -rf %{_builddir}/%{name}-%{version}/unittest/*.mp3 %{buildroot}%{_bindir}/
+%endif
%post -p /sbin/ldconfig
%files
%manifest %{name}.manifest
%{_libdir}/libmmffile.so.*
-%{_libdir}/libmmfile_codecs.so.*
%{_libdir}/libmmfile_formats.so.*
%{_libdir}/libmmfile_utils.so.*
%{_libdir}/libmmffile.so
-%{_libdir}/libmmfile_codecs.so
%{_libdir}/libmmfile_formats.so
%{_libdir}/libmmfile_utils.so
%{_sysconfdir}/multimedia/mm_file_config.ini
+%if 0%{?gtests:1}
+%{_bindir}/gtest*
+%{_bindir}/libmm-fileinfo-unittest*
+%endif
%license LICENSE.APLv2.0
%files tool