Re: rpmbuild questions

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Thu, 30 Dec 2010, Tim Born wrote:

> Find an example spec file to modify.  That will give you a big leg up
> the learning curve.

Here is my spec for installing "off-distro" versions of firefox (for
testing web apps with different browser versions).  Notice that
the %build step is a no-op.

# $Id$
# Authority: gathman

# Dist: nodist

Summary: Mozilla Firefox Web browser.
Name: firefox35
Version: 3.5.2
Release: 1
License: MPL/LGPL
Group: Applications/Internet
URL: http://www.mozilla.org/projects/firefox/

Packager: Stuart Gathman <stuart@xxxxxxxxxxx>
Vendor: Mozilla

Source: firefox-%{version}.tar.bz2
Source1: mozilla-firefox.desktop
NoSource: 0
BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root

ExclusiveArch: i386

%description
Mozilla Firefox is an open-source web browser, designed for standards
compliance, performance and portability.

%prep

%build

%install
%{__rm} -rf %{buildroot}
mkdir -p %{buildroot}/usr/share/applications
mkdir -p %{buildroot}/usr/lib/mozilla
mkdir -p %{buildroot}/usr/bin
cd %{buildroot}/usr/lib
tar xfj %{SOURCE0}
mv firefox/plugins %{buildroot}/usr/lib/mozilla
ln -sf /usr/lib/mozilla/plugins %{buildroot}/usr/lib/firefox
mv firefox firefox-%{version}
ln -sf /usr/lib/firefox-%{version}/firefox %{buildroot}/usr/bin/firefox35
cp %{SOURCE1} %{buildroot}/usr/share/applications/mozilla-firefox35.desktop
ed %{buildroot}/usr/lib/firefox-%{version}/firefox <<'EOF'
/^moz_libdir=\/usr\/local/
c
moz_libdir=/usr/lib/firefox-%{version}
.
w
q
EOF

%clean
%{__rm} -rf %{buildroot}

%files
%defattr(-, root, root, 0755)
/usr/lib/firefox-%{version}
/usr/lib/mozilla/plugins
/usr/bin/firefox35
/usr/share/applications/*

%changelog
* Mon Oct 06 2008 Stuart Gathman <stuart@xxxxxxxxxxx> - 3.5.1-1
- New release
* Mon Oct 06 2008 Stuart Gathman <stuart@xxxxxxxxxxx> - 2.0.0.17-1
- New release
* Tue Jan 22 2008 Stuart Gathman <stuart@xxxxxxxxxxx> - 2.0.0.11-1
- New release, rename to firefox2
* Mon Apr 02 2007 Stuart Gathman <stuart@xxxxxxxxxxx> - 2.0.0.3-2
- Add desktop 
* Sun Apr 01 2007 Stuart Gathman <stuart@xxxxxxxxxxx> - 2.0.0.3-1
- RPM package

-- 
	      Stuart D. Gathman <stuart@xxxxxxxx>
    Business Management Systems Inc.  Phone: 703 591-0911 Fax: 703 591-6154
"Confutatis maledictis, flammis acribus addictis" - background song for
a Microsoft sponsored "Where do you want to go from here?" commercial.
_______________________________________________
Rpm-list mailing list
Rpm-list@xxxxxxxxxxxxx
http://lists.rpm.org/mailman/listinfo/rpm-list


[Index of Archives]     [RPM Ecosystem]     [Linux Kernel]     [Red Hat Install]     [PAM]     [Red Hat Watch]     [Red Hat Development]     [Red Hat]     [Gimp]     [Yosemite News]     [IETF Discussion]

  Powered by Linux