pkgsrc-Users archive

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

Re: self bootstrap on Interix 3.5



Hi!

Self bootstrap on Interix is succeed.
Need some patches.

Please review following patches and check effect on other platforms.

1. DEFAULT_MAKESYSPATH issue (devel/bmake)

Interix have /usr/share/mk/sys.mk and it is no good for pkgsrc.
for example, 
 CC=c89

I think MAKESYSPATH should be only ${PREFIX}/share/mk.

Here is a patch.

Index: devel/bmake/files/makefile.boot.in
===================================================================
RCS file: /home/cvsroot/NetBSD/pkgsrc/devel/bmake/files/makefile.boot.in,v
retrieving revision 1.2
diff -u -r1.2 makefile.boot.in
--- devel/bmake/files/makefile.boot.in  10 Nov 2005 00:09:34 -0000      1.2
+++ devel/bmake/files/makefile.boot.in  8 Apr 2006 11:14:19 -0000
@@ -13,14 +13,13 @@
 MKDEP_OPTS=-A
 MK=${prefix}/share/mk
 MKSRC=@mksrc@
-DEFAULT_MAKESYSPATH=/usr/share/mk:/usr/local/share/mk:/opt/share/mk
 CFLAGS=-I. -I$(srcdir) @DEFS@ @CPPFLAGS@ ${XDEFS} 
-D_PATH_DEFSYSPATH=\"@default_sys_path@\"
 MDEFS="-D@force_machine@MACHINE=\"@machine@\"" 
"-DMACHINE_ARCH=\"@machine_arch@\""

 OBJ=arch.o buf.o compat.o cond.o dir.o for.o hash.o job.o main.o make.o \
     parse.o str.o suff.o targ.o trace.o var.o util.o getopt.o sigcompat.o 
@LIBOBJS@

-BMAKE_ENV= CC="$(CC)" LIBC= MAKEFLAGS= 
MAKESYSPATH=`pwd`/mk:${MKSRC}:${MK}:${DEFAULT_MAKESYSPATH}
+BMAKE_ENV= CC="$(CC)" LIBC= MAKEFLAGS= MAKESYSPATH=`pwd`/mk:${MKSRC}:${MK}

 bootstrap:     bmake.boot .mk.done
        ${BMAKE_ENV} ./bmake.boot -f Makefile
===================================================================

2. ${MAKEFILE} issue(devel/bmake)

Unit test of bmake expect ${MAKEFILE} is defined, but not defined on Interix,
so unit test is failed.

I don't know why this hack exist.
I think if it is enabled case-sensitivity for the file system,
it can distinguish b/w [Mm]akefile.

Here is a patch.

Index: devel/bmake/files/main.c
===================================================================
RCS file: /home/cvsroot/NetBSD/pkgsrc/devel/bmake/files/main.c,v
retrieving revision 1.1
diff -u -r1.1 main.c
--- devel/bmake/files/main.c    31 Oct 2005 21:34:24 -0000      1.1
+++ devel/bmake/files/main.c    8 Apr 2006 11:41:06 -0000
@@ -1136,16 +1136,7 @@
                Parse_File("(stdin)", stdin);
                Var_Set("MAKEFILE", "", VAR_GLOBAL, 0);
        } else {
-#ifdef __INTERIX
-               /*
-                * XXX Hack from tv:
-                * This system has broken filesystem support - can't
-                * always distinguish b/w [Mm]akefile.
-                */
-               setMAKEFILE = FALSE;
-#else
                setMAKEFILE = strcmp(fname, ".depend");
-#endif

                /* if we've chdir'd, rebuild the path name */
                if (strcmp(curdir, objdir) && *fname != '/') {
===================================================================

3. TAPE SUPPORT issue (archives/pax)

Interix don't support TAPE drive, so SUPPORT_TAPE isn't defeined in pax.h .
If SUPPORT_TAPE isn't defined, ISTAPE is also not defined.

but in ar_io.c line 1023-
        switch(artyp) {
#ifdef SUPPORT_RMT
        case ISRMT:
#endif /* SUPPORT_RMT */
        case ISTAPE:
#ifdef SUPPORT_TAPE
                /*

ISTAPE is undefined, so compile error occured.

I think there is no reason when SUPPORT_TAPE isn't defined, ISTAPE is also
not defined.
(and SUPPORT_RMT & ISRMT)

Here is a patch.

Index: archivers/pax/files/pax.h
===================================================================
RCS file: /home/cvsroot/NetBSD/pkgsrc/archivers/pax/files/pax.h,v
retrieving revision 1.9
diff -u -r1.9 pax.h
--- archivers/pax/files/pax.h   1 Dec 2005 03:00:01 -0000       1.9
+++ archivers/pax/files/pax.h   8 Apr 2006 12:01:41 -0000
@@ -74,13 +74,9 @@
 #define ISREG          0       /* regular file */
 #define ISCHR          1       /* character device */
 #define ISBLK          2       /* block device */
-#ifdef SUPPORT_TAPE
 #define ISTAPE         3       /* tape drive */
-#endif
 #define ISPIPE         4       /* pipe/socket */
-#ifdef SUPPORT_RMT
 #define        ISRMT           5       /* rmt */
-#endif

 /*
  * Pattern matching structure
===================================================================

--
"Of course I love NetBSD":-)
OBATA Akio / obata%lins.jp@localhost




Home | Main Index | Thread Index | Old Index