SHA256
1
0
forked from pool/picard

Remove libdiscid because there is no dlopen anymore

OBS-URL: https://build.opensuse.org/package/show/multimedia:apps/picard?expand=0&rev=44
This commit is contained in:
Olaf Hering 2016-06-29 10:55:49 +00:00 committed by Git OBS Bridge
parent ca99013da8
commit b2bea08d7b

View File

@ -38,7 +38,6 @@ Source16: http://users.musicbrainz.org/~brianfreud/SearchSoundtrackCollect
Source17: http://users.musicbrainz.org/~brianfreud/SearchSoundtrackINFO3.py Source17: http://users.musicbrainz.org/~brianfreud/SearchSoundtrackINFO3.py
BuildRequires: desktop-file-utils BuildRequires: desktop-file-utils
BuildRequires: gcc-c++ BuildRequires: gcc-c++
BuildRequires: libdiscid-devel
BuildRequires: libofa-devel BuildRequires: libofa-devel
BuildRequires: python-devel BuildRequires: python-devel
BuildRequires: python-mutagen BuildRequires: python-mutagen
@ -62,22 +61,6 @@ tagging and cross platform compatibility.
%setup -q -n %{name}-release-%{version} %setup -q -n %{name}-release-%{version}
%build %build
export CFLAGS="%{optflags}"
cat > %{name}_libdiscid_dummy.c <<-EOF
#include <stdio.h>
#include <discid/discid.h>
int main(void) {
printf("Dummy to generate correct libdiscid.so rpm dependency.\n");
discid_free(discid_new());
return 0;
}
EOF
gcc -Wall -s $CFLAGS -o %{name}_libdiscid_dummy %{name}_libdiscid_dummy.c -ldiscid
# there is some upstream confusion about what the SONAME of libdiscid is supposed to be
libdiscid_so="`readelf --wide --dynamic picard_libdiscid_dummy | sed -n '/(NEEDED).*libdiscid.so/s@^\(.*\[\)\([^]]\+\).*@\2@p'`"
sed -i~ -e "s@^\([[:blank:]]\+\)\(libName[[:blank:]]*=[[:blank:]]*'\)\(libdiscid.so.0\)\('[[:blank:]]*\)@\1\2${libdiscid_so}\4 # was '\3'@" picard/disc.py
if diff -u picard/disc.py~ picard/disc.py ; then : ; fi
#
python setup.py config python setup.py config
python setup.py build python setup.py build
@ -106,9 +89,6 @@ rm -rfv %{buildroot}%{_datadir}/locale/sco
%find_lang %{name}-countries %{name}.lang %find_lang %{name}-countries %{name}.lang
%find_lang %{name}-attributes %{name}.lang %find_lang %{name}-attributes %{name}.lang
mkdir -vp %{buildroot}/%{_libdir}/%{name}
cp -avL %{name}_libdiscid_dummy %{buildroot}/%{_libdir}/%{name}
%post %post
%icon_theme_cache_post %icon_theme_cache_post
@ -119,7 +99,6 @@ cp -avL %{name}_libdiscid_dummy %{buildroot}/%{_libdir}/%{name}
%defattr(-,root,root) %defattr(-,root,root)
%doc AUTHORS.txt COPYING.txt NEWS.txt %doc AUTHORS.txt COPYING.txt NEWS.txt
%{_bindir}/picard %{_bindir}/picard
%{_libdir}/%{name}
%{_datadir}/applications/%{name}.desktop %{_datadir}/applications/%{name}.desktop
%{python_sitearch}/picard* %{python_sitearch}/picard*
%{_datadir}/icons/hicolor/*/apps/picard.png %{_datadir}/icons/hicolor/*/apps/picard.png