public inbox for cygwin@cygwin.com
 help / color / mirror / Atom feed
* Re: B20.1: make dependencies broken
@ 2000-01-26  6:59 Earnie Boyd
  2000-01-26  9:29 ` Kevin Wright
  0 siblings, 1 reply; 9+ messages in thread
From: Earnie Boyd @ 2000-01-26  6:59 UTC (permalink / raw)
  To: Kevin Wright, Cygwin

Sounds like a \r\n problem to me.  Convert the Makefile line endings to \n
endings only.

Earnie.

--- Kevin Wright <kwright@uk.mdis.com> wrote:
> I've found the following problem with make on B20.1.
> Try the following makefile:
> ------------------------------
> NTTOOLSDIR = /tmp
> 
> NTTOOLS = $(NTTOOLSDIR)/f1.bat \
>           $(NTTOOLSDIR)/f2.bat
> 
> All: $(NTTOOLS)
> 
> $(NTTOOLS): $(NTTOOLSDIR)/%: %
> 
> $(NTTOOLS):
>         # making $@ due to $?
>         cp $? $@
> --------------------------------
> 
> now touch f1.bat f2.bat
> 
> 
> make always reports:
> make: Nothing to be done for `All'.
> 
> Removing the .bat extension on f1/f2 fixes the problem.
> Removing the second file from NTTOOLS fixes the problem.
> 
> This all worked fine on B17.
> 
> I'm using NT4 SP5
> 
> I've tried searching the archives for this problem, but can't find anything
> similar.
> 
> 
> --
> Want to unsubscribe from this list?
> Send a message to cygwin-unsubscribe@sourceware.cygnus.com
> 
> 
__________________________________________________
Do You Yahoo!?
Talk to your friends online with Yahoo! Messenger.
http://im.yahoo.com

--
Want to unsubscribe from this list?
Send a message to cygwin-unsubscribe@sourceware.cygnus.com

^ permalink raw reply	[flat|nested] 9+ messages in thread

* RE: B20.1: make dependencies broken
  2000-01-26  6:59 B20.1: make dependencies broken Earnie Boyd
@ 2000-01-26  9:29 ` Kevin Wright
  0 siblings, 0 replies; 9+ messages in thread
From: Kevin Wright @ 2000-01-26  9:29 UTC (permalink / raw)
  To: Cygwin

Changing my make file to \n line endings didn't make any difference.
Any way what effect could \n endings have on whether or not there's a .bat
extension ?
The line brake after the \ doesn't make any difference.  The two file can be
on the same line.

> -----Original Message-----
> From: cygwin-owner@sourceware.cygnus.com
> [ mailto:cygwin-owner@sourceware.cygnus.com]On Behalf Of Earnie Boyd
> Sent: 26 January 2000 14:59
> To: Kevin Wright; Cygwin
> Subject: Re: B20.1: make dependencies broken
>
>
> Sounds like a \r\n problem to me.  Convert the Makefile line endings to \n
> endings only.
>
> Earnie.
>
> --- Kevin Wright <kwright@uk.mdis.com> wrote:
> > I've found the following problem with make on B20.1.
> > Try the following makefile:
> > ------------------------------
> > NTTOOLSDIR = /tmp
> >
> > NTTOOLS = $(NTTOOLSDIR)/f1.bat \
> >           $(NTTOOLSDIR)/f2.bat
> >
> > All: $(NTTOOLS)
> >
> > $(NTTOOLS): $(NTTOOLSDIR)/%: %
> >
> > $(NTTOOLS):
> >         # making $@ due to $?
> >         cp $? $@
> > --------------------------------
> >
> > now touch f1.bat f2.bat
> >
> >
> > make always reports:
> > make: Nothing to be done for `All'.
> >
> > Removing the .bat extension on f1/f2 fixes the problem.
> > Removing the second file from NTTOOLS fixes the problem.
> >
> > This all worked fine on B17.
> >
> > I'm using NT4 SP5
> >
> > I've tried searching the archives for this problem, but can't
> find anything
> > similar.
> >
> >
> > --
> > Want to unsubscribe from this list?
> > Send a message to cygwin-unsubscribe@sourceware.cygnus.com
> >
> >
> __________________________________________________
> Do You Yahoo!?
> Talk to your friends online with Yahoo! Messenger.
> http://im.yahoo.com
>
> --
> Want to unsubscribe from this list?
> Send a message to cygwin-unsubscribe@sourceware.cygnus.com


--
Want to unsubscribe from this list?
Send a message to cygwin-unsubscribe@sourceware.cygnus.com

^ permalink raw reply	[flat|nested] 9+ messages in thread

* RE: B20.1: make dependencies broken
  2000-01-28  6:31 Earnie Boyd
@ 2000-01-28  8:58 ` Kevin Wright
  0 siblings, 0 replies; 9+ messages in thread
From: Kevin Wright @ 2000-01-28  8:58 UTC (permalink / raw)
  To: Cygwin

Hmmm.  I tried make 3.77 from make-3.77-mingw32.zip.

It does fix my original problem.  However it seems to have real problems
with libraries and their dependencies.

I've been trying to generate a sample makefile but I can't get make to do
_anything_ interesting in a test case.

But try this

================================================================
MARK = Mark

# Turn off default library rule
(%): %
        > $(MARK)

LIB = mylib.a

OBS = $(LIB)(f1.o) $(LIB)(f2.o)

All: $(OBS)
        # making $@ due to $?
=================================================================

I know this doesn't do anything useful but it just demonstrates a problem.
The proper makefile generates a load of objects and then puts them into the
library all in one go.

touch f1.o f2.o
make

I expect to get:
-------------------
> Mark
> Mark
# making All due to f1.o f2.o
-------------------

On cygwin all I get is
make: *** No rule to make target `mylib.a(f1.o)', needed by `All'.  Stop.

This works on the make versions I listed previously but does not work on
cygwin using make 3.76 or 3.77
I'm really puzzled how the cygwin developers manage to use this make.

The problem I was trying to demonstrate is that the '# making' line is
printed as
# making All due to mylib.a(f1.o) mylib.a(f2.o)

which is what I get when running this on my real makefile.  This is
definitely wrong as the make documentation clearly states that $? expands
the library members and not the full path.

I think I will just give up trying to go down this route as make 3.75 seems
to work perfectly well.
Thanks for your help.


Kevin


--
Want to unsubscribe from this list?
Send a message to cygwin-unsubscribe@sourceware.cygnus.com

^ permalink raw reply	[flat|nested] 9+ messages in thread

* RE: B20.1: make dependencies broken
@ 2000-01-28  6:31 Earnie Boyd
  2000-01-28  8:58 ` Kevin Wright
  0 siblings, 1 reply; 9+ messages in thread
From: Earnie Boyd @ 2000-01-28  6:31 UTC (permalink / raw)
  To: Kevin Wright, Cygwin

Oh.  I must of had my reverse thinking cap on.  Your makefile works for me.
Make version is 3.77.  I tried both Cygwin CD V1.0 and Mingw32 versions.  Both
copied from the /tmp/makeit directory to the /tmp directory after touching
either f1.bat or f2.bat or both.

Earnie.


--- Kevin Wright <kwright@uk.mdis.com> wrote:
> I agree your make file works.  However your makefile lives in the target
> directory and copies files from another directory to the target directory.
> 
> My makefile lives in the source directory and copies files to another
> directory.  This is (I would have thought) the more normal use of make i.e.
> creating a file from a source file and then copying it to an installation
> directory.
> 
> My make file works on 5 different flavours of Unix using gnu make version
> 3.75 and 3.76.1.   It worked on B17 using gnu make 3.75.  It doesn't work on
> B20.1 using gnu make 3.76.1 as supplied with B20.1 binaries.
> 
> Kevin.
> >
> > Hmm...  Is you Makefile example correct?  I redid it like this:
> >
> > ------------------------------
> > NTTOOLSDIR = /tmp
> >
> > NTTOOLS = f1.bat \
> >           f2.bat
> >
> > All: $(NTTOOLS)
> >
> > $(NTTOOLS): % : $(NTTOOLSDIR)/%
> >         # making $@ due to $?
> >         cp $? $@
> > --------------------------------
> >
> > I then did
> >
> > mkdir /tmp/maketest
> > cd /tmp/maketest
> > create above Makefile
> > touch /tmp/f1.bat /tmp/f2.bat
> > make
> >        This gave me the expected results.
> > touch /tmp/f2.bat
> > make
> >        This gave me the expected results.
> > touch /tmp/f1.bat
> > make
> >        This gave me the expected results.
> > make
> >        Everything current, great, that was the expected result.
> > cd ..
> > make -f maketest/Makefile
> >        Everything current, great, that was the expected result.
> >
> > Earnie.
> >
> > --- Kevin Wright <kwright@uk.mdis.com> wrote:
> > > I tried adding
> > > .SUFFIXES: .bat
> > > and it didn't make any difference.
> > >
> > > Kevin.
> > >
> > > >
> > > > Ok.  You problen with .bat is that it is an suffix that isn't a
> > > > default one.
> > > > What happens if you add .SUFFIXES .bat?
> > > >
> > > > Earnie.
> > > >
> > > > I've found the following problem with make on B20.1.
> > > > Try the following makefile:
> > > > ------------------------------
> > > > NTTOOLSDIR = /tmp
> > > >
> > > > NTTOOLS = $(NTTOOLSDIR)/f1.bat \
> > > >           $(NTTOOLSDIR)/f2.bat
> > > >
> > > > All: $(NTTOOLS)
> > > >
> > > > $(NTTOOLS): $(NTTOOLSDIR)/%: %
> > > >
> > > > $(NTTOOLS):
> > > >         # making $@ due to $?
> > > >         cp $? $@
> > > > --------------------------------
> > > >
> > > > now touch f1.bat f2.bat
> > > >
> > > >
> > > > make always reports:
> > > > make: Nothing to be done for `All'.
> > > >
> > > > Removing the .bat extension on f1/f2 fixes the problem.
> > > > Removing the second file from NTTOOLS fixes the problem.
> > > >
> > > > This all worked fine on B17.
> > > >
> > > > I'm using NT4 SP5
> 
> 
> --
> Want to unsubscribe from this list?
> Send a message to cygwin-unsubscribe@sourceware.cygnus.com
> 
> 

=====
Earnie Boyd < mailto:earnie_boyd@yahoo.com >
Cygwin Newbies, please visit
< http://www.freeyellow.com/members5/gw32/index.html >
__________________________________________________
Do You Yahoo!?
Talk to your friends online with Yahoo! Messenger.
http://im.yahoo.com

--
Want to unsubscribe from this list?
Send a message to cygwin-unsubscribe@sourceware.cygnus.com

^ permalink raw reply	[flat|nested] 9+ messages in thread

* RE: B20.1: make dependencies broken
  2000-01-27 11:38 Earnie Boyd
@ 2000-01-28  4:15 ` Kevin Wright
  0 siblings, 0 replies; 9+ messages in thread
From: Kevin Wright @ 2000-01-28  4:15 UTC (permalink / raw)
  To: Cygwin

I agree your make file works.  However your makefile lives in the target
directory and copies files from another directory to the target directory.

My makefile lives in the source directory and copies files to another
directory.  This is (I would have thought) the more normal use of make i.e.
creating a file from a source file and then copying it to an installation
directory.

My make file works on 5 different flavours of Unix using gnu make version
3.75 and 3.76.1.   It worked on B17 using gnu make 3.75.  It doesn't work on
B20.1 using gnu make 3.76.1 as supplied with B20.1 binaries.

Kevin.
>
> Hmm...  Is you Makefile example correct?  I redid it like this:
>
> ------------------------------
> NTTOOLSDIR = /tmp
>
> NTTOOLS = f1.bat \
>           f2.bat
>
> All: $(NTTOOLS)
>
> $(NTTOOLS): % : $(NTTOOLSDIR)/%
>         # making $@ due to $?
>         cp $? $@
> --------------------------------
>
> I then did
>
> mkdir /tmp/maketest
> cd /tmp/maketest
> create above Makefile
> touch /tmp/f1.bat /tmp/f2.bat
> make
>        This gave me the expected results.
> touch /tmp/f2.bat
> make
>        This gave me the expected results.
> touch /tmp/f1.bat
> make
>        This gave me the expected results.
> make
>        Everything current, great, that was the expected result.
> cd ..
> make -f maketest/Makefile
>        Everything current, great, that was the expected result.
>
> Earnie.
>
> --- Kevin Wright <kwright@uk.mdis.com> wrote:
> > I tried adding
> > .SUFFIXES: .bat
> > and it didn't make any difference.
> >
> > Kevin.
> >
> > >
> > > Ok.  You problen with .bat is that it is an suffix that isn't a
> > > default one.
> > > What happens if you add .SUFFIXES .bat?
> > >
> > > Earnie.
> > >
> > > I've found the following problem with make on B20.1.
> > > Try the following makefile:
> > > ------------------------------
> > > NTTOOLSDIR = /tmp
> > >
> > > NTTOOLS = $(NTTOOLSDIR)/f1.bat \
> > >           $(NTTOOLSDIR)/f2.bat
> > >
> > > All: $(NTTOOLS)
> > >
> > > $(NTTOOLS): $(NTTOOLSDIR)/%: %
> > >
> > > $(NTTOOLS):
> > >         # making $@ due to $?
> > >         cp $? $@
> > > --------------------------------
> > >
> > > now touch f1.bat f2.bat
> > >
> > >
> > > make always reports:
> > > make: Nothing to be done for `All'.
> > >
> > > Removing the .bat extension on f1/f2 fixes the problem.
> > > Removing the second file from NTTOOLS fixes the problem.
> > >
> > > This all worked fine on B17.
> > >
> > > I'm using NT4 SP5


--
Want to unsubscribe from this list?
Send a message to cygwin-unsubscribe@sourceware.cygnus.com

^ permalink raw reply	[flat|nested] 9+ messages in thread

* RE: B20.1: make dependencies broken
@ 2000-01-27 11:38 Earnie Boyd
  2000-01-28  4:15 ` Kevin Wright
  0 siblings, 1 reply; 9+ messages in thread
From: Earnie Boyd @ 2000-01-27 11:38 UTC (permalink / raw)
  To: Kevin Wright, Cygwin

Hmm...  Is you Makefile example correct?  I redid it like this:

------------------------------
NTTOOLSDIR = /tmp

NTTOOLS = f1.bat \
          f2.bat

All: $(NTTOOLS)

$(NTTOOLS): % : $(NTTOOLSDIR)/%
        # making $@ due to $?
        cp $? $@
--------------------------------

I then did 

mkdir /tmp/maketest
cd /tmp/maketest
create above Makefile
touch /tmp/f1.bat /tmp/f2.bat
make
       This gave me the expected results.
touch /tmp/f2.bat
make
       This gave me the expected results.
touch /tmp/f1.bat
make
       This gave me the expected results.
make
       Everything current, great, that was the expected result.
cd ..
make -f maketest/Makefile
       Everything current, great, that was the expected result.

Earnie.

--- Kevin Wright <kwright@uk.mdis.com> wrote:
> I tried adding
> .SUFFIXES: .bat
> and it didn't make any difference.
> 
> Kevin.
> 
> > 
> > Ok.  You problen with .bat is that it is an suffix that isn't a 
> > default one. 
> > What happens if you add .SUFFIXES .bat?
> > 
> > Earnie.
> > 
> > > > > I've found the following problem with make on B20.1.
> > > > > Try the following makefile:
> > > > > ------------------------------
> > > > > NTTOOLSDIR = /tmp
> > > > >
> > > > > NTTOOLS = $(NTTOOLSDIR)/f1.bat \
> > > > >           $(NTTOOLSDIR)/f2.bat
> > > > >
> > > > > All: $(NTTOOLS)
> > > > >
> > > > > $(NTTOOLS): $(NTTOOLSDIR)/%: %
> > > > >
> > > > > $(NTTOOLS):
> > > > >         # making $@ due to $?
> > > > >         cp $? $@
> > > > > --------------------------------
> > > > >
> > > > > now touch f1.bat f2.bat
> > > > >
> > > > >
> > > > > make always reports:
> > > > > make: Nothing to be done for `All'.
> > > > >
> > > > > Removing the .bat extension on f1/f2 fixes the problem.
> > > > > Removing the second file from NTTOOLS fixes the problem.
> > > > >
> > > > > This all worked fine on B17.
> > > > >
> > > > > I'm using NT4 SP5
> > > > >
> 
> 
> --
> Want to unsubscribe from this list?
> Send a message to cygwin-unsubscribe@sourceware.cygnus.com
> 
> 
__________________________________________________
Do You Yahoo!?
Talk to your friends online with Yahoo! Messenger.
http://im.yahoo.com

--
Want to unsubscribe from this list?
Send a message to cygwin-unsubscribe@sourceware.cygnus.com

^ permalink raw reply	[flat|nested] 9+ messages in thread

* RE: B20.1: make dependencies broken
  2000-01-26 12:00 Earnie Boyd
@ 2000-01-27  7:09 ` Kevin Wright
  0 siblings, 0 replies; 9+ messages in thread
From: Kevin Wright @ 2000-01-27  7:09 UTC (permalink / raw)
  To: Cygwin

I tried adding
.SUFFIXES: .bat
and it didn't make any difference.

Kevin.

> 
> Ok.  You problen with .bat is that it is an suffix that isn't a 
> default one. 
> What happens if you add .SUFFIXES .bat?
> 
> Earnie.
> 
> > > > I've found the following problem with make on B20.1.
> > > > Try the following makefile:
> > > > ------------------------------
> > > > NTTOOLSDIR = /tmp
> > > >
> > > > NTTOOLS = $(NTTOOLSDIR)/f1.bat \
> > > >           $(NTTOOLSDIR)/f2.bat
> > > >
> > > > All: $(NTTOOLS)
> > > >
> > > > $(NTTOOLS): $(NTTOOLSDIR)/%: %
> > > >
> > > > $(NTTOOLS):
> > > >         # making $@ due to $?
> > > >         cp $? $@
> > > > --------------------------------
> > > >
> > > > now touch f1.bat f2.bat
> > > >
> > > >
> > > > make always reports:
> > > > make: Nothing to be done for `All'.
> > > >
> > > > Removing the .bat extension on f1/f2 fixes the problem.
> > > > Removing the second file from NTTOOLS fixes the problem.
> > > >
> > > > This all worked fine on B17.
> > > >
> > > > I'm using NT4 SP5
> > > >


--
Want to unsubscribe from this list?
Send a message to cygwin-unsubscribe@sourceware.cygnus.com

^ permalink raw reply	[flat|nested] 9+ messages in thread

* RE: B20.1: make dependencies broken
@ 2000-01-26 12:00 Earnie Boyd
  2000-01-27  7:09 ` Kevin Wright
  0 siblings, 1 reply; 9+ messages in thread
From: Earnie Boyd @ 2000-01-26 12:00 UTC (permalink / raw)
  To: Kevin Wright, Cygwin

To answer what the difference is:

NTTOOLS = $(NTTOOLSDIR)/f1.bat \\r\n
          $(NTTOOLSDIR)/f2.bat \r\n

Ok.  You problen with .bat is that it is an suffix that isn't a default one. 
What happens if you add .SUFFIXES .bat?

Earnie.

--- Kevin Wright <kwright@uk.mdis.com> wrote:
> Changing my make file to \n line endings didn't make any difference.
> Any way what effect could \n endings have on whether or not there's a .bat
> extension ?
> The line brake after the \ doesn't make any difference.  The two file can be
> on the same line.
> 
> > -----Original Message-----
> > From: cygwin-owner@sourceware.cygnus.com
> > [ mailto:cygwin-owner@sourceware.cygnus.com]On Behalf Of Earnie Boyd
> > Sent: 26 January 2000 14:59
> > To: Kevin Wright; Cygwin
> > Subject: Re: B20.1: make dependencies broken
> >
> >
> > Sounds like a \r\n problem to me.  Convert the Makefile line endings to \n
> > endings only.
> >
> > Earnie.
> >
> > --- Kevin Wright <kwright@uk.mdis.com> wrote:
> > > I've found the following problem with make on B20.1.
> > > Try the following makefile:
> > > ------------------------------
> > > NTTOOLSDIR = /tmp
> > >
> > > NTTOOLS = $(NTTOOLSDIR)/f1.bat \
> > >           $(NTTOOLSDIR)/f2.bat
> > >
> > > All: $(NTTOOLS)
> > >
> > > $(NTTOOLS): $(NTTOOLSDIR)/%: %
> > >
> > > $(NTTOOLS):
> > >         # making $@ due to $?
> > >         cp $? $@
> > > --------------------------------
> > >
> > > now touch f1.bat f2.bat
> > >
> > >
> > > make always reports:
> > > make: Nothing to be done for `All'.
> > >
> > > Removing the .bat extension on f1/f2 fixes the problem.
> > > Removing the second file from NTTOOLS fixes the problem.
> > >
> > > This all worked fine on B17.
> > >
> > > I'm using NT4 SP5
> > >
> > > I've tried searching the archives for this problem, but can't
> > find anything
> > > similar.
> > >
> > >
> > > --
> > > Want to unsubscribe from this list?
> > > Send a message to cygwin-unsubscribe@sourceware.cygnus.com
> > >
> > >
> > __________________________________________________
> > Do You Yahoo!?
> > Talk to your friends online with Yahoo! Messenger.
> > http://im.yahoo.com
> >
> > --
> > Want to unsubscribe from this list?
> > Send a message to cygwin-unsubscribe@sourceware.cygnus.com
> 
> 
> --
> Want to unsubscribe from this list?
> Send a message to cygwin-unsubscribe@sourceware.cygnus.com
> 
> 
__________________________________________________
Do You Yahoo!?
Talk to your friends online with Yahoo! Messenger.
http://im.yahoo.com

--
Want to unsubscribe from this list?
Send a message to cygwin-unsubscribe@sourceware.cygnus.com

^ permalink raw reply	[flat|nested] 9+ messages in thread

* B20.1: make dependencies broken
@ 2000-01-26  6:34 Kevin Wright
  0 siblings, 0 replies; 9+ messages in thread
From: Kevin Wright @ 2000-01-26  6:34 UTC (permalink / raw)
  To: Cygwin

I've found the following problem with make on B20.1.
Try the following makefile:
------------------------------
NTTOOLSDIR = /tmp

NTTOOLS = $(NTTOOLSDIR)/f1.bat \
          $(NTTOOLSDIR)/f2.bat

All: $(NTTOOLS)

$(NTTOOLS): $(NTTOOLSDIR)/%: %

$(NTTOOLS):
        # making $@ due to $?
        cp $? $@
--------------------------------

now touch f1.bat f2.bat


make always reports:
make: Nothing to be done for `All'.

Removing the .bat extension on f1/f2 fixes the problem.
Removing the second file from NTTOOLS fixes the problem.

This all worked fine on B17.

I'm using NT4 SP5

I've tried searching the archives for this problem, but can't find anything
similar.


--
Want to unsubscribe from this list?
Send a message to cygwin-unsubscribe@sourceware.cygnus.com

^ permalink raw reply	[flat|nested] 9+ messages in thread

end of thread, other threads:[~2000-01-28  8:58 UTC | newest]

Thread overview: 9+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2000-01-26  6:59 B20.1: make dependencies broken Earnie Boyd
2000-01-26  9:29 ` Kevin Wright
  -- strict thread matches above, loose matches on Subject: below --
2000-01-28  6:31 Earnie Boyd
2000-01-28  8:58 ` Kevin Wright
2000-01-27 11:38 Earnie Boyd
2000-01-28  4:15 ` Kevin Wright
2000-01-26 12:00 Earnie Boyd
2000-01-27  7:09 ` Kevin Wright
2000-01-26  6:34 Kevin Wright

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).