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

how the other guys do things

Thought someone might find this amusing.

----- Forwarded message from Tom Payne <ion@tompayne.org> -----

From: Tom Payne <ion@tompayne.org>
Date: Thu, 10 Apr 2003 11:27:03 +0100
To: Ion <ion@list.rt.fm>
Subject: Fw: Re: Cygwin and ion-devel-20030408
X-Spam-Status: No, hits=-17.8 required=5.0
	autolearn=ham version=2.53

[Tuomo: I meant to post this to the list too, sorry you get it twice]

On Thu, Apr 10, 2003 at 09:38:24AM +0300, Tuomo Valkonen wrote:
> PS. Is anyone else having trouble with libtool? If this seems to be common,
> I may still have to reconsider using it.

It's designed to work closely with autoconf. autoconf has a
AC_PROG_LIBTOOL macro that does all the work for you.

Plea: please use autoconf/automake for ion. I know this has been debated
a few times on my list, but now that you're using libtool it really makes
sense! Here's my reason:

The Gentoo ebuild for ion-devel-20030327 contains (full snip to demonstrate
just how much code is required):


cp system.mk system.mk.orig
sed -e 's:^PREFIX=/usr/local/ion-devel:PREFIX=/usr:' \
	-e 's:^ETCDIR=$(PREFIX)/etc:ETCDIR=/etc/X11:' \
	-e 's:^MANDIR=$(PREFIX)/man:MANDIR=$(PREFIX)/share/man:' \
	-e 's:^DOCDIR=$(PREFIX)/doc:DOCDIR=$(PREFIX)/share/doc:' \
	system.mk.orig > system.mk

local ion_version=`cut -d\  -f3 version.h | tr -d \"`
cp Makefile Makefile.orig
sed -e "s:\$(DOCDIR)/ion:\$(DOCDIR)/ion-devel-${ion_version}:" \
	Makefile.orig > Makefile

if [ "`use truetype`" ]; then
	local xft_config=`which xft-config 2> /dev/null`
	if [ -n "${xft_config}" ] && [ -x "${xft_config}" ]; then
		local xft_cflags=`${xft_config} --cflags`
		local xft_libs=`${xft_config} --libs`
		local xft_cflags=
		local xft_libs="-lXft"
	cp system.mk system.mk.orig
	sed -e 's:#DEFINES += -DCF_XFT:DEFINES += -DCF_XFT:' \
		-e "s:#X11_INCLUDES += \`xft-config --cflags\`:X11_INCLUDES += ${xft_cflags}:" \
		-e "s:#X11_LIBS += \`xft-config --libs\`:X11_LIBS += ${xft_libs}:" \
		system.mk.orig > system.mk


Now that a new version of ion is out, I have to write another script like
the one SPECIFIC to this version of Ion. I need to check all the sed scripts
still work, and add new ones to to support Lua and whatever else has
changed. Please can I just do:

	./configure --enable-utf8 --disable-xinerama --with-lua=/usr/local


I've got virtually fully functional autoconf scripts that I can email to



----- End forwarded message -----

The kicker is the rest of the conversation, with Per Olofsson, who
maintains ion for Debian.

Per Olofsson:
> Instead of using sed, why don't you just pass these variables to make?
> That works perfectly well, and you don't have to check for versions
> because variables that are not used are just silently ignored.

Tom Payne again:
> Good idea. I'll look into it.

see shy jo

Attachment: pgpcHW6ayITXi.pgp
Description: PGP signature

Reply to: