2000-05-11-03:13:38 Thomas Roessler:
> I'd suggest you use the DESTDIR mechanism.  That is, you
> ./configure mutt with the directories you want on the
> target system.  Then, when it comes to installing things,
> you type:
> 
>       make DESTDIR=/what/ever/path/you/want install

Thanks; that's nicely simpler than what I'd been using before, with
prefix= and docdir= settings. With that tweak, I think my Mutt spec
file may just be simple enough, close enough to generic, to deserve
consideration for inclusion in the Mutt distribution. If you were to
place the spec file anywhere inside the tarball --- e.g. in
contrib/redhat/mutt.spec --- anywhere, as long as the filename ends
in .spec --- then RPM users who download the tarball could
automatically build the rpm by going

        sudo rpm -ta mutt-1.2i.tar.gz

One other tweak that I'd encourage considering. If there were some
way you could rig the "make install" process so it doesn't bomb off
in the middle if it can't make mutt_dotlock sgid mail or whatever,
then the spec file could specify the correct perms, and a full
successful rpm build would run fine as any normal, non-privileged
user, and privs would only be needed for the actual install. I
believe I've specified the right perms in the spec file, so the only
reason this build has to be run as root is to prevent the make
install step from failing.

-Bennett
Name: mutt
Version: 1.2i
Release: 2
Source: ftp://ftp.mutt.org/pub/mutt/mutt-%{version}.tar.gz
Group: Applications/Mail
License: GPL
Summary: The Mutt Mail User Agent
BuildRoot: /var/tmp/%{name}-rpmroot
%description

Mutt is a small but very powerful full-screen Unix mail client. Features
include MIME, POP3, multiple mailbox formats, colour, message threading,
scoring, and bindable keys.

This is the International version of mutt *with* PGP support.

%prep
%setup -n mutt-1.2
%build
./configure --prefix=/usr \
            --enable-pop \
            --enable-imap \
            --with-ssl

make keymap_defs.h
make

%install
mkdir -p $RPM_BUILD_ROOT/usr/{bin,etc,man/man1,doc/mutt-%{version}}
make DESTDIR=$RPM_BUILD_ROOT install
find $RPM_BUILD_ROOT -type f | \
        xargs file | \
        awk -F: '/not stripped/{print $1}' | \
        xargs strip

%changelog
* Thu May 11 2000 Bennett Todd <[EMAIL PROTECTED]>
  - Release 2
  - switched to use DESTDIR, thanks to Thomas Roessler <[EMAIL PROTECTED]>
  - fixed perms on mutt_dotlock
  - removed /usr/share/mutt, it wasn't being used any more
* Wed May 10 2000 Bennett Todd <[EMAIL PROTECTED]>
  - Initial wrap

%files
%defattr(-,root,root)
/usr/bin/mutt
/usr/bin/muttbug
/usr/bin/pgpewrap
/usr/bin/pgpring
%attr(2755,root,mail) /usr/bin/mutt_dotlock
%doc /usr/man/man*/*
%doc /usr/doc/mutt
/usr/share/*
%config /usr/etc/*

PGP signature

Reply via email to