FS#23906 - [openjpeg] have a way to set custom CFLAGS, LDFLAGS
Attached to Project:
Arch Linux
Opened by Kristoffer Tidemann (ktide) - Saturday, 23 April 2011, 20:26 GMT
Last edited by Jan de Groot (JGC) - Monday, 16 April 2012, 14:12 GMT
Opened by Kristoffer Tidemann (ktide) - Saturday, 23 April 2011, 20:26 GMT
Last edited by Jan de Groot (JGC) - Monday, 16 April 2012, 14:12 GMT
|
Details
The Makefile doesn't make use of LDFLAGS and defines it's
own CFLAGS. The only and kinda shitty way to get *both*
included during compile and link is to do something like
this in the PKGBUILD:
make CC="gcc ${CFLAGS} ${LDFLAGS}" The patch from Debian that "fixes" the Makefile is pretty stupid and could be adjusted instead of doing it this way. |
This task depends upon
Closed by Jan de Groot (JGC)
Monday, 16 April 2012, 14:12 GMT
Reason for closing: Fixed
Additional comments about closing: openjpeg 1.5.0 takes LDFLAGS and CFLAGS into account.
Monday, 16 April 2012, 14:12 GMT
Reason for closing: Fixed
Additional comments about closing: openjpeg 1.5.0 takes LDFLAGS and CFLAGS into account.
You'd better use cmake if you want a proper, more complete build system.
+COMPILERFLAGS = $(EXTRA_CFLAGS) -ffast-math -std=c99 -fPIC
and
+ $(CC) -shared -Wl,-soname,$(LIBNAME) $(LDFLAGS) -o $@ $(MODULES) -lm
PKGBUILD:
make EXTRA_CFLAGS="${CFLAGS/-O2/-O3}"
or something similar