[exim-cvs] cvs commit: exim/exim-course/rpm exim-course.spec

Top Page
Delete this message
Reply to this message
Author: Tony Finch
Date:  
To: exim-cvs
Subject: [exim-cvs] cvs commit: exim/exim-course/rpm exim-course.spec
fanf2 2006/07/17 16:41:30 BST

  Modified files:
    exim-course/rpm      exim-course.spec 
  Log:
  Fix install.
  Use the year as the version number, since we're agglomeratnig several
  bits in the same RPM.


  Revision  Changes    Path
  1.6       +8 -2      exim/exim-course/rpm/exim-course.spec


  Index: exim-course.spec
  ===================================================================
  RCS file: /home/cvs/exim/exim-course/rpm/exim-course.spec,v
  retrieving revision 1.5
  retrieving revision 1.6
  diff -u -u -r1.5 -r1.6
  --- exim-course.spec    17 Jul 2006 15:04:38 -0000    1.5
  +++ exim-course.spec    17 Jul 2006 15:41:30 -0000    1.6
  @@ -1,8 +1,9 @@
  -# $Cambridge: exim/exim-course/rpm/exim-course.spec,v 1.5 2006/07/17 15:04:38 fanf2 Exp $
  +# $Cambridge: exim/exim-course/rpm/exim-course.spec,v 1.6 2006/07/17 15:41:30 fanf2 Exp $
   #
   # The RPM spec file for the package which customizes PWF Linux for the
   # Exim course. This is a little bit sketchy and assumes a working
   # environment rather than specifying the dependencies in full detail.
  +# The smtpc stuff should really be a separate package...


   # Check the version numbers in the header below,
   # and in the %install and %post sections.
  @@ -13,7 +14,7 @@
   License:      GPL
   Group:        Development/Sources
   Autoreqprov:  on
  -Version:      4.62
  +Version:      2006
   Release:      1
   Summary:      Customize PWF Linux for the Exim course
   BuildRoot:    %{_tmppath}/%{name}-%{version}-build
  @@ -41,23 +42,28 @@
   : do nothing


%build
+mkdir %{name}-%{version}
+cd %{name}-%{version}
wget http://www-uxsup.csx.cam.ac.uk/~fanf2/hermes/src/smtpc/smtpc-1.36.tar.gz
tar fxz smtpc-1.36.tar.gz
cd smtpc-1.36
make
-pwd

%install
# ensure clean install tree
rm -rf ${RPM_BUILD_ROOT}
mkdir -p ${RPM_BUILD_ROOT}/usr/sbin
mkdir -p ${RPM_BUILD_ROOT}/usr/local/bin
+# install stuff
cat <<EOF >> ${RPM_BUILD_ROOT}/usr/sbin/sendmail
#!/bin/sh
echo sendmail is not installed
exit 1
EOF
+cp %{name}-%{version}/smtpc-1.36/smtpc ${RPM_BUILD_ROOT}/usr/local/bin/smtpc
+# fix perms
chmod +x ${RPM_BUILD_ROOT}/usr/sbin/sendmail
+chmod +x ${RPM_BUILD_ROOT}/usr/local/bin/smtpc

%files
/usr/sbin/sendmail