Re: automake, autoconf compiling

2005-01-14 Thread Giorgos Keramidas
On 2005-01-13 20:13, Tom Huppi <[EMAIL PROTECTED]> wrote:
>On Thu, 13 Jan 2005, Giorgos Keramidas wrote:
>> I use autoconf/automake and libtool daily at work[1].
>>
>> The programs I write have to run on at least 3 different operating
>> systems (FreeBSD, Linux and Solaris) without the need for constant
>> manual tweaking of the source.
>
> At work (former), I was responsible for code which was to *compile* on
> 6 or 7 different platforms.  I choose one (often my FreeBSD
> workstation) upon which to execute the auto-tools and didn't bother
> with most of the others though I kept a compatible set of these tools
> on Linux and Solaris for convenience.

Very well said.

I'd only like to note that the important thing to note here is:

'a compatible set of these tools'

> Indeed, the whole paradigm behind these tools is that they should
> _not_ be needed on the target platform.  'autoconf' goes to great
> pains to generate platform independent Bourne shell configure script
> for a very good reason!

The compatibility problems are usually encountered long before the
program reaches 'the target platform'.  The generated Bourne shell
scripts are indeed very platform independent.  The autoconf/automake
stuff used to write them is not though.

> Unfortunately too many people either misunderstand the paradigm and/or
> or mis-use the tools and I suspect that this is a good portion of the
> reason why the FreeBSD ports infrastructure needs to play so many
> silly games with the auto-tools.

No, the reason the Ports go through all the hoops you see is that they
are meant to be used by people who don't care or don't need to know the
internals of the autotools.  They just need a version that 'works good
enough for installing port foo/bar-1.2.3'.

One other reason is, of course, the fact that the autotools have changed
and are constantly changing the 'canonical' way of writing their input
files.  This is both a good and bad thing, depending on the viewpoint.

It is a good thing, because it shows that they are alive, actively
maintained projects.

It is a bad thing, because every time a developer tries to regenerate
the `configure' scripts and all associated files with a mismatched
autotools version, they are forced to either: a) install the exact same
versions the original configure.ac scripts have been written for, or b)
abandon the idea of using autotools altogether.

I usually go for (a), if I have a choise.  The ports people do not have
that choise, because they need to support programs coming from various
sources, with the minimal amount of changes to the original program
source.

- Giorgos

___
freebsd-questions@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to "[EMAIL PROTECTED]"


Re: automake, autoconf compiling

2005-01-13 Thread Tom Huppi



On Thu, 13 Jan 2005, Giorgos Keramidas wrote:



> I use autoconf/automake and libtool daily at work[1].
>
> The programs I write have to run on at least 3 different operating
> systems (FreeBSD, Linux and Solaris) without the need for constant
> manual tweaking of the source.

At work (former), I was responsible for code which was to
*compile* on 6 or 7 different platforms.  I choose one (often my
FreeBSD workstation) upon which to execute the auto-tools and
didn't bother with most of the others though I kept a compatible
set of these tools on Linux and Solaris for convenience.  Indeed,
the whole paradigm behind these tools is that they should _not_ be
needed on the target platform.  'autoconf' goes to great pains to
generate platform independent Bourne shell configure script for a
very good reason!  Unfortunately too many people either
misunderstand the paradigm and/or or mis-use the tools and I
suspect that this is a good portion of the reason why the FreeBSD
ports infrastructure needs to play so many silly games with the
auto-tools.  Properly speaking, the target platform shouldn't need
them at all, but I'm sure there are details of certain source
distributions which I am not aware of.

Thanks,

 - Tom

> The best way to do that is to use the same version of autotools on all
> those platforms.  So, I install the latest possible versions of these
> tools with --prefix=/opt/autotools on all the machines I have to use,
> and stop worrying about all the details.
>
> When I have to use the tools, I add /opt/autotools/bin at the beginning
> of my PATH.  When I don't need them, I remove /opt/autotools/bin from my
> path.
>
> This has worked wonders so far.
>
> - Giorgos
>
>
>
> [1] The operative keyword here is "at work".  I don't use autoconf and
> friends for programs I write on my own.  I prefer bsd.*.mk for that.
>
___
freebsd-questions@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to "[EMAIL PROTECTED]"


RE: automake, autoconf compiling

2005-01-13 Thread Keith Bottner
All of the information both of your provided is helpful. I will have to
investigate further. Some of the information that Tom specified helped me to
track down the problem. Basically I have multiple versions of the tools
installed and there are two different directories with aclocal m4 files. If
I explicitly change the shell script to also include the other directory
then everything seems to continue on until compile time when there is a
header that cannot be found. It appears this header alloca.h is located in
/usr/src/gnu/usr.bin/sort/alloca.h. I was just wondering if Giorgos method
would also alleviate these problems or if this is just par for the course
when using projects that people have not moved into the ports collection?

Keith 

-Original Message-
From: [EMAIL PROTECTED]
[mailto:[EMAIL PROTECTED] On Behalf Of Giorgos Keramidas
Sent: Thursday, January 13, 2005 3:48 PM
To: Tom Huppi
Cc: Keith Bottner; freebsd-questions@freebsd.org; [EMAIL PROTECTED]
Org
Subject: Re: automake, autoconf compiling

PLEASE DON'T TOP-POST.  THANK YOU :-)

On 2005-01-13 16:24, Tom Huppi <[EMAIL PROTECTED]> wrote:
>On Thu, 13 Jan 2005, Keith Bottner wrote:
>> I am trying to get a development system setup and am having trouble 
>> identifying how FreeBSD handles automake, autoconf and the like.
>> [...] I did chase them down in the /usr/local/libexec/automake18 and 
>> similar directories but placing them in the path still generates 
>> errors (i.e. there continues to be things that are missing at various 
>> stages).
>>
>> I guess my general question is: What is the standard way for setting 
>> up FreeBSD to use these (GNU tools) with the least trouble across 
>> disparate projects?
>
> I've recently been struggling with similar issues, and would be 
> interested to know what others might have found effective.

I use autoconf/automake and libtool daily at work[1].

The programs I write have to run on at least 3 different operating systems
(FreeBSD, Linux and Solaris) without the need for constant manual tweaking
of the source.

The best way to do that is to use the same version of autotools on all those
platforms.  So, I install the latest possible versions of these tools with
--prefix=/opt/autotools on all the machines I have to use, and stop worrying
about all the details.

When I have to use the tools, I add /opt/autotools/bin at the beginning of
my PATH.  When I don't need them, I remove /opt/autotools/bin from my path.

This has worked wonders so far.

- Giorgos



[1] The operative keyword here is "at work".  I don't use autoconf and
friends for programs I write on my own.  I prefer bsd.*.mk for that.
___
[EMAIL PROTECTED] mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-newbies
To unsubscribe, send any mail to "[EMAIL PROTECTED]"

--
No virus found in this incoming message.
Checked by AVG Anti-Virus.
Version: 7.0.300 / Virus Database: 265.6.11 - Release Date: 1/12/2005
 

-- 
No virus found in this outgoing message.
Checked by AVG Anti-Virus.
Version: 7.0.300 / Virus Database: 265.6.11 - Release Date: 1/12/2005
 

___
freebsd-questions@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to "[EMAIL PROTECTED]"


Re: automake, autoconf compiling

2005-01-13 Thread Giorgos Keramidas
PLEASE DON'T TOP-POST.  THANK YOU :-)

On 2005-01-13 16:24, Tom Huppi <[EMAIL PROTECTED]> wrote:
>On Thu, 13 Jan 2005, Keith Bottner wrote:
>> I am trying to get a development system setup and am having trouble
>> identifying how FreeBSD handles automake, autoconf and the like.
>> [...] I did chase them down in the /usr/local/libexec/automake18 and
>> similar directories but placing them in the path still generates
>> errors (i.e. there continues to be things that are missing at various
>> stages).
>>
>> I guess my general question is: What is the standard way for setting
>> up FreeBSD to use these (GNU tools) with the least trouble across
>> disparate projects?
>
> I've recently been struggling with similar issues, and would be
> interested to know what others might have found effective.

I use autoconf/automake and libtool daily at work[1].

The programs I write have to run on at least 3 different operating
systems (FreeBSD, Linux and Solaris) without the need for constant
manual tweaking of the source.

The best way to do that is to use the same version of autotools on all
those platforms.  So, I install the latest possible versions of these
tools with --prefix=/opt/autotools on all the machines I have to use,
and stop worrying about all the details.

When I have to use the tools, I add /opt/autotools/bin at the beginning
of my PATH.  When I don't need them, I remove /opt/autotools/bin from my
path.

This has worked wonders so far.

- Giorgos



[1] The operative keyword here is "at work".  I don't use autoconf and
friends for programs I write on my own.  I prefer bsd.*.mk for that.
___
freebsd-questions@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to "[EMAIL PROTECTED]"


Re: automake, autoconf compiling

2005-01-13 Thread Tom Huppi

Hi Keith,

I've recently been struggling with similar issues, and would be
interested to know what others might have found effective.

I have a number of different versions of the auto-tools on my
machine, almost certainly as a result of installing various ports.
It is worth note that one can glean some info on how the FreeBSD
ports infrastructure handles this problem by looking at
/usr/ports/Mk/bsd.autotools.mk.  For my part, I found the details
to be too 'ugly' to attempt to emulate in my work, but they are
interesting all-the-same.  To date I have not resorted to
installing any custom, system-wide builds of any of these tools
for fear of harming my ability to use the ports infrastructure and
out of a desire to reduce future maintenance considerations.

For the most part, I have reasonable luck simply calling the
desired tool by it's installed name.  (i.e., 'autoconf259' instead
of 'autoconf'.)  Most of these tools know where to obtain their
helper files due to the PREFIX they were assigned when they
themselves were 'built'.

I have run into situations where aclocal got confused by multiple
macro definitions (for some libtool macros in my case.)  That was
a bit hard to debug, and it may be rare as my research didn't turn
up too many references.

I think it pertinent to expand this question to freebsd-questions
to include a wider audience.  Certainly these are FreeBSD specific
considerations, and probably not extremely arcane ones.

Thanks,

 - Tom


On Thu, 13 Jan 2005, Keith Bottner wrote:

> First let me say that I am definitely a newbie to FreeBSD but not to Linux
> or Windows.
>
> I am trying to get a development system setup and am having trouble
> identifying how FreeBSD handles automake, autoconf and the like.
> Specifically I am trying to get the Apache log4cxx source to compile and of
> course I am running into problems with automake, aclocal, autoheader,
> autoconf and libtoolize not being in the path. I did chase them down in the
> /usr/local/libexec/automake18 and similar directories but placing them in
> the path still generates errors (i.e. there continues to be things that are
> missing at various stages).
>
> I guess my general question is: What is the standard way for setting up
> FreeBSD to use these (GNU tools) with the least trouble across disparate
> projects?
>
> I have never had this problem on Linux as they have always been properly
> setup on install and I want to get FreeBSD going and do it the way that is
> accepted as the standard so that later generalizing my project with autoconf
> will be standardized as well.
>
> I appreciate any feedback and realize this is a rather broad question, but
> hey I said I was new to FreeBSD.
>
> Keith
>
> --
> No virus found in this outgoing message.
> Checked by AVG Anti-Virus.
> Version: 7.0.300 / Virus Database: 265.6.11 - Release Date: 1/12/2005
>
> ___
> [EMAIL PROTECTED] mailing list
> http://lists.freebsd.org/mailman/listinfo/freebsd-newbies
> To unsubscribe, send any mail to "[EMAIL PROTECTED]"
>
___
freebsd-questions@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to "[EMAIL PROTECTED]"