1
0
mirror of https://git.FreeBSD.org/ports.git synced 2024-11-20 00:21:35 +00:00

sysutils/showbeastie: 0.1 -> 0.2, build-fixes

PR:		208283
Submitted by:	xmj, Tobias Kortkamp <t@tobik.me> (maintainer)
This commit is contained in:
Kurt Jaeger 2016-04-02 05:39:14 +00:00
parent cce6716655
commit 237fd26b60
Notes: svn2git 2021-03-31 03:12:20 +00:00
svn path=/head/; revision=412380
2 changed files with 42 additions and 9 deletions

View File

@ -2,7 +2,7 @@
# $FreeBSD$
PORTNAME= showbeastie
PORTVERSION= 0.1
PORTVERSION= 0.2
CATEGORIES= sysutils
MASTER_SITES=
DISTFILES=
@ -12,9 +12,9 @@ COMMENT= Preview FreeBSD loader logos
LICENSE= BSD2CLAUSE
# Let's pretend we build a kernel module, because we require the
# kernel sources
USES= kmod
.if !exists(${SRC_BASE}/sys/Makefile)
IGNORE= requires kernel source files in ${SRC_BASE}
.endif
NO_FETCH= yes
@ -22,9 +22,14 @@ ALL_TARGET= testmain
PLIST_FILES= bin/${PORTNAME}
# Make sure building succeeds on HEAD
MAKE_ARGS+= -m ${SRC_BASE}/share/mk
pre-patch:
@${MKDIR} ${WRKSRC}
@(cd ${SRC_BASE}/sys/boot/ficl && ${COPYTREE_SHARE} . ${WRKSRC})
@${TAR} -C ${SRC_BASE}/sys/boot/ficl \
--exclude '*.o' --exclude '*.a' --exclude 'testmain' \
-cf - . | ${TAR} -C ${WRKSRC} -xf -
post-patch:
${REINPLACE_CMD} 's|-I.*/\.\./common|-I${SRC_BASE}/sys/boot/common|g' \

View File

@ -1,6 +1,14 @@
--- testmain.c.orig 2016-03-02 15:04:22 UTC
--- testmain.c.orig 2015-10-11 17:48:47 UTC
+++ testmain.c
@@ -316,17 +316,38 @@ int main(int argc, char **argv)
@@ -296,6 +296,7 @@ void buildTestInterface(FICL_SYSTEM *pSy
ficlBuild(pSys, "cd", ficlChDir, FW_DEFAULT);
ficlBuild(pSys, "execxt", execxt, FW_DEFAULT);
ficlBuild(pSys, "load", ficlLoad, FW_DEFAULT);
+ ficlBuild(pSys, "include", ficlLoad, FW_DEFAULT);
ficlBuild(pSys, "pwd", ficlGetCWD, FW_DEFAULT);
ficlBuild(pSys, "system", ficlSystem, FW_DEFAULT);
ficlBuild(pSys, "spewhash", spewHash, FW_DEFAULT);
@@ -316,17 +317,58 @@ int main(int argc, char **argv)
buildTestInterface(pSys);
pVM = ficlNewVM(pSys);
@ -9,15 +17,27 @@
+ ficlEvaluate(pVM, "vocabulary support-functions");
+ ficlEvaluate(pVM, ": contains? ( -- ) FALSE ;");
+ ficlEvaluate(pVM, ": any_conf_read? ( -- ) FALSE ;");
+ ficlEvaluate(pVM, ": boot_serial? ( -- ) TRUE ;");
+ ficlEvaluate(pVM, ": load_kernel ( -- ) ;");
+ ficlEvaluate(pVM, ": load_modules ( -- ) ;");
+ ficlEvaluate(pVM, ": delay_execute ( -- ) ;");
+ ficlEvaluate(pVM, ": boot ( -- ) ;");
+ ficlEvaluate(pVM, ": reboot ( -- ) ;");
+ ficlEvaluate(pVM, ": load_xen_throw ( -- ) ;");
+ ficlEvaluate(pVM, "variable logoX");
+ ficlEvaluate(pVM, "variable logoY");
+ ficlEvaluate(pVM, "variable brandX");
+ ficlEvaluate(pVM, "variable brandY");
+
+ sprintf(in, "load %s", "/boot/screen.4th");
+ ficlEvaluate(pVM, in);
+ sprintf(in, "load %s", "/boot/beastie.4th");
+ ficlEvaluate(pVM, in);
+ sprintf(in, "load %s", "/boot/brand.4th");
+ ficlEvaluate(pVM, in);
+ sprintf(in, "load %s", "/boot/frames.4th");
+ ficlEvaluate(pVM, in);
+ sprintf(in, "load %s", "/boot/menu.4th");
+ ficlEvaluate(pVM, in);
/*
@ -26,15 +46,23 @@
if (argc > 1)
{
- sprintf(in, ".( loading %s ) cr load %s\n cr", argv[1], argv[1]);
+ sprintf(in, "load %s", argv[1], argv[1]);
+ char *brand = "/boot/brand-fbsd.4th";
+ sprintf(in, "load %s", argv[1]);
+ ficlEvaluate(pVM, in);
+ if (argc > 2) {
+ brand = argv[2];
+ }
+ sprintf(in, "load %s", brand);
ficlEvaluate(pVM, in);
+ } else {
+ fprintf(stderr, "usage: %s <logo.4th>\n", argv[0]);
+ fprintf(stderr, "usage: %s <logo.4th> [<brand.4th>]\n", argv[0]);
+ return 1;
}
+ system("clear");
+ ficlEvaluate(pVM, "draw-beastie");
+ ficlEvaluate(pVM, "draw-brand");
+ ficlEvaluate(pVM, "menu-init");
+ printf("\n\n");
+ return 0;
+