Skip site navigation (1) Skip section navigation (2)

Re: win32 version info

From: Andrew Dunstan <andrew(at)dunslane(dot)net>
To: Magnus Hagander <mha(at)sollentuna(dot)net>
Cc: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>,PostgreSQL-patches <pgsql-patches(at)postgresql(dot)org>
Subject: Re: win32 version info
Date: 2004-07-26 19:40:40
Message-ID: 41055E38.6050000@dunslane.net (view raw or flat)
Thread:
Lists: pgsql-patches

Magnus Hagander wrote:

>  
>
>>Can't you localize this into a single build rule somewhere?  And surely
>>we do not need to maintain a boilerplate .rc file for every executable.
>>    
>>
>
>There is a field in the RC file that is "file description". It's pretty
>much different for every file. (There is also a "product description" in
>there which is the same). 
>
>As for putting it in a single build rule - I don't know if that can be
>done. I thought it over and didn't come up with a way, but there may be
>other who are better at writing Makefiles... I guess a script could be
>written that generates the file, but the per-binary information has to
>be somewhere. Not sure how that method would be cleaner.
>  
>

We would not need to generate it at all. Maybe something like this would 
work:

In the makefile, symlink each .rc file to the boilerplate version 
somewhere, and put a definition like this:
 
FILEDESC="\"whatever you like\""

and also conditionally include the *rc.o file in its objects list.

The rc file would, of course, have this line:

   VALUE "FileDescription",  FILEDESC

Makefile.global or similar could define the build rule once, like

%.o: %.rc
    windres -DFILEDESC=$(FILEDESC) $< -o $@  
--include-dir=$(top_builddir)/src/include

I hope you get the idea.

cheers

andrew




In response to

Responses

pgsql-patches by date

Next:From: Peter EisentrautDate: 2004-07-26 19:42:13
Subject: Re: win32 version info
Previous:From: Sean ChittendenDate: 2004-07-26 19:25:18
Subject: pg_ctl -o option dumps core when processing postmaster arguments...

Privacy Policy | About PostgreSQL
Copyright © 1996-2014 The PostgreSQL Global Development Group