gunnar: server/kolab-webclient-h4/imp-h4 Makefile, NONE, 1.1 imp-h4.spec, NONE, 1.1

cvs at kolab.org cvs at kolab.org
Thu Feb 18 11:06:55 CET 2010


Author: gunnar

Update of /kolabrepository/server/kolab-webclient-h4/imp-h4
In directory doto:/tmp/cvs-serv10085/kolab-webclient-h4/imp-h4

Added Files:
	Makefile imp-h4.spec 
Log Message:
Added the next Horde4 piece: imp. Does work on my test install but there are still some major issues and installation on another system should be close but not yet fully functional.

--- NEW FILE: Makefile ---
STAGING = ../../stage

include ../../make-helper/kolab.mk

GIT_PACKAGE = $(shell grep "%define[ ]*V_gitpath" *.spec | sed -e "s/.*V_gitpath\s*\([0-9a-z-]*\).*/\1/")
SAFE_COMMIT = $(shell grep "%define[ ]*V_commit" *.spec | sed -e "s/.*V_commit\s*\([0-9a-z-]*\).*/\1/")
SOURCE_NAME = $(shell grep "%define[ ]*V_source_name" *.spec | sed -e "s/.*V_source_name\s*\([0-9a-z-]*\).*/\1/")
SOURCE_PACKAGE = $(SOURCE_NAME)-$(SAFE_COMMIT)

SOURCE_URL = http://files.kolab.org/incoming/wrobel/
SOURCE_0 = $(SOURCE_NAME)-$(VERSION)-$(SAFE_COMMIT).tar.bz2

include ../../make-helper/package.mk
include ../../make-helper/patch-series.mk

# Get the list of templates if there are any in the template directory
TEMPLATES = $(shell ls templates/$(PACKAGE)-$(SAFE_COMMIT)/*.template 2> /dev/null)

# Get the list of configuration files if there are any in the configuration directory
CONFIGURATION = $(shell ls configuration/$(PACKAGE)-$(SAFE_COMMIT)/*.php 2> /dev/null)

EXTRA = package.patch $(TEMPLATES) $(CONFIGURATION)

include ../../make-helper/package-new.mk
include ../../make-helper/horde-snapshot.mk

--- NEW FILE: imp-h4.spec ---
# Macros
%define         V_package imp-h4
%define         V_gitpath imp
%define         V_commit  0ef4c583a74e6521f7f2e7ea9f06c3a9f08bd091
%define         V_version 4.999
%define         V_release 20100119
%define         V_source_name imp

# Package Information
Name:		%{V_package}
Summary:	IMP provides webmail access to IMAP and POP3 accounts.
URL:		http://www.horde.org/
Packager:	Gunnar Wrobel <wrobel at pardus.de> (p at rdus)
Version:	%{V_version}
Release:	%{V_release}
License:	GPL
Group:		MAIL
Distribution:	OpenPKG

# List of Sources
Source0:	http://ftp.horde.org/pub/%{V_package}/%{V_source_name}-%{V_version}-%{V_commit}.tar.bz2
Source1:        webclient4-imp_conf.php.template
Source2:        webclient4-imp_header.php.template
Source3:        webclient4-imp_hooks.php.template
Source4:        webclient4-imp_menu.php.template
Source5:        webclient4-imp_mime_drivers.php.template
Source6:        webclient4-imp_motd.php.template
Source7:        webclient4-imp_prefs.php.template
Source8:        webclient4-imp_servers.php.template
Source9:        webclient4-imp_spelling.php.template
Source10:       10-kolab_conf_base.php
Source11:       10-kolab_servers_base.php
Source12:       conf.php
Source13:       11-kolab_conf_imp.php

# List of Patches
Patch0:         package.patch

# Build Info
Prefix:		%{l_prefix}
BuildRoot:	%{l_buildroot}

#Pre requisites
BuildPreReq:  OpenPKG, openpkg >= 20070603
BuildPreReq:  php, php::with_pear = yes
PreReq:       horde-h4 >= 3.999
PreReq:       Horde_Imap_Client-H4
PreReq:       Horde_Editor-H4
PreReq:       Horde_Vfs-H4

AutoReq:      no
AutoReqProv:  no

%description 
IMP is the Internet Messaging Program. It is written in PHP and
provides webmail access to IMAP and POP3 accounts.

%prep
	%setup -q -c %{V_package}-%{V_version}

	cd %{V_source_name}-%{V_commit}
	%patch -p1 -P 0
	cd ..

%build

%install

	%{l_shtool} install -d $RPM_BUILD_ROOT%{l_prefix}/var/kolab/www/client4/imp
	%{l_shtool} install -d $RPM_BUILD_ROOT%{l_prefix}/var/kolab/www/client4/config/conf.d
	%{l_shtool} install -d $RPM_BUILD_ROOT%{l_prefix}/var/kolab/webclient4_data/storage
	%{l_shtool} install -d $RPM_BUILD_ROOT%{l_prefix}/etc/kolab/templates	

	cd %{V_source_name}-%{V_commit}

	cd config
	for CONFIG in *.dist;                          \
	    do                                         \
	      cp $CONFIG `basename $CONFIG .dist`;     \
	      mkdir -p `basename $CONFIG .php.dist`.d; \
	done
	cd ..

	#rm test.php

	#find . -type f | grep '\.orig$' | xargs rm -f

	cp -r * $RPM_BUILD_ROOT%{l_prefix}/var/kolab/www/client4/imp

        sqlite $RPM_BUILD_ROOT%{l_prefix}/var/kolab/webclient4_data/storage/imp.db < scripts/sql/imp.sql

	cd ..

	%{l_shtool} install -d $RPM_BUILD_ROOT%{l_prefix}/var/kolab/www/client4/imp/config/conf.d
	%{l_shtool} install -d $RPM_BUILD_ROOT%{l_prefix}/var/kolab/www/client4/imp/config/header.d
	%{l_shtool} install -d $RPM_BUILD_ROOT%{l_prefix}/var/kolab/www/client4/imp/config/hooks.d
	%{l_shtool} install -d $RPM_BUILD_ROOT%{l_prefix}/var/kolab/www/client4/imp/config/menu.d
	%{l_shtool} install -d $RPM_BUILD_ROOT%{l_prefix}/var/kolab/www/client4/imp/config/mime_drivers.d
	%{l_shtool} install -d $RPM_BUILD_ROOT%{l_prefix}/var/kolab/www/client4/imp/config/motd.d
	%{l_shtool} install -d $RPM_BUILD_ROOT%{l_prefix}/var/kolab/www/client4/imp/config/prefs.d
	%{l_shtool} install -d $RPM_BUILD_ROOT%{l_prefix}/var/kolab/www/client4/imp/config/servers.d
	%{l_shtool} install -d $RPM_BUILD_ROOT%{l_prefix}/var/kolab/www/client4/imp/config/spelling.d

	%{l_shtool} install -c -m 644 %{l_value -s -a} %{S:1} %{S:2} %{S:3} %{S:4} %{S:5} %{S:6} %{S:7} %{S:8} %{S:9} \
	  $RPM_BUILD_ROOT%{l_prefix}/etc/kolab/templates

	%{l_shtool} install -c -m 644 %{l_value -s -a} %{S:10} $RPM_BUILD_ROOT%{l_prefix}/var/kolab/www/client4/imp/config/conf.d/
	%{l_shtool} install -c -m 644 %{l_value -s -a} %{S:11} $RPM_BUILD_ROOT%{l_prefix}/var/kolab/www/client4/imp/config/servers.d/
	%{l_shtool} install -c -m 644 %{l_value -s -a} %{S:12} $RPM_BUILD_ROOT%{l_prefix}/var/kolab/www/client4/imp/config/
	%{l_shtool} install -c -m 644 %{l_value -s -a} %{S:13} $RPM_BUILD_ROOT%{l_prefix}/var/kolab/www/client4/config/conf.d/

	sed -i -e 's#@@@horde_confdir@@@#%{l_prefix}/var/kolab/www/client4/imp/config#' $RPM_BUILD_ROOT%{l_prefix}/etc/kolab/templates/*.php.template

	%{l_rpmtool} files -v -ofiles -r$RPM_BUILD_ROOT %{l_files_std} \
            '%config %{l_prefix}/etc/kolab/templates/webclient4-imp_conf.php.template' \
            '%config %{l_prefix}/etc/kolab/templates/webclient4-imp_header.php.template' \
            '%config %{l_prefix}/etc/kolab/templates/webclient4-imp_hooks.php.template' \
            '%config %{l_prefix}/etc/kolab/templates/webclient4-imp_menu.php.template' \
            '%config %{l_prefix}/etc/kolab/templates/webclient4-imp_mime_drivers.php.template' \
            '%config %{l_prefix}/etc/kolab/templates/webclient4-imp_motd.php.template' \
            '%config %{l_prefix}/etc/kolab/templates/webclient4-imp_prefs.php.template' \
            '%config %{l_prefix}/etc/kolab/templates/webclient4-imp_servers.php.template' \
            '%config %{l_prefix}/etc/kolab/templates/webclient4-imp_spelling.php.template' \
            '%config(noreplace) %defattr(-,%{l_nusr},%{l_ngrp}) %{l_prefix}/var/kolab/webclient4_data/storage/imp.db' \
            %dir '%defattr(-,%{l_nusr},%{l_ngrp})' %{l_prefix}/var/kolab/webclient4_data/storage \
	    '%defattr(-,%{l_nusr},%{l_ngrp})' %{l_prefix}/var/kolab/www/client4/imp/config/conf.php


%clean
	rm -rf $RPM_BUILD_ROOT

%files -f files





More information about the commits mailing list