EXTRA_PATCHES considered harmful?

Eugene Grosbein eugen at grosbein.net
Sat Sep 23 22:22:34 UTC 2017

24.09.2017 4:39, Julian Elischer wrote:
> currently if you set EXTRA_PATCHES and the port you are making decides to build a second port as a dependency, EXTRA_PATCHES is passed to the second port which them obiously fails to patch it.
> e.g.  cd /usr/ports/emulators/open-vm-tools-nox11; Make EXTRA_PATCHES=/foo/bar/patch1
> will fail when it tries to apply the patch files to each dependency.
> AM I doing something wrong here?

Obviously, one should not use EXTRA_PATCHES in command line,
rather define an option for distinct port's Makefile and
turn option on/off in command line instead.

For example, converters/iconv's Makefile has:

CCSUTIL_EXTRA_PATCHES_OFF=      ${FILESDIR}/extra-patch-ccs_Makefile

And you can run "make WITH_CCSUTIL=yes"

More information about the freebsd-ports mailing list