Mailinglist Archive: opensuse-packaging (208 mails)

< Previous Next >
Re: [opensuse-packaging] Packaging Questions
  • From: Nelson Marques <nmo.marques@xxxxxxxxx>
  • Date: Thu, 10 May 2012 20:43:58 +0100
  • Message-id: <CAHWXQKM0DdAHOcSFr5kM=UKswwKHegY4=sUdpHFTc_U=uioJ3A@mail.gmail.com>
Pascal,

Thanks for the corrections and for dedicating some time to elaborate
them. It's important (from my unwanted perspective) that experienced
people like yourself pass on the good procedures for people starting
up.

NM

2012/5/10 Pascal Bleser <pascal.bleser@xxxxxxxxxxxx>:
On 2012-05-10 17:02:19 (+0100), Nelson Marques <nmo.marques@xxxxxxxxx> wrote:
The correct way would be to properly patch the software, maybe
including support for DESTDIR and submit upstream... That sort of
fixes is in my humble opinion 'the way of the slacker'...

Wouldnt it be more benefic for all if this changes would be applied by
upstream? I would suppose so... but what would I know about it ;)

A patch for DESTDIR support, yes, definitely, as that is good
practice.

Something like going from

prefix = /usr/local
libdir = $(prefix)/lib/nut
bindir = $(prefix)/bin
mandir = $(prefix)/man/man1

to this:

DESTDIR =
prefix = /usr/local
libdir = $(prefix)/lib/nut
bindir = $(prefix)/bin
mandir = $(prefix)/man/man1

(and obviously use $DESTDIR in the install target)

As well as making strip optional.

But changing the prefix from /usr/local to /usr is not, in my
opinion, something one should push to upstream, as when someone
builds from source without any packaging, /usr/local is actually
the right spot.

But as said, the paths depend on the distribution (e.g. mandir,
it's not /usr/share/man everywhere, in the olden days and on
some current distributions (eg. slackware if I'm not mistaken),
it's /usr/man), and they are properly defined as variables in
the Makefile. The purpose of such variables is to be overridden
when invoking make.
That's precisely what they have been made for (just like there
are parameters in configure), so why not use them, why going
through the hassle of a patch.

For DESTDIR, though, I agree, but using
 make prefix="%{buildroot}{_prefix}"
works too.
Depends on how much time you want to spend on packaging it, and
your level of experience.

[...]

cheers
--
 -o) Pascal Bleser
 /\\ http://opensuse.org -- we haz green
 _\_v http://fosdem.org   -- we haz conf



--
Nelson Marques
// I've stopped trying to understand sandwiches with a third piece of
bread in the middle...
--
To unsubscribe, e-mail: opensuse-packaging+unsubscribe@xxxxxxxxxxxx
To contact the owner, e-mail: opensuse-packaging+owner@xxxxxxxxxxxx

< Previous Next >