CFLAGS are always ignored. ### List of files built with LDFLAGS ignored ### /usr/bin/zip /usr/bin/zipcloak /usr/bin/zipsplit /usr/bin/zipnote ### End of list ###
OK, that was about enough. 1/ Use common sense when filing bugs (like, what about mailing gentoo-dev mailing list first and asking about the best course of action here? 2/ If you have a patch, submit it *upstream* unless this is a *Gentoo-specific* issue.
This bug report also concerns CFLAGS. Unfortunately you didn't see it. http://devmanual.gentoo.org/ebuild-writing/functions/src_compile/building/index.html and http://devmanual.gentoo.org/general-concepts/user-environment/index.html say that CFLAGS should be respected. I think that this bug report should be reopened.
I discovered that target "generic" has broken behaviour (and generally this Makefile is strange). It uses variables from file "flags", so this file must be recreated. If "eval $(MAKE) zips `cat flags`" is changed to "eval $(MAKE) zips", then we have new problems: 1. CFLAGS doesn't contain probably necessary -D* flags. 2. "LFLAGS1 =" line should be changed to "LFLAGS1 = $(LDFLAGS)" using sed. 3. "LFLAGS2 = -s" line causes "QA Notice: Pre-stripped files found". 4. OBJA isn't set and executable "zip" lacks code from 2 object files, because there is in unix/Makefile: OBJA = ... zip$(EXE): $(OBJZ) $(OBJI) $(OBJA) $(BIND) -o zip$(EXE) $(LFLAGS1) $(OBJZ) $(OBJI) $(OBJA) $(LFLAGS2) I think that recreating file "flags" is good decision.
Created attachment 121847 [details, diff] Patch
that patch is certainly not right ... you cant hardcode those flags in the ebuild ive cleaned up the build process in cvs