bugfix: use GNU Patch under FreeBSD (by Tony Theodore)

This commit is contained in:
Volker Grabsch 2010-09-13 11:47:52 +02:00
parent d70597fd94
commit 7695cd835a
2 changed files with 4 additions and 3 deletions

View File

@ -16,6 +16,7 @@ TOP_DIR := $(patsubst %/,%,$(dir $(MAKEFILE)))
PATH := $(PREFIX)/bin:$(PATH)
SHELL := bash
SED := $(shell gsed --help >/dev/null 2>&1 && echo g)sed
PATCH := $(shell gpatch --help >/dev/null 2>&1 && echo g)patch
INSTALL := $(shell ginstall --help >/dev/null 2>&1 && echo g)install
LIBTOOLIZE := $(shell glibtoolize --help >/dev/null 2>&1 && echo g)libtoolize
VERSION := $(shell $(SED) -n 's,^.*<span id="latest-version">\([^<]*\)</span>.*$$,\1,p' '$(TOP_DIR)/doc/index.html')
@ -125,7 +126,7 @@ build-only-$(1):
cd '$(2)' && $(call UNPACK_PKG_ARCHIVE,$(1))
cd '$(2)/$($(1)_SUBDIR)'
$(foreach PKG_PATCH,$(sort $(wildcard $(TOP_DIR)/src/$(1)-*.patch)),
(cd '$(2)/$($(1)_SUBDIR)' && patch -p1 -u) < $(PKG_PATCH))
(cd '$(2)/$($(1)_SUBDIR)' && $(PATCH) -p1 -u) < $(PKG_PATCH))
$$(call $(1)_BUILD,$(2)/$($(1)_SUBDIR),$(TOP_DIR)/src/$(1)-test)
rm -rfv '$(2)'
,)

View File

@ -589,8 +589,8 @@ USE_OSGPLUGIN(&lt;plugin2&gt;)
<!-- http://www.freebsd.org/ports/ -->
<pre>pkg_add -r automake110 autoconf262 bash bison cmake \
flex gmake gsed libtool openssl perl \
pkg-config scons unzip wget xz</pre>
flex gmake gsed libtool openssl patch perl \
pkg-config scons unzip wget</pre>
<p>
Ensure that /usr/local/bin preceeds /usr/bin in your $PATH: