pkgsrc-WIP-changes archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

bosh: Share Makefile.common with smake



Module Name:	pkgsrc-wip
Committed By:	Michael Baeuerle <michael.baeuerle%stz-e.de@localhost>
Pushed By:	micha
Date:		Wed Sep 26 19:48:18 2018 +0200
Changeset:	d21a6fe2868ccbff96014d0702e5c5fcae2c2a1f

Modified Files:
	bosh/Makefile
	bosh/TODO

Log Message:
bosh: Share Makefile.common with smake

To see a diff of this commit:
https://wip.pkgsrc.org/cgi-bin/gitweb.cgi?p=pkgsrc-wip.git;a=commitdiff;h=d21a6fe2868ccbff96014d0702e5c5fcae2c2a1f

Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.

diffstat:
 bosh/Makefile | 43 +++++++++++--------------------------------
 bosh/TODO     |  9 ++-------
 2 files changed, 13 insertions(+), 39 deletions(-)

diffs:
diff --git a/bosh/Makefile b/bosh/Makefile
index b74e2c8fec..0b9bc67889 100644
--- a/bosh/Makefile
+++ b/bosh/Makefile
@@ -12,27 +12,14 @@ COMMENT=	The Schily Bourne Shell
 LICENSE=	cddl-1.0
 
 MAKE_JOBS_SAFE=	no
-MAKE_FLAGS+=	GMAKE_NOWARN=true
 
-USE_TOOLS+=	gmake tbl
+USE_TOOLS+=	smake tbl
 
 PKG_SHELL=	bin/bosh
 INSTALLATION_DIRS=	bin ${PKGMANDIR}/man1
 
 .include "../../mk/bsd.prefs.mk"
 
-# Map PKGSRC_COMPILER to CCOM used by schilytools build system.
-.if !empty(PKGSRC_COMPILER:Mgcc)
-MAKE_FLAGS+=	CCOM=gcc
-.elif !empty(PKGSRC_COMPILER:Mclang)
-MAKE_FLAGS+=	CCOM=clang
-# The following compilers are untested
-.elif !empty(PKGSRC_COMPILER:Micc)
-MAKE_FLAGS+=	CCOM=icc
-.else
-MAKE_FLAGS+=	CCOM=cc
-.endif
-
 # Fix testsuite (NetBSD od creates whitespace at the end of output lines)
 SUBST_CLASSES+=		od
 SUBST_STAGE.od=		post-patch
@@ -40,40 +27,32 @@ SUBST_FILES.od=		sh/tests/shelltests/printf/printf.sh
 SUBST_SED.od=		-e "s,-e \\\\\"s/\^\[ 	]\*//\\\[\"],-e \\\\\"s/^[ 	]*//\\\\\" -e \\\\\"s/[ 	]*$$//\\\\\",g"
 SUBST_MESSAGE.od=	Fix processing of output from od.
 
+# Shared platform specific hacks for schilytools (provided by smake package)
+.include "../../wip/smake/Makefile.common"
+
 do-configure:
-	cd ${WRKSRC}/RULES;						\
-	if [ ! -f i386-netbsd-clang.rul ]; then				\
-		${SED} -e 's/cc-gcc.rul/cc-$$(C_ARCH).rul/' i386-netbsd-gcc.rul >i386-netbsd-clang.rul; \
-	fi
-	cd ${WRKSRC}/RULES;						\
-	for suffix in netbsd-clang.rul netbsd-cc.rul netbsd-gcc.rul; do	\
-		if [ ! -f ${MACHINE}-$$suffix ]; then			\
-			ln -sf i386-$$suffix ${MACHINE}-$$suffix;	\
-		fi;							\
-	done;								\
-	${CP} -fp i386-darwin-clang.rul x86_64-darwin-clang.rul
-	cd ${WRKSRC}/inc && ${MAKE_PROGRAM} ${MAKE_FLAGS}
+	cd ${WRKSRC}/inc && MAKEFLAGS=${MAKEFLAGS:S/:_MAKE/_PKGSRC_MAKE/} ${MAKE_PROGRAM} ${MAKE_FLAGS}
 
 do-build:
-	cd ${WRKSRC}; for library in					\
+	cd ${WRKSRC} && for library in					\
 		libschily libxtermcap libfind libgetopt libshedit;	\
 	do								\
 		cd ${WRKSRC}/$${library} &&				\
-		${MAKE_PROGRAM} ${MAKE_FLAGS};				\
+			${MAKE_PROGRAM} ${MAKE_FLAGS};			\
 	done
 	cd ${WRKSRC}/sh && ${MAKE_PROGRAM} ${MAKE_FLAGS}
 
 # Process tables in manpage
 post-build:
-	cd ${WRKSRC}; tbl sh/sh.1 >sh/sh.1.tmp;				\
+	cd ${WRKSRC} && ${TBL} sh/sh.1 >sh/sh.1.tmp;			\
 		mv -f sh/sh.1.tmp sh/bosh.1
 
 do-test:
-	cd ${WRKSRC}/sh;						\
-	cd tests; ${MAKE_PROGRAM} ${MAKE_FLAGS} tests
+	cd ${WRKSRC}/sh &&						\
+		cd tests; ${MAKE_PROGRAM} ${MAKE_FLAGS} tests
 
 do-install:
-	cd ${WRKSRC}/sh;						\
+	cd ${WRKSRC}/sh &&						\
 		${INSTALL_PROGRAM} ${WRKSRC}/sh/OBJ/*/sh		\
 			${DESTDIR}${PREFIX}/bin/bosh;			\
 		${INSTALL_MAN} ${WRKSRC}/sh/bosh.1 			\
diff --git a/bosh/TODO b/bosh/TODO
index bf4a85cb5e..6a82c308c6 100644
--- a/bosh/TODO
+++ b/bosh/TODO
@@ -4,10 +4,5 @@
     => Reported to upstream, next release will contain a workaround
 [X] Analyze keyboard behaviour for Delete and Backspace
     => Different behaviour (compared to ash and bash) is documented
-[X] Compiler setup via CCOM
-[X] Test with clang compiler
-
-[ ] Test with Intel compiler
-[ ] Test with SunPro compiler
-[ ] Test with non-NetBSD operating systems
-[ ] Add obosh and pbosh variants to this package?
+[X] Add obosh and pbosh variants to this package?
+    => No, use separate packages


Home | Main Index | Thread Index | Old Index