gunnar: server/horde/php-channel-horde Makefile, NONE, 1.1 php-channel-horde.spec, NONE, 1.1
cvs at kolab.org
cvs at kolab.org
Thu Nov 8 12:54:54 CET 2007
Author: gunnar
Update of /kolabrepository/server/horde/php-channel-horde
In directory doto:/tmp/cvs-serv17633/horde/php-channel-horde
Added Files:
Makefile php-channel-horde.spec
Log Message:
kolab/issue2128 (Building horde-framework-kolab without http access fails)
--- NEW FILE: Makefile ---
ifeq "x$(RPM)" "x"
RPM = $(HOME)/bin/openpkg rpm
endif
ifeq "x$(KOLABRPMSRC)" "x"
KOLABRPMSRC = $(HOME)/RPM/SRC
endif
ifeq "x$(KOLABRPMPKG)" "x"
KOLABRPMPKG = $(HOME)/RPM/PKG
endif
ifeq "x$(KOLABRPMTMP)" "x"
KOLABRPMTMP = $(HOME)/RPM/TMP
endif
PACKAGE = php-channel-horde
VERSION = 1.0
RELEASE = 1
SOURCE_0=http://pear.horde.org/channel.xml
.PHONY: all
all: $(PACKAGE)-$(VERSION)-$(RELEASE).src.rpm
.PHONY: dist
dist: all
cp $(PACKAGE)-$(VERSION)-$(RELEASE).src.rpm ../../stage/
.PHONY: clean
clean:
rm -rf /kolab/RPM/TMP/$(PACKAGE)
rm -rf $(PACKAGE)-$(VERSION)-$(RELEASE).src.rpm
rm -rf *~
$(PACKAGE)-$(VERSION)-$(RELEASE).src.rpm: Makefile $(PACKAGE).spec
test -d $(KOLABRPMSRC)/$(PACKAGE) || mkdir $(KOLABRPMSRC)/$(PACKAGE)
cd $(KOLABRPMSRC)/$(PACKAGE) && wget "$(SOURCE_0)"
cp $(PACKAGE).spec $(KOLABRPMSRC)/$(PACKAGE)
cd $(KOLABRPMSRC)/$(PACKAGE) && $(RPM) -ba $(PACKAGE).spec
cp -p $(KOLABRPMPKG)/$(PACKAGE)-$(VERSION)-$(RELEASE).src.rpm .
--- NEW FILE: php-channel-horde.spec ---
%define pear_xmldir %{l_prefix}/var/pear
Name: php-channel-horde
Version: 1.0
Release: 1
Summary: Adds pear.horde.org channel to PEAR
Group: Development/Languages
License: N/A
URL: http://pear.horde.org/
Source0: http://pear.horde.org/channel.xml
# Build Info
Prefix: %{l_prefix}
BuildRoot: %{l_buildroot}
BuildPreReq: php, php::with_pear = yes
Requires: php, php::with_pear = yes
%description
This package adds the pear.horde.org channel which allows PEAR packages
from this channel to be installed.
%prep
%setup -q -c -T
%build
%install
rm -rf $RPM_BUILD_ROOT
mkdir -p $RPM_BUILD_ROOT%{pear_xmldir}
install -pm 644 %{SOURCE0} $RPM_BUILD_ROOT%{pear_xmldir}/pear.horde.org.xml
%{l_rpmtool} files -v -ofiles -r$RPM_BUILD_ROOT %{l_files_std}
%clean
rm -rf $RPM_BUILD_ROOT
%post
env PHP_PEAR_PHP_BIN="%{l_prefix}/bin/php -d safe_mode=off" \
%{l_prefix}/bin/pear -d php_dir=%{l_prefix}/lib/php channel-add %{pear_xmldir}/pear.horde.org.xml || \
echo "Channel already exists!" && sleep 1
env PHP_PEAR_PHP_BIN="%{l_prefix}/bin/php -d safe_mode=off" \
%{l_prefix}/bin/pear -d php_dir=%{l_prefix}/lib/php channel-update %{pear_xmldir}/pear.horde.org.xml || \
echo "Could not update channel pear.horde.org!" && sleep 1
%postun
env PHP_PEAR_PHP_BIN="%{l_prefix}/bin/php -d safe_mode=off" \
%{l_prefix}/bin/pear -d php_dir=%{l_prefix}/lib/php channel-delete pear.horde.org || \
echo "Could not delete channel pear.horde.org!" && sleep 1
%files -f files
More information about the commits
mailing list