[MPlayer-dev-eng] Re: "dev-CVS-040828-23:58-3.2" data on builds incorrect

J. Grant jg at jguk.org
Sun Oct 10 22:37:43 CEST 2004


Hi Torinthiel,

Thanks for your reply.  I respond to your points below.

>> $ pwd
>> /home/now3d/mplayer/main
>> $ ./mplayer
>> MPlayer dev-CVS-040828-23:58-3.2 (C) 2000-2004 MPlayer Team
>> 
>> The fault is because version.sh does not called everytime ./configure is
>> run. So when I do:
>> 
>> cvs update -d
>> ./configure
>> make
>> 
>> it will still be using the old version.h !
> 
> You have seriously quirked your build system if that is true.
> According to Makefile, version.h is required by 'all' (and if you type
> 'make' that's what you're building). Also every object and library
> depends on version.h and building version.h runs 'make distclean'
> (see Makefile, line 362).

I deleted version.h, and it was not "rebuilt" by running "make".

Some thinks I have noticed:
1. "make distclean" does not remove version.h.

2. "make distclean" does not create version.h if there is not one already.


>> Unless I do "make distclean", which clears all the crud and makes me
>> completely rebuild.
> 
> You don't need to. Generating version.h does it.
> 
>> Is there a reason configure does not update the version.h timestamp?
>> Would a patch be accepted to update version.h when configure is run?
> 
> Yes, Makefile does it. IMHO no, as running it in Makefile is more
> general. Suppose you update something and don't run configure. If
> version.h is updated by configure it won't get run. But if run by
> Makefile then the version gets updated correctly.

Ok, that sounds good.  If it works.  The makefile only updates version.h if
config.h, config.mak, or Makefile have changed. I do not know if "cvs
update -d" will update those files.

> Now go and check what have you changed that it doesn't.
> If you update a file, no matter whether in subdirectory or in main, make
> sees it needs to update corresponding .a or .o file. Then it sees that
> this file depends on version.h and generates version.h, which in turn
> runs make distclean.

Do all corresponding object files depend on config.h, config.mak, or
Makefile then?


Here is an example illustrainting the problem:
=================================
make distclean
rm version.h
cvs update -d
make

version.h contains:
"dev-CVS-041010-21:11-3.2"

now, i update again (21:36)

cvs update -d
make

version.h contains:
"dev-CVS-041010-21:11-3.2"

So obviously version.h is not updated.
==============================

Can you repeat the steps and confirm if you too see this problem?

Kind regards

JG

-- 
Homepage: http://jguk.org/
Blog: http://jguk.org/#blog
Radio: http://jguk.org/#radio





More information about the MPlayer-dev-eng mailing list