Filtering -fstack-protector out of CFLAGS
Adam Jackson
ajax at redhat.com
Tue Nov 11 16:17:26 UTC 2008
On Tue, 2008-11-11 at 08:21 -0700, Jerry James wrote:
> GCL will not run successfully if compiled with -fstack-protector. It
> has its own internal stack management code that interacts badly with
> -fstack-protector. So I decided to try filtering that option out of
> the default CFLAGS. I put this at the top of the GCL spec file:
>
> %global __global_cflags %{echo %__global_cflags | %{__sed} 's/
> -fstack-protector//'}
>
> That seems to work, in that %configure passes RPM_OPT_FLAGS minus
> -fstack-protector, but when I run rpmbuild, I see:
>
> echoechoechoechoechoechoechoechoExecuting(%prep): ...
>
> What's with the 8 "echo" strings, one right after the other? Is that
> something I should worry about? Am I filtering CFLAGS the right way?
> Do I need to get explicit permission from some group to do this?
> Thanks,
In the X server, I do:
export CFLAGS="${RPM_OPT_FLAGS} -Wstrict-overflow -rdynamic $CFLAGS"
%configure --enable-maintainer-mode %{xservers} \
# ...
Which seems to work fine.
- ajax
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 197 bytes
Desc: This is a digitally signed message part
URL: <http://listman.redhat.com/archives/fedora-devel-list/attachments/20081111/a2c7c7c8/attachment.sig>
More information about the fedora-devel-list
mailing list