[openbeos-build-team] Re: Jam 2.4 hack

  • From: "David Reid" <dreid@xxxxxxxxxxxx>
  • To: <openbeos-build-team@xxxxxxxxxxxxx>
  • Date: Tue, 2 Jul 2002 18:49:36 +0100

The shell script can just use sed or some such and simply substitute the
paths...

Then it can run Jam :)

We can have a line telling people they only need to run Jam from then on.

Don't get too involved - it's should be a wonderfully simple little
bootstrap script that gets run once. Avoid autoconf like the plague.

david

----- Original Message -----
From: "Ingo Weinhold" <bonefish@xxxxxxxxxxxxxxx>
To: <openbeos-build-team@xxxxxxxxxxxxx>
Sent: Tuesday, July 02, 2002 6:38 PM
Subject: [openbeos-build-team] Re: Jam 2.4 hack


>
> > Guess we could have the rule to generate the BuildConfig file somehow
> > as
> > well by making it a dependancy (somehow??).
>
> Mmh, at least I wouldn't know how to do it. Unlike make Jam doesn't
> feature rebuilding of Makefiles. The execution order of the passes is
> strictly linear, and since a file to be included would be needed in the
> parsing pass, but can't be built before the updating pass, I don't have
> much hope for this idea.
>
> > Well, I'm eagerly awaiting the code guys!
>
> Err, I'm afraid you mean Ryan or me. ;-)
>
> I'm not common to autoconf, which Ryan proposed to use. So please
> forgive my naive ignorance, as I would currently doing something simple
> like:
>
> in Jamrules (at the very beginning):
>
> include BuildConfig ;
>
> 8< 8< 8< 8< 8< 8< 8< 8< 8< 8< 8< 8< 8< 8< 8< 8<
>
> configure:
>
> #!/bin/sh
> #
> # configure
> #
> # No parameters for now.
>
> platform=`uname`
>
> # BeOS
> if [ "${platform}" == "BeOS" ] ; then
> # GGC_PATH
> if [ "x${GCC_PATH}" == "x" ] ; then
> gcclib=`gcc -print-libgcc-file-name`
> GCC_PATH=`dirname ${gcclib}`
> fi
>
> # Linux
> else if [ "${platform}" == "Linux" ] ; then
> # GGC_PATH
> if [ "x${GCC_PATH}" == "x" ] ; then
> gcclib=`gcc -print-libgcc-file-name`
> GCC_PATH=`dirname ${gcclib}`
> fi
>
> # Unknown platform
> else
> echo Unsupported platform: ${platform}
> exit 1
> fi; fi
>
> # Generate BuildConfig
> cat << EOF > BuildConfig
> # BuildConfig
> # Note: This file has been automatically generated by configure.
>
> GCC_PATH = ${GCC_PATH}
> EOF
>
> 8< 8< 8< 8< 8< 8< 8< 8< 8< 8< 8< 8< 8< 8< 8< 8<
>
> With Jam 2.4 we can use the GLOB rule to determine whether a
> BuildConfig file does exist.
>
> CU, Ingo
>
>
>
>


Other related posts: