From 30cd79ca358540d1b96c3c637f6d0e22ab2bd6bc Mon Sep 17 00:00:00 2001 From: wen Date: Sat, 31 Dec 2011 08:10:20 +0000 Subject: - respect CC/CFLAGS, now build with clang PR: ports/161943 Submitted by: Nali Toja --- lang/ucc/Makefile | 12 +++++++++++- lang/ucc/files/patch-Makefile | 23 +++++++---------------- 2 files changed, 18 insertions(+), 17 deletions(-) (limited to 'lang') diff --git a/lang/ucc/Makefile b/lang/ucc/Makefile index 667c6dd02b02..210822b7105e 100644 --- a/lang/ucc/Makefile +++ b/lang/ucc/Makefile @@ -15,9 +15,19 @@ MAINTAINER= wenheping@gmail.com COMMENT= C Compiler Which Implements the ANSI C89 Standard USE_ZIP= yes +USE_DOS2UNIX= yes WRKSRC= ${WRKDIR}/${PORTNAME} -USE_GMAKE= yes USE_LDCONFIG= yes +post-patch: .SILENT + ${REINPLACE_CMD} 's/make/$$(MAKE)/' \ + ${WRKSRC}/Makefile + ${REINPLACE_CMD} -e '/^CC[[:blank:]]*=/d' \ + -e '/^CFLAGS/ { s/=/+=/; s/-g//; }' \ + -e '/:[[:blank:]]/s/\.c/.o/g' \ + -e 's/$$^/$$>/g' \ + ${WRKSRC}/driver/Makefile \ + ${WRKSRC}/ucl/Makefile + .include diff --git a/lang/ucc/files/patch-Makefile b/lang/ucc/files/patch-Makefile index 58d4ebded3af..f54aadd01185 100644 --- a/lang/ucc/files/patch-Makefile +++ b/lang/ucc/files/patch-Makefile @@ -1,22 +1,15 @@ ---- Makefile.orig 2008-05-14 11:13:02.000000000 +0800 -+++ Makefile 2008-08-15 13:25:35.000000000 +0800 -@@ -1,21 +1,21 @@ +--- Makefile.orig 2011-12-31 14:41:27.000000000 +0800 ++++ Makefile 2011-12-31 14:43:38.000000000 +0800 +@@ -1,5 +1,5 @@ -UCCDIR = /usr/local/lib/ucc -export UCCDIR +UCCDIR = ${PREFIX} +#export UCCDIR all: -- make -C driver -- make -C ucl -+ gmake -C driver -+ gmake -C ucl - - clean: -- make -C driver clean -- make -C ucl clean -+ gmake -C driver clean -+ gmake -C ucl clean + make -C driver +@@ -10,11 +10,11 @@ + make -C ucl clean install: - mkdir -p $(UCCDIR) @@ -31,6 +24,4 @@ + cp ucl/linux/include/* $(UCCDIR)/include/ucc/ test: -- make -C ucl test -+ gmake -C ucl test - + make -C ucl test -- cgit