Now cpio works for me. (it was Mostly confusion about when the chroot
happened) Make vsystem crunch aware in an intelligent fashion. make the boot.flp target more specific (and faster).
This commit is contained in:
parent
455eaaa434
commit
0fefba755d
@ -1,4 +1,4 @@
|
|||||||
# $Id: Makefile,v 1.159 1995/05/20 13:49:47 jkh Exp $
|
# $Id: Makefile,v 1.160 1995/05/20 13:52:53 jkh Exp $
|
||||||
#
|
#
|
||||||
# How to roll a release:
|
# How to roll a release:
|
||||||
#
|
#
|
||||||
@ -58,6 +58,10 @@ RD= ${RELEASEDIR}/stage
|
|||||||
FD= ${RELEASEDIR}/ftp
|
FD= ${RELEASEDIR}/ftp
|
||||||
CD= ${RELEASEDIR}/cdrom
|
CD= ${RELEASEDIR}/cdrom
|
||||||
|
|
||||||
|
.if !defined(WHICH_CRUNCH)
|
||||||
|
WHICH_CRUNCH= boot cpio fixit
|
||||||
|
.endif
|
||||||
|
|
||||||
release:
|
release:
|
||||||
.if !defined(CHROOTDIR) || !defined(BUILDNAME)
|
.if !defined(CHROOTDIR) || !defined(BUILDNAME)
|
||||||
@echo "To make a release you must set CHROOTDIR and BUILDNAME" && false
|
@echo "To make a release you must set CHROOTDIR and BUILDNAME" && false
|
||||||
@ -200,12 +204,13 @@ release.4:
|
|||||||
@cd ${.CURDIR} ; $(MAKE) ckRELEASEDIR
|
@cd ${.CURDIR} ; $(MAKE) ckRELEASEDIR
|
||||||
rm -rf ${RD}/crunch
|
rm -rf ${RD}/crunch
|
||||||
mkdir -p ${RD}/crunch
|
mkdir -p ${RD}/crunch
|
||||||
for j in boot cpio fixit; do \
|
for j in ${WHICH_CRUNCH} ; do \
|
||||||
rm -rf $${j}_crunch && \
|
rm -rf $${j}_crunch && \
|
||||||
mkdir $${j}_crunch && \
|
mkdir $${j}_crunch && \
|
||||||
( cd $${j}_crunch && \
|
( cd $${j}_crunch && \
|
||||||
crunchgen ${.CURDIR}/$${j}_crunch.conf && \
|
crunchgen ${.CURDIR}/$${j}_crunch.conf && \
|
||||||
${MAKE} -f $${j}_crunch.mk objs exe NOCRYPT=yes ) && \
|
${MAKE} -f $${j}_crunch.mk objs exe NOCRYPT=yes \
|
||||||
|
"CFLAGS=${CFLAGS} -DCRUNCHED_BINARY") && \
|
||||||
mv $${j}_crunch/$${j}_crunch ${RD}/crunch/$${j} && \
|
mv $${j}_crunch/$${j}_crunch ${RD}/crunch/$${j} && \
|
||||||
rm -rf $${j}_crunch ; \
|
rm -rf $${j}_crunch ; \
|
||||||
done
|
done
|
||||||
@ -439,6 +444,10 @@ floppies:
|
|||||||
rm -f release.4 release.6 release.7 release.10
|
rm -f release.4 release.6 release.7 release.10
|
||||||
cd ${.CURDIR} && ${MAKE} doRELEASE
|
cd ${.CURDIR} && ${MAKE} doRELEASE
|
||||||
|
|
||||||
|
boot.flp:
|
||||||
|
rm -f release.4 release.6
|
||||||
|
cd ${.CURDIR} && ${MAKE} release.4 release.6 WHICH_CRUNCH=boot
|
||||||
|
|
||||||
ckRELEASEDIR:
|
ckRELEASEDIR:
|
||||||
.if !defined(RELEASEDIR)
|
.if !defined(RELEASEDIR)
|
||||||
@echo "To make a release RELEASEDIR must be defined" && false
|
@echo "To make a release RELEASEDIR must be defined" && false
|
||||||
|
@ -4,7 +4,7 @@
|
|||||||
* This is probably the last program in the `sysinstall' line - the next
|
* This is probably the last program in the `sysinstall' line - the next
|
||||||
* generation being essentially a complete rewrite.
|
* generation being essentially a complete rewrite.
|
||||||
*
|
*
|
||||||
* $Id: install.c,v 1.42 1995/05/20 19:22:20 jkh Exp $
|
* $Id: install.c,v 1.43 1995/05/20 20:30:08 jkh Exp $
|
||||||
*
|
*
|
||||||
* Copyright (c) 1995
|
* Copyright (c) 1995
|
||||||
* Jordan Hubbard. All rights reserved.
|
* Jordan Hubbard. All rights reserved.
|
||||||
@ -140,6 +140,8 @@ installInitial(void)
|
|||||||
make_filesystems();
|
make_filesystems();
|
||||||
copy_self();
|
copy_self();
|
||||||
dialog_clear();
|
dialog_clear();
|
||||||
|
chroot("/mnt");
|
||||||
|
chdir("/");
|
||||||
cpio_extract();
|
cpio_extract();
|
||||||
alreadyDone = TRUE;
|
alreadyDone = TRUE;
|
||||||
}
|
}
|
||||||
@ -272,7 +274,7 @@ copy_self(void)
|
|||||||
int i;
|
int i;
|
||||||
|
|
||||||
msgNotify("Copying the boot floppy to /stand on root filesystem");
|
msgNotify("Copying the boot floppy to /stand on root filesystem");
|
||||||
i = vsystem("find -x / | cpio -pdmv /mnt");
|
i = vsystem("find -x /stand | cpio -pdmv /mnt");
|
||||||
if (i)
|
if (i)
|
||||||
msgConfirm("Copy returned error status of %d!", i);
|
msgConfirm("Copy returned error status of %d!", i);
|
||||||
}
|
}
|
||||||
@ -292,7 +294,7 @@ cpio_extract(void)
|
|||||||
}
|
}
|
||||||
j = fork();
|
j = fork();
|
||||||
if (!j) {
|
if (!j) {
|
||||||
chroot("/mnt"); chdir("/");
|
chdir("/");
|
||||||
msgNotify("Extracting contents of CPIO floppy...");
|
msgNotify("Extracting contents of CPIO floppy...");
|
||||||
pipe(pfd);
|
pipe(pfd);
|
||||||
zpid = fork();
|
zpid = fork();
|
||||||
@ -341,14 +343,14 @@ cpio_extract(void)
|
|||||||
}
|
}
|
||||||
else
|
else
|
||||||
i = wait(&j);
|
i = wait(&j);
|
||||||
if (i < 0 || _WSTATUS(j) || access("/mnt/OK", R_OK) == -1) {
|
if (i < 0 || _WSTATUS(j) || access("/OK", R_OK) == -1) {
|
||||||
dialog_clear();
|
dialog_clear();
|
||||||
msgConfirm("CPIO floppy did not extract properly! Please verify\nthat your media is correct and try again.");
|
msgConfirm("CPIO floppy did not extract properly! Please verify\nthat your media is correct and try again.");
|
||||||
close(CpioFD);
|
close(CpioFD);
|
||||||
CpioFD = -1;
|
CpioFD = -1;
|
||||||
goto tryagain;
|
goto tryagain;
|
||||||
}
|
}
|
||||||
unlink("/mnt/OK");
|
unlink("/OK");
|
||||||
}
|
}
|
||||||
|
|
||||||
static void
|
static void
|
||||||
|
@ -276,12 +276,10 @@ systemChangeScreenmap(const u_char newmap[])
|
|||||||
dialog_clear();
|
dialog_clear();
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
#if 0
|
|
||||||
/* Execute a command that is crunched into the same binary */
|
|
||||||
int
|
int
|
||||||
vsystem(char *fmt, ...)
|
vsystem(char *fmt, ...)
|
||||||
{
|
{
|
||||||
|
#ifdef CRUNCHED_BINARY
|
||||||
va_list args;
|
va_list args;
|
||||||
union wait pstat;
|
union wait pstat;
|
||||||
pid_t pid;
|
pid_t pid;
|
||||||
@ -329,12 +327,7 @@ vsystem(char *fmt, ...)
|
|||||||
msgDebug("Command `%s' returns status of %d\n", cmd, i);
|
msgDebug("Command `%s' returns status of %d\n", cmd, i);
|
||||||
free(cmd);
|
free(cmd);
|
||||||
return i;
|
return i;
|
||||||
}
|
#else /* Not crunched */
|
||||||
#else
|
|
||||||
/* Execute a system command, with varargs */
|
|
||||||
int
|
|
||||||
vsystem(char *fmt, ...)
|
|
||||||
{
|
|
||||||
va_list args;
|
va_list args;
|
||||||
union wait pstat;
|
union wait pstat;
|
||||||
pid_t pid;
|
pid_t pid;
|
||||||
@ -377,5 +370,5 @@ vsystem(char *fmt, ...)
|
|||||||
msgDebug("Command `%s' returns status of %d\n", cmd, i);
|
msgDebug("Command `%s' returns status of %d\n", cmd, i);
|
||||||
free(cmd);
|
free(cmd);
|
||||||
return i;
|
return i;
|
||||||
}
|
|
||||||
#endif
|
#endif
|
||||||
|
}
|
||||||
|
@ -4,7 +4,7 @@
|
|||||||
* This is probably the last program in the `sysinstall' line - the next
|
* This is probably the last program in the `sysinstall' line - the next
|
||||||
* generation being essentially a complete rewrite.
|
* generation being essentially a complete rewrite.
|
||||||
*
|
*
|
||||||
* $Id: install.c,v 1.42 1995/05/20 19:22:20 jkh Exp $
|
* $Id: install.c,v 1.43 1995/05/20 20:30:08 jkh Exp $
|
||||||
*
|
*
|
||||||
* Copyright (c) 1995
|
* Copyright (c) 1995
|
||||||
* Jordan Hubbard. All rights reserved.
|
* Jordan Hubbard. All rights reserved.
|
||||||
@ -140,6 +140,8 @@ installInitial(void)
|
|||||||
make_filesystems();
|
make_filesystems();
|
||||||
copy_self();
|
copy_self();
|
||||||
dialog_clear();
|
dialog_clear();
|
||||||
|
chroot("/mnt");
|
||||||
|
chdir("/");
|
||||||
cpio_extract();
|
cpio_extract();
|
||||||
alreadyDone = TRUE;
|
alreadyDone = TRUE;
|
||||||
}
|
}
|
||||||
@ -272,7 +274,7 @@ copy_self(void)
|
|||||||
int i;
|
int i;
|
||||||
|
|
||||||
msgNotify("Copying the boot floppy to /stand on root filesystem");
|
msgNotify("Copying the boot floppy to /stand on root filesystem");
|
||||||
i = vsystem("find -x / | cpio -pdmv /mnt");
|
i = vsystem("find -x /stand | cpio -pdmv /mnt");
|
||||||
if (i)
|
if (i)
|
||||||
msgConfirm("Copy returned error status of %d!", i);
|
msgConfirm("Copy returned error status of %d!", i);
|
||||||
}
|
}
|
||||||
@ -292,7 +294,7 @@ cpio_extract(void)
|
|||||||
}
|
}
|
||||||
j = fork();
|
j = fork();
|
||||||
if (!j) {
|
if (!j) {
|
||||||
chroot("/mnt"); chdir("/");
|
chdir("/");
|
||||||
msgNotify("Extracting contents of CPIO floppy...");
|
msgNotify("Extracting contents of CPIO floppy...");
|
||||||
pipe(pfd);
|
pipe(pfd);
|
||||||
zpid = fork();
|
zpid = fork();
|
||||||
@ -341,14 +343,14 @@ cpio_extract(void)
|
|||||||
}
|
}
|
||||||
else
|
else
|
||||||
i = wait(&j);
|
i = wait(&j);
|
||||||
if (i < 0 || _WSTATUS(j) || access("/mnt/OK", R_OK) == -1) {
|
if (i < 0 || _WSTATUS(j) || access("/OK", R_OK) == -1) {
|
||||||
dialog_clear();
|
dialog_clear();
|
||||||
msgConfirm("CPIO floppy did not extract properly! Please verify\nthat your media is correct and try again.");
|
msgConfirm("CPIO floppy did not extract properly! Please verify\nthat your media is correct and try again.");
|
||||||
close(CpioFD);
|
close(CpioFD);
|
||||||
CpioFD = -1;
|
CpioFD = -1;
|
||||||
goto tryagain;
|
goto tryagain;
|
||||||
}
|
}
|
||||||
unlink("/mnt/OK");
|
unlink("/OK");
|
||||||
}
|
}
|
||||||
|
|
||||||
static void
|
static void
|
||||||
|
@ -276,12 +276,10 @@ systemChangeScreenmap(const u_char newmap[])
|
|||||||
dialog_clear();
|
dialog_clear();
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
#if 0
|
|
||||||
/* Execute a command that is crunched into the same binary */
|
|
||||||
int
|
int
|
||||||
vsystem(char *fmt, ...)
|
vsystem(char *fmt, ...)
|
||||||
{
|
{
|
||||||
|
#ifdef CRUNCHED_BINARY
|
||||||
va_list args;
|
va_list args;
|
||||||
union wait pstat;
|
union wait pstat;
|
||||||
pid_t pid;
|
pid_t pid;
|
||||||
@ -329,12 +327,7 @@ vsystem(char *fmt, ...)
|
|||||||
msgDebug("Command `%s' returns status of %d\n", cmd, i);
|
msgDebug("Command `%s' returns status of %d\n", cmd, i);
|
||||||
free(cmd);
|
free(cmd);
|
||||||
return i;
|
return i;
|
||||||
}
|
#else /* Not crunched */
|
||||||
#else
|
|
||||||
/* Execute a system command, with varargs */
|
|
||||||
int
|
|
||||||
vsystem(char *fmt, ...)
|
|
||||||
{
|
|
||||||
va_list args;
|
va_list args;
|
||||||
union wait pstat;
|
union wait pstat;
|
||||||
pid_t pid;
|
pid_t pid;
|
||||||
@ -377,5 +370,5 @@ vsystem(char *fmt, ...)
|
|||||||
msgDebug("Command `%s' returns status of %d\n", cmd, i);
|
msgDebug("Command `%s' returns status of %d\n", cmd, i);
|
||||||
free(cmd);
|
free(cmd);
|
||||||
return i;
|
return i;
|
||||||
}
|
|
||||||
#endif
|
#endif
|
||||||
|
}
|
||||||
|
@ -4,7 +4,7 @@
|
|||||||
* This is probably the last program in the `sysinstall' line - the next
|
* This is probably the last program in the `sysinstall' line - the next
|
||||||
* generation being essentially a complete rewrite.
|
* generation being essentially a complete rewrite.
|
||||||
*
|
*
|
||||||
* $Id: install.c,v 1.42 1995/05/20 19:22:20 jkh Exp $
|
* $Id: install.c,v 1.43 1995/05/20 20:30:08 jkh Exp $
|
||||||
*
|
*
|
||||||
* Copyright (c) 1995
|
* Copyright (c) 1995
|
||||||
* Jordan Hubbard. All rights reserved.
|
* Jordan Hubbard. All rights reserved.
|
||||||
@ -140,6 +140,8 @@ installInitial(void)
|
|||||||
make_filesystems();
|
make_filesystems();
|
||||||
copy_self();
|
copy_self();
|
||||||
dialog_clear();
|
dialog_clear();
|
||||||
|
chroot("/mnt");
|
||||||
|
chdir("/");
|
||||||
cpio_extract();
|
cpio_extract();
|
||||||
alreadyDone = TRUE;
|
alreadyDone = TRUE;
|
||||||
}
|
}
|
||||||
@ -272,7 +274,7 @@ copy_self(void)
|
|||||||
int i;
|
int i;
|
||||||
|
|
||||||
msgNotify("Copying the boot floppy to /stand on root filesystem");
|
msgNotify("Copying the boot floppy to /stand on root filesystem");
|
||||||
i = vsystem("find -x / | cpio -pdmv /mnt");
|
i = vsystem("find -x /stand | cpio -pdmv /mnt");
|
||||||
if (i)
|
if (i)
|
||||||
msgConfirm("Copy returned error status of %d!", i);
|
msgConfirm("Copy returned error status of %d!", i);
|
||||||
}
|
}
|
||||||
@ -292,7 +294,7 @@ cpio_extract(void)
|
|||||||
}
|
}
|
||||||
j = fork();
|
j = fork();
|
||||||
if (!j) {
|
if (!j) {
|
||||||
chroot("/mnt"); chdir("/");
|
chdir("/");
|
||||||
msgNotify("Extracting contents of CPIO floppy...");
|
msgNotify("Extracting contents of CPIO floppy...");
|
||||||
pipe(pfd);
|
pipe(pfd);
|
||||||
zpid = fork();
|
zpid = fork();
|
||||||
@ -341,14 +343,14 @@ cpio_extract(void)
|
|||||||
}
|
}
|
||||||
else
|
else
|
||||||
i = wait(&j);
|
i = wait(&j);
|
||||||
if (i < 0 || _WSTATUS(j) || access("/mnt/OK", R_OK) == -1) {
|
if (i < 0 || _WSTATUS(j) || access("/OK", R_OK) == -1) {
|
||||||
dialog_clear();
|
dialog_clear();
|
||||||
msgConfirm("CPIO floppy did not extract properly! Please verify\nthat your media is correct and try again.");
|
msgConfirm("CPIO floppy did not extract properly! Please verify\nthat your media is correct and try again.");
|
||||||
close(CpioFD);
|
close(CpioFD);
|
||||||
CpioFD = -1;
|
CpioFD = -1;
|
||||||
goto tryagain;
|
goto tryagain;
|
||||||
}
|
}
|
||||||
unlink("/mnt/OK");
|
unlink("/OK");
|
||||||
}
|
}
|
||||||
|
|
||||||
static void
|
static void
|
||||||
|
@ -276,12 +276,10 @@ systemChangeScreenmap(const u_char newmap[])
|
|||||||
dialog_clear();
|
dialog_clear();
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
#if 0
|
|
||||||
/* Execute a command that is crunched into the same binary */
|
|
||||||
int
|
int
|
||||||
vsystem(char *fmt, ...)
|
vsystem(char *fmt, ...)
|
||||||
{
|
{
|
||||||
|
#ifdef CRUNCHED_BINARY
|
||||||
va_list args;
|
va_list args;
|
||||||
union wait pstat;
|
union wait pstat;
|
||||||
pid_t pid;
|
pid_t pid;
|
||||||
@ -329,12 +327,7 @@ vsystem(char *fmt, ...)
|
|||||||
msgDebug("Command `%s' returns status of %d\n", cmd, i);
|
msgDebug("Command `%s' returns status of %d\n", cmd, i);
|
||||||
free(cmd);
|
free(cmd);
|
||||||
return i;
|
return i;
|
||||||
}
|
#else /* Not crunched */
|
||||||
#else
|
|
||||||
/* Execute a system command, with varargs */
|
|
||||||
int
|
|
||||||
vsystem(char *fmt, ...)
|
|
||||||
{
|
|
||||||
va_list args;
|
va_list args;
|
||||||
union wait pstat;
|
union wait pstat;
|
||||||
pid_t pid;
|
pid_t pid;
|
||||||
@ -377,5 +370,5 @@ vsystem(char *fmt, ...)
|
|||||||
msgDebug("Command `%s' returns status of %d\n", cmd, i);
|
msgDebug("Command `%s' returns status of %d\n", cmd, i);
|
||||||
free(cmd);
|
free(cmd);
|
||||||
return i;
|
return i;
|
||||||
}
|
|
||||||
#endif
|
#endif
|
||||||
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user