libz/zlib fix needs updating after change in src: Index: Makefile =================================================================== --- Makefile (revision 431539) +++ Makefile (working copy) @@ -35,7 +35,7 @@ > ${WRKSRC}/opennurbs_version.h.tmp || ${TRUE} ${MV} ${WRKSRC}/opennurbs_version.h.tmp ${WRKSRC}/opennurbs_version.h ${MV} ${WRKSRC}/zlib ${WRKSRC}/zlib_ - ${CP} -R ${SRC_BASE}/lib/libz ${WRKSRC}/zlib + ${CP} -R ${SRC_BASE}/contrib/zlib ${WRKSRC}/zlib do-install: @${MKDIR} ${STAGEDIR}${EXAMPLESDIR} \
(In reply to Poul-Henning Kamp from comment #0) Thanks for the patch. I don't have a -CURRENT system to test it, but it simple enough so you have my approval. Thanks
- Wait, why do you copy zlib from src/ at all? If any, you should remove bundled zlib and use system one. Not sure how dependees would handle this - iconv in pre-build does not seem to do anything. why's it needed? - do-install is an overcomplication just for examples installation, ports should not do such things; I'd just install example apps, and they should go to examplesdir, not libexec
(In reply to Dmitry Marakasov from comment #2) The first version of the patch used just the bundled version of zlib which eventually broke QCad. Copying the sources from base was the fastest patch I came up with. iconv. Agreed. I tested it and it doesn't seem to be necessary right now (not sure if it was in the past) The simplification of the installation of examples is certainly necessary. The patch submitted by phk@ needs to be actually a conditional since we want it to work on systems with both paths. I'll work on it as soon as I can and send a new patch.
Created attachment 179871 [details] fix detection of zlib.h Tested on current and 103.
(In reply to Tobias C. Berner from comment #4) Reworked patch. I added Tobias' detection patch. - Removed iconv related code. - Examples go to EXAMPLESDIR instead of libexec I didn't change the copy if of the zlib sources. Linking the directory is not an option (see this: https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=187506). We could try to avoid to include the zlib.o files in the library archive, but then some of the .o files would have unresolved symbols and we would force the final executable to be linked against zlib (-lz). I'm not sure if this violates POLA since linking against zlib is not necessary if the upstream package is used. Please, let me know what you think. Thanks.
Created attachment 180001 [details] patch to the ports tree
Comment on attachment 179871 [details] fix detection of zlib.h Superseded by this patch: https://bugs.freebsd.org/bugzilla/attachment.cgi?id=180001 which includes this one.
Comment on attachment 179871 [details] fix detection of zlib.h Superseded by this one: https://bugs.freebsd.org/bugzilla/attachment.cgi?id=180001
Created attachment 180043 [details] Improved patch Hmm, it actually turns out to be hard to unbundle zlib. Ok, let it be taken from src. I've improved a patch a bit: actually removed iconv stuff, made examples installation optional.
(In reply to Dmitry Marakasov from comment #9) The patch makes the port much cleaner, thanks! I tested it with and without examples via port test. I couldn't test it with poudriere though. I get this error: =========================================================================== =======================<phase: patch-depends >============================ =========================================================================== =======================<phase: patch >============================ ===> Patching for opennurbs-20130711_3 ===> Converting DOS text files to UNIX text files ===> Applying FreeBSD patches for opennurbs-20130711_3 Ignoring previously applied (or reversed) patch. 1 out of 1 hunks ignored--saving rejects to opennurbs_system.h.rej => FreeBSD patch patch-opennurbs__system.h failed to apply cleanly. => Patch(es) patch-opennurbs__system.h applied cleanly. *** Error code 1 I suppose is something in my poudriere set up? Other ports build fine though... I approve this patch. Thanks for improving it.
Comment on attachment 180001 [details] patch to the ports tree superseded by https://bugs.freebsd.org/bugzilla/attachment.cgi?id=180043
(In reply to fernando.apesteguia from comment #10) Just for the record, I fixed my jails and I can confirm the patch builds fine in {10.3,11.0}{i386,amd64} What's preventing the patch from being committed?
No advance on this? Is there singing wrong with the patch?
Again, Why has this stalled?
(In reply to fernando.apesteguia from comment #14) > Again, > > Why has this stalled? https://bz-attachments.freebsd.org/attachment.cgi?id=180043&action=diff&format=raw&headers=1 Is this the final patch?
(In reply to Bryan Drewery from comment #15) Yes, the final one by amdmi3@
taking this PR, Approved By: adamw (mentor)
A commit references this bug: Author: ler Date: Thu Mar 23 01:27:35 UTC 2017 New revision: 436749 URL: https://svnweb.freebsd.org/changeset/ports/436749 Log: fix finding of the zlib sources. PR: 216212 Submitted by: mdmi3 Approved by: fernando.apesteguia@gmail.com, phk, adamw (mentor) Differential Revision: https://reviews.freebsd.org/D10110 Changes: head/graphics/opennurbs/Makefile head/graphics/opennurbs/files/patch-opennurbs__system.h head/graphics/opennurbs/pkg-plist
Committed, Thanks all. Thank you for the patience.