Source-Changes-HG archive

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

[src/trunk]: src/distrib/acorn32 Create initial distribution directory for Ne...



details:   https://anonhg.NetBSD.org/src/rev/7bf1c9521c71
branches:  trunk
changeset: 521174:7bf1c9521c71
user:      reinoud <reinoud%NetBSD.org@localhost>
date:      Fri Jan 25 15:28:41 2002 +0000

description:
Create initial distribution directory for NetBSD/acorn32. There might be
some unused stuff in there like the floppies but i've left them here for
completion. They might be interesting to build one day too.

diffstat:

 distrib/acorn32/Makefile                   |    27 +
 distrib/acorn32/Makefile.inc               |     4 +
 distrib/acorn32/floppies/Makefile          |     5 +
 distrib/acorn32/floppies/Makefile.inc      |     3 +
 distrib/acorn32/floppies/list2sh.awk       |    55 +
 distrib/acorn32/floppies/runlist.sh        |    13 +
 distrib/acorn32/kernels/Makefile           |    34 +
 distrib/acorn32/ramdisk/Makefile           |    56 +
 distrib/acorn32/ramdisk/disktab.preinstall |    31 +
 distrib/acorn32/ramdisk/dot.commonutils    |   135 +++
 distrib/acorn32/ramdisk/dot.hdprofile      |    62 +
 distrib/acorn32/ramdisk/dot.instutils      |   188 +++++
 distrib/acorn32/ramdisk/dot.profile        |    64 +
 distrib/acorn32/ramdisk/inst.sh            |  1041 ++++++++++++++++++++++++++++
 distrib/acorn32/ramdisk/install.tmpl       |   519 +++++++++++++
 distrib/acorn32/ramdisk/list               |    99 ++
 distrib/acorn32/ramdisk/list2sh.awk        |    70 +
 distrib/acorn32/ramdisk/mtree.conf         |    82 ++
 distrib/acorn32/ramdisk/ramdiskbin.conf    |    34 +
 distrib/acorn32/ramdisk/runlist.sh         |    13 +
 distrib/acorn32/ramdisk/start.tmpl         |    45 +
 distrib/acorn32/ramdisk/termcap.pc3        |    44 +
 distrib/acorn32/ramdisk/termcap.xterm      |    23 +
 distrib/acorn32/ramdisk/upgrade.tmpl       |   240 ++++++
 24 files changed, 2887 insertions(+), 0 deletions(-)

diffs (truncated from 2983 to 300 lines):

diff -r 8b7ad6092da9 -r 7bf1c9521c71 distrib/acorn32/Makefile
--- /dev/null   Thu Jan 01 00:00:00 1970 +0000
+++ b/distrib/acorn32/Makefile  Fri Jan 25 15:28:41 2002 +0000
@@ -0,0 +1,27 @@
+# $NetBSD: Makefile,v 1.1 2002/01/25 15:28:41 reinoud Exp $
+
+ITARGET=       ${RELEASEDIR}/installation
+IINST=         ${INSTALL} ${RENAME} ${PRESERVE} ${COPY}        \
+               -o ${BINOWN} -g ${BINGRP} -m ${NONBINMODE}
+KERNELS=       INSTALL
+
+SUBDIR= ramdisk kernels
+
+REV!=sh ${.CURDIR}/../../sys/conf/osrelease.sh -s
+
+.include <bsd.subdir.mk>
+
+.ifndef RELEASEDIR
+release:
+       @echo setenv RELEASEDIR first
+       @false
+.else
+RAMDISKOBJ != cd ${.CURDIR}/ramdisk && ${PRINTOBJDIR}
+KERNELOBJ != cd ${.CURDIR}/kernels && ${PRINTOBJDIR}
+
+release:
+       ${IINST} ${RAMDISKOBJ}/ramdisk-${REV}.fs.gz ${ITARGET}/misc/
+.for kern in ${KERNELS}
+       ${IINST} ${KERNELOBJ}/netbsd.${kern}.gz ${ITARGET}/kernel/
+.endfor
+.endif
diff -r 8b7ad6092da9 -r 7bf1c9521c71 distrib/acorn32/Makefile.inc
--- /dev/null   Thu Jan 01 00:00:00 1970 +0000
+++ b/distrib/acorn32/Makefile.inc      Fri Jan 25 15:28:41 2002 +0000
@@ -0,0 +1,4 @@
+# $NetBSD: Makefile.inc,v 1.1 2002/01/25 15:28:41 reinoud Exp $
+.include <bsd.own.mk>
+
+REV!=sh ${.CURDIR}/../../../sys/conf/osrelease.sh -s
diff -r 8b7ad6092da9 -r 7bf1c9521c71 distrib/acorn32/floppies/Makefile
--- /dev/null   Thu Jan 01 00:00:00 1970 +0000
+++ b/distrib/acorn32/floppies/Makefile Fri Jan 25 15:28:41 2002 +0000
@@ -0,0 +1,5 @@
+# $NetBSD: Makefile,v 1.1 2002/01/25 15:28:43 reinoud Exp $
+
+SUBDIR= inst upgr
+
+.include <bsd.subdir.mk>
diff -r 8b7ad6092da9 -r 7bf1c9521c71 distrib/acorn32/floppies/Makefile.inc
--- /dev/null   Thu Jan 01 00:00:00 1970 +0000
+++ b/distrib/acorn32/floppies/Makefile.inc     Fri Jan 25 15:28:41 2002 +0000
@@ -0,0 +1,3 @@
+# $NetBSD: Makefile.inc,v 1.1 2002/01/25 15:28:43 reinoud Exp $
+
+REV!=sh ${.CURDIR}/../../../sys/conf/osrelease.sh -s
diff -r 8b7ad6092da9 -r 7bf1c9521c71 distrib/acorn32/floppies/list2sh.awk
--- /dev/null   Thu Jan 01 00:00:00 1970 +0000
+++ b/distrib/acorn32/floppies/list2sh.awk      Fri Jan 25 15:28:41 2002 +0000
@@ -0,0 +1,55 @@
+# $NetBSD: list2sh.awk,v 1.1 2002/01/25 15:28:43 reinoud Exp $
+
+BEGIN {
+       printf("cd ${CURDIR}\n");
+       printf("\n");
+}
+/^$/ || /^#/ {
+       print $0;
+       next;
+}
+$1 == "COPY" {
+       printf("echo '%s'\n", $0);
+       printf("rm -f ${TARGDIR}/%s\n", $3);
+       printf("cp %s ${TARGDIR}/%s\n", $2, $3);
+       next;
+}
+$1 == "LINK" {
+       printf("echo '%s'\n", $0);
+       printf("rm -f ${TARGDIR}/%s\n", $3);
+       printf("(cd ${TARGDIR}; ln %s %s)\n", $2, $3);
+       next;
+}
+$1 == "SYMLINK" {
+       printf("echo '%s'\n", $0);
+       printf("rm -f ${TARGDIR}/%s\n", $3);
+       printf("(cd ${TARGDIR}; ln -s %s %s)\n", $2, $3);
+       next;
+}
+$1 == "COPYDIR" {
+       printf("echo '%s'\n", $0);
+       printf("(cd ${TARGDIR}/%s && find . ! -name . | xargs /bin/rm -rf)\n",
+           $3);
+       printf("(cd %s && find . ! -name . | cpio -pdamu ${TARGDIR}/%s)\n", $2,
+           $3);
+       next;
+}
+$1 == "SPECIAL" {
+       printf("echo '%s'\n", $0);
+       printf("(cd ${TARGDIR};");
+       for (i = 2; i <= NF; i++)
+               printf(" %s", $i);
+       printf(")\n");
+       next;
+}
+{
+       printf("echo '%s'\n", $0);
+       printf("echo 'Unknown keyword \"%s\" at line %d of input.'\n", $1, NR);
+       printf("exit 1\n");
+       exit 1;
+}
+END {
+       printf("\n");
+       printf("exit 0\n");
+       exit 0;
+}
diff -r 8b7ad6092da9 -r 7bf1c9521c71 distrib/acorn32/floppies/runlist.sh
--- /dev/null   Thu Jan 01 00:00:00 1970 +0000
+++ b/distrib/acorn32/floppies/runlist.sh       Fri Jan 25 15:28:41 2002 +0000
@@ -0,0 +1,13 @@
+# $NetBSD: runlist.sh,v 1.1 2002/01/25 15:28:43 reinoud Exp $
+
+if [ "X$1" = "X-d" ]; then
+       SHELLCMD=cat
+       shift
+else
+       SHELLCMD="sh -e"
+fi
+
+( while [ "X$1" != "X" ]; do
+       cat $1
+       shift
+done ) | awk -f ${TOPDIR}/list2sh.awk | ${SHELLCMD}
diff -r 8b7ad6092da9 -r 7bf1c9521c71 distrib/acorn32/kernels/Makefile
--- /dev/null   Thu Jan 01 00:00:00 1970 +0000
+++ b/distrib/acorn32/kernels/Makefile  Fri Jan 25 15:28:41 2002 +0000
@@ -0,0 +1,34 @@
+#      $NetBSD: Makefile,v 1.1 2002/01/25 15:28:44 reinoud Exp $
+
+TOP=           ${.CURDIR}/..
+
+.include "${TOP}/Makefile.inc"
+.include <bsd.kernobj.mk>
+.include <bsd.own.mk>
+
+KERNELS=       INSTALL 
+
+STRIP?=                strip
+
+RAMDISK!=      cd $(.CURDIR)/../ramdisk/; \
+                   printf "xxx: .MAKE\n\t@echo \$${.OBJDIR}/ramdisk-${REV}.fs\n" | \
+                   ${MAKE} -s -f-
+
+CLEANFILES+=   netbsd.tmp ${KERNELS:C/^.*$/netbsd.&.gz/g}
+MDSETIMAGE?=   mdsetimage
+
+all:   ${KERNELS:C/^.*$/netbsd.&.gz/g}
+
+.for kern in ${KERNELS}
+netbsd.${kern}.gz: ${KERNOBJDIR}/${kern}/netbsd ${RAMDISK}
+       cp ${KERNOBJDIR}/${kern}/netbsd netbsd.tmp
+       ${MDSETIMAGE} -v netbsd.tmp ${RAMDISK}
+       ${STRIP} netbsd.tmp
+       gzip -9 netbsd.tmp
+       mv netbsd.tmp.gz ${.TARGET}
+.endfor
+
+clean cleandir distclean:
+       /bin/rm -f *.core ${CLEANFILES}
+
+.include <bsd.obj.mk>
diff -r 8b7ad6092da9 -r 7bf1c9521c71 distrib/acorn32/ramdisk/Makefile
--- /dev/null   Thu Jan 01 00:00:00 1970 +0000
+++ b/distrib/acorn32/ramdisk/Makefile  Fri Jan 25 15:28:41 2002 +0000
@@ -0,0 +1,56 @@
+#      $NetBSD: Makefile,v 1.1 2002/01/25 15:28:45 reinoud Exp $
+
+TOP=           ${.CURDIR}/..
+
+.include "${TOP}/Makefile.inc"
+IMAGEDIR=      ${.OBJDIR}/ramdisk-image
+IMAGE=         ${.OBJDIR}/ramdisk-${REV}.fs
+
+AUXTARGETS=    install.sh upgrade.sh start.sh
+AUXCLEAN=      ${AUXTARGETS}
+
+CBIN=          ramdiskbin
+
+LISTS=         list
+CRUNCHCONF=    ${CBIN}.conf
+MTREECONF=     mtree.conf
+
+CRUNCHGEN?=    crunchgen
+MTREE?=                mtree
+
+DISKTYPE=      install-ramdisk
+RDSIZE=                3800
+
+install.sh: install.tmpl
+       sed "s/@@VERSION@@/${VER}/" < ${.ALLSRC} > ${.TARGET}
+
+upgrade.sh: upgrade.tmpl
+       sed "s/@@VERSION@@/${VER}/" < ${.ALLSRC} > ${.TARGET}
+
+start.sh: start.tmpl
+       sed "s/@@VERSION@@/${VER}/" < ${.ALLSRC} > ${.TARGET}
+
+all: ${AUXTARGETS} ${CBIN} 
+       rm -rf ${IMAGEDIR}
+       mkdir ${IMAGEDIR}
+       ${MTREE} -def ${.CURDIR}/${MTREECONF} -p ${IMAGEDIR} -u
+       TOPDIR=${TOP} CURDIR=${.CURDIR} OBJDIR=${.OBJDIR} \
+           KERNOBJDIR=${KERNOBJDIR} \
+           TARGDIR=${IMAGEDIR} sh ${.CURDIR}/runlist.sh ${.CURDIR}/${LISTS}
+       ${MAKEFS} -B le ${IMAGE} ${IMAGEDIR}
+       gzip -c9 ${IMAGE} > ${IMAGE}.gz
+
+unconfig:
+       -/bin/rm -rf ${IMAGEDIR} ${IMAGE} ${IMAGE}.gz
+
+${CBIN}.mk ${CBIN}.cache ${CBIN}.c: ${CRUNCHCONF}
+       ${CRUNCHGEN} -D ${TOP}/../.. -L ${DESTDIR}/usr/lib ${.ALLSRC}
+
+${CBIN}: ${CBIN}.mk ${CBIN}.cache ${CBIN}.c
+       ${MAKE} -f ${CBIN}.mk all
+
+clean cleandir distclean:
+       /bin/rm -rf ${AUXCLEAN} *.core ${IMAGEDIR}/* ${IMAGE} ${IMAGE}.gz ${CBIN} ${CBIN}.mk ${CBIN}.cache *.o *.cro *.c
+
+.include <bsd.obj.mk>
+.include <bsd.subdir.mk>
diff -r 8b7ad6092da9 -r 7bf1c9521c71 distrib/acorn32/ramdisk/disktab.preinstall
--- /dev/null   Thu Jan 01 00:00:00 1970 +0000
+++ b/distrib/acorn32/ramdisk/disktab.preinstall        Fri Jan 25 15:28:41 2002 +0000
@@ -0,0 +1,31 @@
+#      $NetBSD: disktab.preinstall,v 1.1 2002/01/25 15:28:45 reinoud Exp $
+#
+# Disk geometry and partition layout tables. 
+# Key:
+#      dt      controller type
+#      ty      type of disk (fixed, removeable, simulated)
+#      d[0-4]  drive-type-dependent parameters
+#      ns      #sectors/track
+#      nt      #tracks/cylinder
+#      nc      #cylinders/disk
+#      sc      #sectors/cylinder, nc*nt default
+#      su      #sectors/unit, sc*nc default
+#      se      sector size, DEV_BSIZE default
+#      rm      rpm, 3600 default
+#      sf      supports bad144-style bad sector forwarding
+#      sk      sector skew per track, default 0
+#      cs      sector skew per cylinder, default 0
+#      hs      headswitch time, default 0
+#      ts      one-cylinder seek time, default 0
+#      il      sector interleave (n:1), 1 default
+#      bs      boot block size, default BBSIZE
+#      sb      superblock size, default SBSIZE
+#      o[a-h]  partition offsets in sectors
+#      p[a-h]  partition sizes in sectors
+#      b[a-h]  partition block sizes in bytes
+#      f[a-h]  partition fragment sizes in bytes
+#      t[a-h]  partition types (filesystem, swap, etc)
+#
+# All partition sizes reserve space for bad sector tables.
+# (5 cylinders needed for maintenance + replacement sectors)
+#
diff -r 8b7ad6092da9 -r 7bf1c9521c71 distrib/acorn32/ramdisk/dot.commonutils
--- /dev/null   Thu Jan 01 00:00:00 1970 +0000
+++ b/distrib/acorn32/ramdisk/dot.commonutils   Fri Jan 25 15:28:41 2002 +0000
@@ -0,0 +1,135 @@
+# $NetBSD: dot.commonutils,v 1.1 2002/01/25 15:28:45 reinoud Exp $
+#
+# Copyright (c) 1994 Christopher G. Demetriou
+# All rights reserved.
+# 
+# Redistribution and use in source and binary forms, with or without
+# modification, are permitted provided that the following conditions
+# are met:
+# 1. Redistributions of source code must retain the above copyright
+#    notice, this list of conditions and the following disclaimer.
+# 2. Redistributions in binary form must reproduce the above copyright
+#    notice, this list of conditions and the following disclaimer in the
+#    documentation and/or other materials provided with the distribution.
+# 3. All advertising materials mentioning features or use of this software
+#    must display the following acknowledgement:
+#          This product includes software developed for the
+#          NetBSD Project.  See http://www.netbsd.org/ for
+#          information about NetBSD.
+# 4. The name of the author may not be used to endorse or promote products
+#    derived from this software without specific prior written permission.
+# 
+# THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS OR
+# IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
+# OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED.
+# IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT,
+# INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT
+# NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
+# DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
+# THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
+# (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF
+# THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
+# 



Home | Main Index | Thread Index | Old Index