On Tue, Mar 19, 2013 at 18:36:49 +0200, Elan Ruusamäe wrote:

>> +%{__make} \
>> +    CFLAGS="%{rpmcflags} -fblocks -Wall -I$(pwd)/BlocksRunTime 
>> -I$(pwd)/include -DDEBUG_BUILD=0 -D_FILE_OFFSET_BITS=64 -DLINUX=1 -DBSD=1 
>> -DVERSION=\\\"%{version}\\\"" \
>> +    LDFLAGS="%{rpmldflags} -L$(pwd)/BlocksRunTime"
> wouldn't in such cases when you overwrite make variable, do a patch and 
> write it into new variable (say OPTFLAGS),

I prefer sed -i on appropriate file, which:
- is easier to maintain than patch,
- introduces only flags we explicitly set,
- doesn't always need update (when something next to the place changes),
  but would fail when the flags we put in regexp are altered.

> make OPTPFAGS="%{rpmcflags}"
> 
> also if you ass CFLAGS as env, not make parameter, makefiles can 
> CFLAGS+=something, and not needing to copy that contents to .spec
> 
> CFLAGS="%{rpmcflags}" make

Sometimes you need to export env, depends on build system chaining.

-- 
Tomasz Pala <go...@pld-linux.org>
_______________________________________________
pld-devel-en mailing list
pld-devel-en@lists.pld-linux.org
http://lists.pld-linux.org/mailman/listinfo/pld-devel-en

Reply via email to