aboutsummaryrefslogtreecommitdiff
path: root/sysutils/minipro
diff options
context:
space:
mode:
authorPiotr Kubaj <pkubaj@FreeBSD.org>2019-07-09 09:49:19 +0000
committerPiotr Kubaj <pkubaj@FreeBSD.org>2019-07-09 09:49:19 +0000
commit60bdebe0421626c89e3391b68c2fa185d833496a (patch)
treed5b30a728af26094861fd6d7cd14eac36fc90328 /sysutils/minipro
parent836bdb2d0ee14238d1a5a3dc6f6ef2df4eb9cc3f (diff)
downloadports-60bdebe0421626c89e3391b68c2fa185d833496a.tar.gz
ports-60bdebe0421626c89e3391b68c2fa185d833496a.zip
sysutils/minipro: fix build with GCC-based architectures
This port needs new GCC to build on GCC architectures. Actually respect CC by putting ?= instead of =. Also respect CFLAGS and remove post-patch step, instead use a separate patch file. PR: 238515 Approved by: mat (mentor) Differential Revision: https://reviews.freebsd.org/D20819
Notes
Notes: svn path=/head/; revision=506276
Diffstat (limited to 'sysutils/minipro')
-rw-r--r--sysutils/minipro/Makefile7
-rw-r--r--sysutils/minipro/files/patch-Makefile31
2 files changed, 32 insertions, 6 deletions
diff --git a/sysutils/minipro/Makefile b/sysutils/minipro/Makefile
index b739ea7ed8a6..354a29c1a5e4 100644
--- a/sysutils/minipro/Makefile
+++ b/sysutils/minipro/Makefile
@@ -12,7 +12,7 @@ LICENSE= GPLv3
RUN_DEPENDS= bash:shells/bash
-USES= gmake pkgconfig shebangfix
+USES= compiler:c11 gmake pkgconfig shebangfix
USE_GITLAB= yes
GL_ACCOUNT= DavidGriffith
@@ -23,11 +23,6 @@ PLIST_FILES= bin/minipro \
bin/miniprohex \
man/man1/minipro.1.gz
-post-patch:
- @${REINPLACE_CMD} -e ' s|gcc|clang|g' \
- -e 's|share/||g' \
- ${WRKSRC}/Makefile
-
post-install:
@${GZIP_CMD} ${STAGEDIR}${PREFIX}/man/man1/minipro.1
@${STRIP_CMD} ${STAGEDIR}${PREFIX}/bin/${PORTNAME}
diff --git a/sysutils/minipro/files/patch-Makefile b/sysutils/minipro/files/patch-Makefile
new file mode 100644
index 000000000000..d69c9c97ddd1
--- /dev/null
+++ b/sysutils/minipro/files/patch-Makefile
@@ -0,0 +1,31 @@
+--- Makefile.orig 2019-02-27 06:19:06 UTC
++++ Makefile
+@@ -1,16 +1,16 @@
+ # Install Configuration
+
+ # Your C compiler
+-CC=gcc
++CC?=gcc
+ #CC=clang
+
+ # Compiler options
+-CFLAGS = -g -O0 -Wall
++CFLAGS ?= -g -O0 -Wall
+
+ # Normally minipro is installed to /usr/local. If you want to put it
+ # somewhere else, define that location here.
+ PREFIX ?= /usr/local
+-MANDIR ?= $(PREFIX)/share/man
++MANDIR ?= $(PREFIX)/man
+
+ # Some older releases of MacOS need some extra library flags.
+ #EXTRA_LIBS += "-framework Foundation -framework IOKit"
+@@ -58,7 +58,7 @@ OBJCOPY=objcopy
+
+ DIST_DIR = $(MINIPRO)-$(VERSION)
+ BIN_INSTDIR=$(DESTDIR)$(PREFIX)/bin
+-MAN_INSTDIR=$(DESTDIR)$(PREFIX)/share/man/man1
++MAN_INSTDIR=$(DESTDIR)$(PREFIX)/man/man1
+
+ UDEV_DIR=$(shell $(PKG_CONFIG) --define-variable=prefix=$(PREFIX) --silence-errors --variable=udevdir udev)
+ UDEV_RULES_INSTDIR=$(DESTDIR)$(UDEV_DIR)/rules.d