Home > Archive > alt.os.linux > October 2002 > makefile help





You are viewing an archived Text-only version of the thread. To view this thread in it's original format and/or if you want to reply to this thread please [click here]

Author makefile help
Tom

2002-10-15, 12:24 pm

I know its a bad usergroup for this but I couldn't find a makefile
formum.

Can someone please point me to my problem in my GNUmakefile. My problem
is
it never enters to do the blah blah... :-(

---------------------------------
#!/bin/bash

ifeq($(OSTYPE),linux-gnu)

blah blah.. not important

endif
---------------------------------

$ echo $OSTYPE
linux-gnu

$ gmake -v
version 3.79.1

Paul Lutus

2002-10-15, 12:24 pm

Tom wrote:

> I know its a bad usergroup for this but I couldn't find a makefile
> formum.
>
> Can someone please point me to my problem in my GNUmakefile.


Can you say what the problem is, specifically?

> My problem
> is
> it never enters to do the blah blah... :-(


No, that's a symptom of the problem, a consequence.

>
> ---------------------------------
> #!/bin/bash
>
> ifeq($(OSTYPE),linux-gnu)


That is not bash code. Why not test these things on the command line before
writing them into scripts?

# if [ "$OSTYPE" == "linux-gnu" ]; then echo "yes"; fi

yes

Your shell commands are all screwed up. Why not browse some of the many
shell scripts on your system to see how they are written, or even (gasp)
read something about how they are written?

Then take some time to interactively test your commands on the command line,
before putting them into a shell script. This will keep you from
inadvertently erasing your file system.

--
Paul Lutus
www.arachnoid.com
Tom

2002-10-15, 12:24 pm

Paul Lutus wrote:

> Tom wrote:
>
> > I know its a bad usergroup for this but I couldn't find a makefile
> > formum.
> >
> > Can someone please point me to my problem in my GNUmakefile.

>
> Can you say what the problem is, specifically?
>
> > My problem
> > is
> > it never enters to do the blah blah... :-(

>
> No, that's a symptom of the problem, a consequence.
>
> >
> > ---------------------------------
> > #!/bin/bash
> >
> > ifeq($(OSTYPE),linux-gnu)

>
> That is not bash code. Why not test these things on the command line before
> writing them into scripts?
>
> # if [ "$OSTYPE" == "linux-gnu" ]; then echo "yes"; fi
>
> yes
>
> Your shell commands are all screwed up. Why not browse some of the many
> shell scripts on your system to see how they are written, or even (gasp)
> read something about how they are written?
>
> Then take some time to interactively test your commands on the command line,
> before putting them into a shell script. This will keep you from
> inadvertently erasing your file system.
>
> --
> Paul Lutus
> www.arachnoid.com


Thanks but i'm trying to learn Gnumake not bash......

Peter T. Breuer

2002-10-15, 1:24 pm

Tom <no_spam@anti_spam.com> wrote:
> Can someone please point me to my problem in my GNUmakefile. My problem is
> it never enters to do the blah blah... :-(


> ---------------------------------
> #!/bin/bash


That's not a makefile. How are you "executing" this?


> ifeq($(OSTYPE),linux-gnu)


You are missing a space after the "ifeq".

> blah blah.. not important


> endif
> ---------------------------------


> $ echo $OSTYPE
> linux-gnu


Works fine here.

betty:/usr/oboe/ptb% make -f foobar
echo hi
hi

betty:/usr/oboe/ptb% cat foobar


ifeq ($(OSTYPE),linux-gnu)
all:
echo hi
endif


> $ gmake -v
> version 3.79.1


betty:/usr/oboe/ptb% make -v
GNU Make version 3.79.1, by Richard Stallman and Roland McGrath.


Never heard of "gmake", but it does sound gnuish!



Peter
Paul Lutus

2002-10-15, 1:24 pm

Tom wrote:

> Paul Lutus wrote:
>
>> Tom wrote:
>>
>> > I know its a bad usergroup for this but I couldn't find a makefile
>> > formum.
>> >
>> > Can someone please point me to my problem in my GNUmakefile.

>>
>> Can you say what the problem is, specifically?
>>
>> > My problem
>> > is
>> > it never enters to do the blah blah... :-(

>>
>> No, that's a symptom of the problem, a consequence.
>>
>> >
>> > ---------------------------------
>> > #!/bin/bash
>> >
>> > ifeq($(OSTYPE),linux-gnu)

>>
>> That is not bash code. Why not test these things on the command line
>> before writing them into scripts?
>>
>> # if [ "$OSTYPE" == "linux-gnu" ]; then echo "yes"; fi
>>
>> yes
>>
>> Your shell commands are all screwed up. Why not browse some of the many
>> shell scripts on your system to see how they are written, or even (gasp)
>> read something about how they are written?
>>
>> Then take some time to interactively test your commands on the command
>> line, before putting them into a shell script. This will keep you from
>> inadvertently erasing your file system.
>>
>> --
>> Paul Lutus
>> www.arachnoid.com

>
> Thanks but i'm trying to learn Gnumake not bash......


Then why did you post a bash shell file? You don't understand that if the
first line of a shell script is this --

#!/bin/bash

-- then the contents of the shell script will be interpreted in bash's
terms. It *doesn't* *matter* which program is going to use the result of
the shell script, the efficacy and meaning of the code depends on the shell
processor, which in this case is bash.

You asked why your bash shell script is not being interepreted correctly. I
told you. You replied, "... i'm trying to learn Gnumake not bash ...".
What?

--
Paul Lutus
www.arachnoid.com
Bruce Burhans

2002-10-15, 1:24 pm


"Tom" <no_spam@anti_spam.com> wrote in message
news:3DAC474D.D99E5802@anti_spam.com...
> I know its a bad usergroup for this but I couldn't find a makefile
> formum.


In Rute, the author walks you through the creation
of a Makefile..

http://rute.sourcforge.net

A Makefile is NOT a shellscript. Different language..

see info make.


Bruce<+>








Tom

2002-10-15, 1:25 pm

"Peter T. Breuer" wrote:

> Tom <no_spam@anti_spam.com> wrote:
> > Can someone please point me to my problem in my GNUmakefile. My problem is
> > it never enters to do the blah blah... :-(

>
> > ---------------------------------
> > #!/bin/bash

>
> That's not a makefile. How are you "executing" this?
>
> > ifeq($(OSTYPE),linux-gnu)

>
> You are missing a space after the "ifeq".
>
> > blah blah.. not important

>
> > endif
> > ---------------------------------

>
> > $ echo $OSTYPE
> > linux-gnu

>
> Works fine here.
>
> betty:/usr/oboe/ptb% make -f foobar
> echo hi
> hi
>
> betty:/usr/oboe/ptb% cat foobar
>
> ifeq ($(OSTYPE),linux-gnu)
> all:
> echo hi
> endif
>
> > $ gmake -v
> > version 3.79.1

>
> betty:/usr/oboe/ptb% make -v
> GNU Make version 3.79.1, by Richard Stallman and Roland McGrath.
>
> Never heard of "gmake", but it does sound gnuish!
>
> Peter


Works for me on my Solarius but not the Linux. for some reason the command

gmake -p | grep OSTYPE

Gives me the correct value on the Solarius but gives me nothing on the Linux.
:-(


Paul Lutus

2002-10-15, 2:24 pm

Tom wrote:

> "Peter T. Breuer" wrote:
>
>> Tom <no_spam@anti_spam.com> wrote:
>> > Can someone please point me to my problem in my GNUmakefile. My problem
>> > is it never enters to do the blah blah... :-(

>>
>> > ---------------------------------
>> > #!/bin/bash

>>
>> That's not a makefile. How are you "executing" this?
>>
>> > ifeq($(OSTYPE),linux-gnu)

>>
>> You are missing a space after the "ifeq".
>>
>> > blah blah.. not important

>>
>> > endif
>> > ---------------------------------

>>
>> > $ echo $OSTYPE
>> > linux-gnu

>>
>> Works fine here.
>>
>> betty:/usr/oboe/ptb% make -f foobar
>> echo hi
>> hi
>>
>> betty:/usr/oboe/ptb% cat foobar
>>
>> ifeq ($(OSTYPE),linux-gnu)
>> all:
>> echo hi
>> endif
>>
>> > $ gmake -v
>> > version 3.79.1

>>
>> betty:/usr/oboe/ptb% make -v
>> GNU Make version 3.79.1, by Richard Stallman and Roland McGrath.
>>
>> Never heard of "gmake", but it does sound gnuish!
>>
>> Peter

>
> Works for me on my Solarius but not the Linux. for some reason the command
>
> gmake -p | grep OSTYPE
>
> Gives me the correct value on the Solarius but gives me nothing on the
> Linux.
> :-(


What did you expect to see as output?

--
Paul Lutus
www.arachnoid.com
Peter T. Breuer

2002-10-15, 5:24 pm

Tom <no_spam@anti_spam.com> wrote:

No, he bottom posted. Stop it. Learn to edit!

> "Peter T. Breuer" wrote:
>> Tom <no_spam@anti_spam.com> wrote:
>> > Can someone please point me to my problem in my GNUmakefile. My problem is
>> > it never enters to do the blah blah... :-(
>> > ---------------------------------
>> > #!/bin/bash

>>
>> That's not a makefile. How are you "executing" this?


Comment! You blithering idiot! Are you blind? Say something!

[colo
r=darkred]
>> > ifeq($(OSTYPE),linux-gnu)

>>
>> You are missing a space after the "ifeq".
[/color]

And comment! You ARE blind, no?
[colo
r=darkred]
>> > blah blah.. not important

>>
>> > endif
>> > ---------------------------------

>>
>> > $ echo $OSTYPE
>> > linux-gnu

>>
>> Works fine here.
[/color]

As I said. So go away and stop trolling.


>> betty:/usr/oboe/ptb% make -f foobar
>> echo hi
>> hi
>>
>> betty:/usr/oboe/ptb% cat foobar
>>
>> ifeq ($(OSTYPE),linux-gnu)
>> all:
>> echo hi
>> endif


See? Do you see the difference? Have you learned to SEE yet? And edit?

[colo
r=darkred]
>> > $ gmake -v
>> > version 3.79.1

>>
>> betty:/usr/oboe/ptb% make -v
>> GNU Make version 3.79.1, by Richard Stallman and Roland McGrath.
>>
>> Never heard of "gmake", but it does sound gnuish!
[/color]


> Works for me on my Solarius but not the Linux. for some reason the command


> gmake -p | grep OSTYPE


> Gives me the correct value on the Solarius but gives me nothing on the Linux.
> :-(


a) gmake does not exist. It is "make".

b) until you start typing "make", nobody can guarantee anything

c) it gives me a value "on linux"

betty:/usr/oboe/ptb% make -p | grep OSTYPE
make: *** No targets specified and no makefile found. Stop.
OSTYPE = linux

and anyway, why do you care? Just answer the questions, stop burbling
on as though other peoples replies don't exist, and generally act
logically.

Peter
Sponsored Links





Free Braindumps | MCSE braindumps software forum

Copyright 2003 - 2008 examnotes.net