Mageia Bugzilla – Attachment 2313 Details for
Bug 462
add openclipart package and integrate openclipart images with libreoffice gallery
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Requests
|
Help
|
Log In
[x]
|
New Account
|
Forgot Password
Specfile for create libreoffice-openclipart
openoffice.org-openclipart.spec (text/plain), 4.51 KB, created by
Jaroslav Krejci
on 2012-05-14 19:51:22 CEST
(
hide
)
Description:
Specfile for create libreoffice-openclipart
Filename:
MIME Type:
Creator:
Jaroslav Krejci
Created:
2012-05-14 19:51:22 CEST
Size:
4.51 KB
patch
obsolete
>%define _ooodir /usr/lib/libreoffice >%define _gengal %{_ooodir}/program/gengal >%define _ooogaldir %{_ooodir}/share/gallery > >%bcond_without tarball # don't use tarball, build gallery > >Name: libreoffice-openclipart >Summary: Extra Galleries for libreoffice >Summary(de): Extra-Galerien für libreoffice >Version: 3 >Release: 3mjk.mga2 >License: GPL v2 or later; LGPL v2.1 or later >Group: Office >Source0: openoffice.org-openclipart-0.18.tar.xz >URL: http://www.openoffice.org/ >Requires: libreoffice-core >= 3.5.0 >Conflicts: openoffice.org3-openclipart >Provides: libreoffice-galleries = %version >Requires: clipart-openclipart >= 0.18 >%if %{without tarball} >BuildRequires: x11-server-xvfb >BuildRequires: libreoffice-core >= 3.5 >BuildRequires: libreoffice-graphicfilter >= 3.5 >BuildRequires: clipart-openclipart >= 0.18 >BuildRequires: update-alternatives >Conflicts: openoffice.org3-openclipart >Requires: clipart-openclipart >= 0.18 >%endif >BuildRoot: %{_tmppath}/%{name}-%{version}-build >BuildArch: noarch > >%description >This package contains an extensive set of extra galleries for >libreoffice. It can be used to enrich documents with graphics arts. > >%description -l de >Dieses Paket enthält eine umfangreiche Reihe von zusätzlichen Galerien für >libreoffice. Es kann verwendet werden, um Dokumente mit Grafiken zu bereichern. > >%prep >%if %{with tarball} >%setup -q -n openoffice.org-openclipart-0.18 >%else >%setup -q -c -T -n openoffice.org-openclipart-0.18 >%endif > >%if %{without tarball} >%build >OPENCLIPART_DIR=%{_datadir}/images/openclipart >GAL_BIN=%{_gengal} >GAL_DIR=$(pwd)/gallery ># start number for the new galleries >GAL_NUMBER_FROM=70 >XVFB=/usr/bin/Xvfb > >XDISPLAY=98 >echo 'Starting Xvfb...' ># try only 10-times to avoid infinite loop >while [ "$XDISPLAY" != 108 ]; do > if [ ! -f /tmp/.X$XDISPLAY-lock ]; then > echo " trying display :$XDISPLAY ..." > sleep 2s > $XVFB -ac :$XDISPLAY & > trap "kill $! > /dev/null 2>&1 || true" EXIT > # let server to start > sleep 10s > if [ -f /tmp/.X$XDISPLAY-lock ]; then > break > fi > fi > XDISPLAY=$(($XDISPLAY+1)) >done > >if ! test -f /tmp/.X$XDISPLAY-lock ; then > echo "Error: Unable to start Xvfb" >&2 > exit 1 >fi > >export DISPLAY=":$XDISPLAY" >echo "Using DISPLAY="$DISPLAY > >rm -rf $GAL_DIR >mkdir -p $GAL_DIR >echo "Building extra galleries from openclipart..." >for dir in $(find -L $OPENCLIPART_DIR -mindepth 1 -maxdepth 1 -type d | sort); do > # get the gallery name from the directory name > # and make the first character uppercase > gal_name=${dir##*/} > gal_name=$(echo $gal_name | tr '_-' ' ') > gal_name_rest=${gal_name#?} > gal_name_first_char=${gal_name%$gal_name_rest} > gal_name_first_char=$(echo $gal_name_first_char | tr 'a-z' 'A-Z') > gal_name=$gal_name_first_char$gal_name_rest > > echo "Doing gallery $gal_name..." > find $dir -name '*.png' -print0 | sort -z | { > xargs -0 $GAL_BIN \ > --name "$gal_name" \ > --path "$GAL_DIR" \ > --number-from "$GAL_NUMBER_FROM" || exit 1 > } >done >%endif > >%install >rm -rf $RPM_BUILD_ROOT >install -d $RPM_BUILD_ROOT%{_ooogaldir} >cp -a gallery/* $RPM_BUILD_ROOT%{_ooogaldir} > >%clean >rm -rf $RPM_BUILD_ROOT > >%files >%defattr(644,root,root,755) >%{_ooogaldir}/* > >%changelog >* Mon May 14 2012 Jaroslav Krejci <krejci@zstenis.com> libreoffice-openclipart-3-3mjk.mga2 >- change path to libreoffice 3.5 > >* Wed Oct 26 2011 Jaroslav Krejci <krejci@zstenis.com> libreoffice-openclipart-3-2mjk.mga1 >- change path to libreoffice 3.4 > >* Tue Jun 21 2011 Jaroslav Krejci <krejci@zstenis.com> libreoffice-openclipart-3-1mjk.mga1 >- build for Mageia 1 > >* Sat Dec 11 2010 maik3531 <maik3531 at yahoo.de> libreoffice-openclipart-3-1pclos2010 >- change path to libreoffice 3.3 > >* Mon Jul 26 2010 maik3531 <maik3531 at yahoo.de> openoffice.org3-openclipart-3-5pclos2010 >- change path to 3.2 > >* Sun Jun 07 2009 Texstar <texstar@gmail.com> openoffice.org3-openclipart-3-4pclos2009 >- change path to 3.1 > >* Sun Apr 12 2009 maik3531 <maik3531@yahoo.de> openoffice.org3-openclipart-3-3pclos2007 >- fix XVFB and OPENCLIPART_DIR Path >- create new tarball > >* Sun Apr 12 2009 maik3531 <maik3531@yahoo.de> openoffice.org3-openclipart-3-2pclos2007 >- compared with PLD to png instead of svg > >* Sat Apr 11 2009 maik3531 <maik3531@yahoo.de> openoffice.org3-openclipart-3-1pclos2007 >- rebuild from suse vor PCLinuxOS 2009.1 >#ftp://ftp.pbone.net/mirror/ftp5.gwdg.de/pub/opensuse/repositories/OpenOffice.org%3A/UNSTABLE/openSUSE_Factory/src/OpenOffice_org-openclipart-3-3.22.src.rpm >- add to *.blacklist >food/fruit/turkey_platter_01_with_fruit_and_vegitables_01.svg >food/turkey_platter_01_with_fruit_and_vegitables_01.svg >
%define _ooodir /usr/lib/libreoffice %define _gengal %{_ooodir}/program/gengal %define _ooogaldir %{_ooodir}/share/gallery %bcond_without tarball # don't use tarball, build gallery Name: libreoffice-openclipart Summary: Extra Galleries for libreoffice Summary(de): Extra-Galerien für libreoffice Version: 3 Release: 3mjk.mga2 License: GPL v2 or later; LGPL v2.1 or later Group: Office Source0: openoffice.org-openclipart-0.18.tar.xz URL: http://www.openoffice.org/ Requires: libreoffice-core >= 3.5.0 Conflicts: openoffice.org3-openclipart Provides: libreoffice-galleries = %version Requires: clipart-openclipart >= 0.18 %if %{without tarball} BuildRequires: x11-server-xvfb BuildRequires: libreoffice-core >= 3.5 BuildRequires: libreoffice-graphicfilter >= 3.5 BuildRequires: clipart-openclipart >= 0.18 BuildRequires: update-alternatives Conflicts: openoffice.org3-openclipart Requires: clipart-openclipart >= 0.18 %endif BuildRoot: %{_tmppath}/%{name}-%{version}-build BuildArch: noarch %description This package contains an extensive set of extra galleries for libreoffice. It can be used to enrich documents with graphics arts. %description -l de Dieses Paket enthält eine umfangreiche Reihe von zusätzlichen Galerien für libreoffice. Es kann verwendet werden, um Dokumente mit Grafiken zu bereichern. %prep %if %{with tarball} %setup -q -n openoffice.org-openclipart-0.18 %else %setup -q -c -T -n openoffice.org-openclipart-0.18 %endif %if %{without tarball} %build OPENCLIPART_DIR=%{_datadir}/images/openclipart GAL_BIN=%{_gengal} GAL_DIR=$(pwd)/gallery # start number for the new galleries GAL_NUMBER_FROM=70 XVFB=/usr/bin/Xvfb XDISPLAY=98 echo 'Starting Xvfb...' # try only 10-times to avoid infinite loop while [ "$XDISPLAY" != 108 ]; do if [ ! -f /tmp/.X$XDISPLAY-lock ]; then echo " trying display :$XDISPLAY ..." sleep 2s $XVFB -ac :$XDISPLAY & trap "kill $! > /dev/null 2>&1 || true" EXIT # let server to start sleep 10s if [ -f /tmp/.X$XDISPLAY-lock ]; then break fi fi XDISPLAY=$(($XDISPLAY+1)) done if ! test -f /tmp/.X$XDISPLAY-lock ; then echo "Error: Unable to start Xvfb" >&2 exit 1 fi export DISPLAY=":$XDISPLAY" echo "Using DISPLAY="$DISPLAY rm -rf $GAL_DIR mkdir -p $GAL_DIR echo "Building extra galleries from openclipart..." for dir in $(find -L $OPENCLIPART_DIR -mindepth 1 -maxdepth 1 -type d | sort); do # get the gallery name from the directory name # and make the first character uppercase gal_name=${dir##*/} gal_name=$(echo $gal_name | tr '_-' ' ') gal_name_rest=${gal_name#?} gal_name_first_char=${gal_name%$gal_name_rest} gal_name_first_char=$(echo $gal_name_first_char | tr 'a-z' 'A-Z') gal_name=$gal_name_first_char$gal_name_rest echo "Doing gallery $gal_name..." find $dir -name '*.png' -print0 | sort -z | { xargs -0 $GAL_BIN \ --name "$gal_name" \ --path "$GAL_DIR" \ --number-from "$GAL_NUMBER_FROM" || exit 1 } done %endif %install rm -rf $RPM_BUILD_ROOT install -d $RPM_BUILD_ROOT%{_ooogaldir} cp -a gallery/* $RPM_BUILD_ROOT%{_ooogaldir} %clean rm -rf $RPM_BUILD_ROOT %files %defattr(644,root,root,755) %{_ooogaldir}/* %changelog * Mon May 14 2012 Jaroslav Krejci <krejci@zstenis.com> libreoffice-openclipart-3-3mjk.mga2 - change path to libreoffice 3.5 * Wed Oct 26 2011 Jaroslav Krejci <krejci@zstenis.com> libreoffice-openclipart-3-2mjk.mga1 - change path to libreoffice 3.4 * Tue Jun 21 2011 Jaroslav Krejci <krejci@zstenis.com> libreoffice-openclipart-3-1mjk.mga1 - build for Mageia 1 * Sat Dec 11 2010 maik3531 <maik3531 at yahoo.de> libreoffice-openclipart-3-1pclos2010 - change path to libreoffice 3.3 * Mon Jul 26 2010 maik3531 <maik3531 at yahoo.de> openoffice.org3-openclipart-3-5pclos2010 - change path to 3.2 * Sun Jun 07 2009 Texstar <texstar@gmail.com> openoffice.org3-openclipart-3-4pclos2009 - change path to 3.1 * Sun Apr 12 2009 maik3531 <maik3531@yahoo.de> openoffice.org3-openclipart-3-3pclos2007 - fix XVFB and OPENCLIPART_DIR Path - create new tarball * Sun Apr 12 2009 maik3531 <maik3531@yahoo.de> openoffice.org3-openclipart-3-2pclos2007 - compared with PLD to png instead of svg * Sat Apr 11 2009 maik3531 <maik3531@yahoo.de> openoffice.org3-openclipart-3-1pclos2007 - rebuild from suse vor PCLinuxOS 2009.1 #ftp://ftp.pbone.net/mirror/ftp5.gwdg.de/pub/opensuse/repositories/OpenOffice.org%3A/UNSTABLE/openSUSE_Factory/src/OpenOffice_org-openclipart-3-3.22.src.rpm - add to *.blacklist food/fruit/turkey_platter_01_with_fruit_and_vegitables_01.svg food/turkey_platter_01_with_fruit_and_vegitables_01.svg
View Attachment As Raw
Actions:
View
Attachments on
bug 462
: 2313