Author: baggins                      Date: Sun Feb  5 13:42:36 2012 GMT
Module: packages                      Tag: HEAD
---- Log message:
- revert last commit
- looks like iProgrammers put 1.6rc as 1.5.1, we'll have to wait for proper 
tar.bz2 :/

---- Files affected:
packages/cups:
   cups.spec (1.317 -> 1.318) 

---- Diffs:

================================================================
Index: packages/cups/cups.spec
diff -u packages/cups/cups.spec:1.317 packages/cups/cups.spec:1.318
--- packages/cups/cups.spec:1.317       Sun Feb  5 14:26:31 2012
+++ packages/cups/cups.spec     Sun Feb  5 14:42:31 2012
@@ -6,11 +6,14 @@
 %bcond_with    avahi           # DNS Service Discovery support via Avahi
 %bcond_without ldap            # do not include LDAP support
 %bcond_without gssapi          # do not include GSSAPI support
+%bcond_without php             # don't build PHP extension/support in web 
interface
+%bcond_without perl            # don't build Perl extension/support in web 
interface
 %bcond_without python          # don't build Python support in web interface
 %bcond_without slp             # do not include SLP support
 %bcond_without static_libs     # don't build static library
 
 %define                pdir CUPS
+%include       /usr/lib/rpm/macros.perl
 Summary(pl.UTF-8):     Ogólny system druku dla Uniksa
 Summary(pt_BR.UTF-8):  Sistema Unix de Impressão
 Name:          cups
@@ -68,12 +71,15 @@
 %{?with_slp:BuildRequires:     openslp-devel}
 %{!?with_gnutls:BuildRequires: openssl-devel}
 BuildRequires: pam-devel
+%{?with_php:BuildRequires:     php-devel >= 4:5.0.0}
 BuildRequires: pkgconfig
+BuildRequires: rpm-perlprov
 BuildRequires: rpmbuild(macros) >= 1.344
 Requires(post,preun):  /sbin/chkconfig
 Requires:      %{name}-libs = %{epoch}:%{version}-%{release}
 Requires:      openssl-tools
 Requires:      pam >= 0.77.3
+Requires:      perl-modules
 Requires:      rc-scripts
 Suggests:      ImageMagick-coder-pdf
 Suggests:      cups-filter-pstoraster
@@ -213,6 +219,35 @@
 Bibliotecas estáticas para desenvolvimento de programas que usam as
 bibliotecas do CUPS.
 
+%package -n perl-cups
+Summary:       Perl module for CUPS
+Summary(pl.UTF-8):     Moduł Perla CUPS
+License:       GPL v2 + openssl exception
+Group:         Development/Languages/Perl
+Requires:      %{name}-lib = %{epoch}:%{version}-%{release}
+
+%description -n perl-cups
+Perl module for Common Unix Printing System.
+
+%description -n perl-cups -l pl.UTF-8
+Moduł Perla do ogólnego systemu druku dla Uniksa.
+
+%package -n php-cups
+Summary:       PHP module for CUPS
+Summary(pl.UTF-8):     Moduł PHP CUPS
+License:       GPL v2 + openssl exception
+Group:         Development/Languages/PHP
+Requires:      %{name}-lib = %{epoch}:%{version}-%{release}
+%{?requires_php_extension}
+Requires:      /etc/php/conf.d
+Requires:      php-common >= 4:5.0.0
+
+%description -n php-cups
+PHP module for Common Unix Printing System.
+
+%description -n php-cups -l pl.UTF-8
+Moduł PHP do ogólnego systemu druku dla Uniksa.
+
 %package backend-usb
 Summary:       USB backend for CUPS
 Summary(pl.UTF-8):     Backend USB dla CUPS-a
@@ -329,10 +364,28 @@
        --with-optim=-Wno-format-y2k \
        %{?with_dnssd:--with-dnssd-libs=x} \
        %{?with_dnssd:--with-dnssd-includes=x} \
+       %{?with_perl:--with-perl=%{_bindir}/perl} \
+       %{?with_php:--with-php=%{_bindir}/php} \
        %{?with_python:--with-python=%{_bindir}/python}
 
 %{__make} %{?debug:OPTIONS="-DDEBUG"}
 
+%{__perl} -pi -e 's#-I\.\.\/\.\.#-I../.. -I../../cups#g' scripting/php/Makefile
+%{?with_php:%{__make} -C scripting/php PHPCONFIG=%{_bindir}/php-config}
+
+%if %{with perl}
+cd scripting/perl
+%{__perl} -pi -e 's@-lcups@-L../../cups $1@' Makefile.PL
+%{__perl} Makefile.PL \
+       INSTALLDIRS=vendor \
+       OPTIMIZE="%{rpmcflags} -I../.."
+# avoid rpaths generated by MakeMaker
+%{__perl} -pi -e 's@LD_RUN_PATH="\$\(LD_RUN_PATH\)" @@' Makefile
+
+%{__make}
+cd ../..
+%endif
+
 %install
 rm -rf $RPM_BUILD_ROOT
 install -d 
$RPM_BUILD_ROOT/etc/{rc.d/init.d,pam.d,logrotate.d,modprobe.d,security,sysconfig/rc-inetd}
 \
@@ -353,6 +406,21 @@
 %endif
 fi
 
+%if %{with php}
+%{__make} -C scripting/php install \
+       PHPDIR=$RPM_BUILD_ROOT%{php_extensiondir}
+install -d $RPM_BUILD_ROOT%{php_sysconfdir}/conf.d
+cat > $RPM_BUILD_ROOT%{php_sysconfdir}/conf.d/phpcups.ini << 'EOF'
+; Enable phpcups extension module
+extension=phpcups.so
+EOF
+%endif
+
+%if %{with perl}
+%{__make} -C scripting/perl install \
+       DESTDIR=$RPM_BUILD_ROOT
+%endif
+
 install %{SOURCE1} $RPM_BUILD_ROOT/etc/rc.d/init.d/%{name}
 install %{SOURCE2} $RPM_BUILD_ROOT/etc/pam.d/%{name}
 install %{SOURCE3} $RPM_BUILD_ROOT/etc/logrotate.d/%{name}
@@ -409,6 +477,14 @@
 %post  image-lib -p /sbin/ldconfig
 %postun        image-lib -p /sbin/ldconfig
 
+%post -n php-cups
+%php_webserver_restart
+
+%postun -n php-cups
+if [ "$1" = 0 ]; then
+       %php_webserver_restart
+fi
+
 %post lpd
 %service -q rc-inetd reload
 
@@ -638,6 +714,25 @@
 %{_libdir}/libcupsppdc.a
 %endif
 
+%if %{with perl}
+%files -n perl-cups
+%defattr(644,root,root,755)
+%{perl_vendorarch}/CUPS.pm
+%dir %{perl_vendorarch}/auto/CUPS
+%{perl_vendorarch}/auto/CUPS/CUPS.bs
+%{perl_vendorarch}/auto/CUPS/autosplit.ix
+%attr(755,root,root) %{perl_vendorarch}/auto/CUPS/CUPS.so
+%{_mandir}/man3/CUPS.3pm*
+%endif
+
+%if %{with php}
+%files -n php-cups
+%defattr(644,root,root,755)
+%doc scripting/php/README
+%attr(755,root,root) %{php_extensiondir}/phpcups.so
+%config(noreplace) %verify(not md5 mtime size) 
%{php_sysconfdir}/conf.d/phpcups.ini
+%endif
+
 %files backend-usb
 %defattr(644,root,root,755)
 %attr(755,root,root) %{_ulibdir}/cups/backend/usb
@@ -662,6 +757,10 @@
 All persons listed below can be reached at <cvs_login>@pld-linux.org
 
 $Log$
+Revision 1.318  2012/02/05 13:42:31  baggins
+- revert last commit
+- looks like iProgrammers put 1.6rc as 1.5.1, we'll have to wait for proper 
tar.bz2 :/
+
 Revision 1.317  2012/02/05 13:26:31  baggins
 - php and perl are gone
 
================================================================

---- CVS-web:
    
http://cvs.pld-linux.org/cgi-bin/cvsweb.cgi/packages/cups/cups.spec?r1=1.317&r2=1.318&f=u

_______________________________________________
pld-cvs-commit mailing list
[email protected]
http://lists.pld-linux.org/mailman/listinfo/pld-cvs-commit

Reply via email to