diff -c -r sim5.0/sim/kernel/makefile.SH sim5.0-linux/sim/kernel/makefile.SH *** sim5.0/sim/kernel/makefile.SH Sat Aug 16 11:16:46 1997 --- sim5.0-linux/sim/kernel/makefile.SH Sun Jun 28 10:52:16 1998 *************** *** 52,64 **** switches.o ! final: $(functionobj) $(headers) demux symtab.o: symtab.c makefile ! $(CC) $(CFLAGS) $(LIBS) $(LDFLAGS) symtab.c sim.o: sim.c ! $(CC) $(CFLAGS) -I$(INC) $(LIBS) $(LDFLAGS) $d_cckr sim.c !GROK!THIS! cat >>makefile <<'!NO!SUBS!' --- 52,64 ---- switches.o ! final: \$(functionobj) \$(headers) demux symtab.o: symtab.c makefile ! \$(CC) \$(CFLAGS) \$(LIBS) \$(LDFLAGS) symtab.c sim.o: sim.c ! \$(CC) \$(CFLAGS) -I\$(INC) \$(LIBS) \$(LDFLAGS) $d_cckr sim.c !GROK!THIS! cat >>makefile <<'!NO!SUBS!' diff -c -r sim5.0/sim/lang/makefile sim5.0-linux/sim/lang/makefile *** sim5.0/sim/lang/makefile Wed Aug 13 07:08:20 1997 --- sim5.0-linux/sim/lang/makefile Sun Jun 28 10:52:16 1998 *************** *** 1,8 **** all: y.tab.c y.tab.c : lang.yacc lex.yy.c ! yacc lang.yacc lex.yy.c : lang.lex ! lex lang.lex --- 1,15 ---- + YACC = yacc + LEX = lex -l + + all: y.tab.c y.tab.c : lang.yacc lex.yy.c ! $(YACC) lang.yacc lex.yy.c : lang.lex ! $(LEX) lang.lex ! ! clean: ! rm -f lex.yy.c y.tab.c diff -c -r sim5.0/sim/makefile sim5.0-linux/sim/makefile *** sim5.0/sim/makefile Fri Aug 15 07:46:04 1997 --- sim5.0-linux/sim/makefile Sun Jun 28 10:52:16 1998 *************** *** 113,127 **** # # use the next line for SunOS < 5 (i.e. pre-Solaris) # ! nm -g simulate | awk -f nm2.awk | cat > $(FUNC_FILE) # # use the next line for Solaris # # nm -gp -tx simulate | awk -f nm1.awk | sort | cat > $(FUNC_FILE) # ! # use the next line for IRIX and Digital Unix # ! # nm -B simulate | awk -f nm1.awk | cat > $(FUNC_FILE) chmod a+r $(FUNC_FILE) depend: --- 113,127 ---- # # use the next line for SunOS < 5 (i.e. pre-Solaris) # ! # nm -g simulate | awk -f nm2.awk | cat > $(FUNC_FILE) # # use the next line for Solaris # # nm -gp -tx simulate | awk -f nm1.awk | sort | cat > $(FUNC_FILE) # ! # use the next line for IRIX and Digital Unix or Linux # ! nm -B simulate | awk -f nm1.awk | cat > $(FUNC_FILE) chmod a+r $(FUNC_FILE) depend: diff -c -r sim5.0/src/Configure sim5.0-linux/src/Configure *** sim5.0/src/Configure Fri Aug 15 11:31:30 1997 --- sim5.0-linux/src/Configure Sun Jun 28 10:52:16 1998 *************** *** 289,300 **** EOM ! rp="Would you like this script to send mail to register you as a user?[yn]" echo $n "$rp $c" . myread case "$ans" in ! n*) echo "OK, I'll ignore it.";; ! *) echo "OK, I'm sending mail to skeshav@cs.cornell.edu..." cat < __msg__ Configuration done for REAL 5.0 on this system. --- 289,299 ---- EOM ! rp="Would you like this script to send mail to register you as a user?[ny]" echo $n "$rp $c" . myread case "$ans" in ! y*) echo "OK, I'm sending mail to skeshav@cs.cornell.edu..." cat < __msg__ Configuration done for REAL 5.0 on this system. *************** *** 312,317 **** --- 311,317 ---- rm -f __msg__ ;; + *) echo "OK, I'll ignore it.";; esac : find out where common programs are *************** *** 616,655 **** rm -f try today : see how we invoke the C preprocessor echo " " echo "Now, how can we feed standard input to your C preprocessor..." cat <<'EOT' >testcpp.c #define ABC abc ABC EOT ! echo 'Maybe "/lib/cpp" will work...' ! /lib/cpp testcpp.out 2>&1 if $contains 'abc' testcpp.out >/dev/null 2>&1 ; then ! echo "Yup, it does." ! cpp='/lib/cpp' ! cppminus=''; else ! echo 'Nope, maybe "/lib/cpp -" will work...' ! /lib/cpp - testcpp.out 2>&1 ! if $contains 'abc' testcpp.out >/dev/null 2>&1 ; then ! echo "Yup, it does." ! cpp='/lib/cpp' ! cppminus='-'; ! else ! echo 'No such luck...maybe "cc -E" will work...' cc -E testcpp.out 2>&1 if $contains 'abc' testcpp.out >/dev/null 2>&1 ; then echo "It works!" cpp='cc -E' cppminus=''; else ! echo 'Nixed again...maybe "cc -E -" will work...' ! cc -E - testcpp.out 2>&1 ! if $contains 'abc' testcpp.out >/dev/null 2>&1 ; then ! echo "Hooray, it works! I was beginning to wonder." ! cpp='cc -E' ! cppminus='-'; ! else echo 'Nope...maybe "/opts/SUNWspro/bin/cc -P" will work...' /opts/SUNWspro/bin/cc -P testcpp.out 2>&1 if $contains 'abc' testcpp.out >/dev/null 2>&1 ; then --- 616,669 ---- rm -f try today : see how we invoke the C preprocessor + : + : /* This test is too naive on linux where some system include files rely on + : architecture dependent preprocessor symbols like __i386__. If cpp is + : called directly these symbols are undefined as they are introduced at the + : cc level. The simple workaround is to reorder the tests so we check + : "cc -E -" first. */ + : echo " " echo "Now, how can we feed standard input to your C preprocessor..." cat <<'EOT' >testcpp.c #define ABC abc ABC EOT ! echo 'Maybe "cc -E -" will work...' ! cc -E - testcpp.out 2>&1 if $contains 'abc' testcpp.out >/dev/null 2>&1 ; then ! echo "It works!" ! cpp='cc -E' ! cppminus='-'; else ! echo 'Maybe "/lib/cpp" will work...' ! /lib/cpp testcpp.out 2>&1 ! if $contains 'abc' testcpp.out >/dev/null 2>&1 ; then ! echo "Yup, it does." ! cpp='/lib/cpp' ! cppminus=''; ! else ! echo 'Nope, maybe "/lib/cpp -" will work...' ! /lib/cpp - testcpp.out 2>&1 ! if $contains 'abc' testcpp.out >/dev/null 2>&1 ; then ! echo "Yup, it does." ! cpp='/lib/cpp' ! cppminus='-'; ! else ! echo 'No such luck...maybe "cc -E" will work...' cc -E testcpp.out 2>&1 if $contains 'abc' testcpp.out >/dev/null 2>&1 ; then echo "It works!" cpp='cc -E' cppminus=''; else ! # echo 'Nixed again...maybe "cc -E -" will work...' ! # cc -E - testcpp.out 2>&1 ! # if $contains 'abc' testcpp.out >/dev/null 2>&1 ; then ! # echo "Hooray, it works! I was beginning to wonder." ! # cpp='cc -E' ! # cppminus='-'; ! # else echo 'Nope...maybe "/opts/SUNWspro/bin/cc -P" will work...' /opts/SUNWspro/bin/cc -P testcpp.out 2>&1 if $contains 'abc' testcpp.out >/dev/null 2>&1 ; then diff -c -r sim5.0/src/Makefile.SH sim5.0-linux/src/Makefile.SH *** sim5.0/src/Makefile.SH Tue Jul 8 08:19:09 1997 --- sim5.0-linux/src/Makefile.SH Sun Jun 28 10:52:16 1998 *************** *** 32,38 **** LLIB = $lintlib DEFS = ! CPPFLAGS = $(DEFS) OPTFLAGS = -g -D_BSD_SIGNALS $d_cckr -c --- 32,38 ---- LLIB = $lintlib DEFS = ! CPPFLAGS = \$(DEFS) OPTFLAGS = -g -D_BSD_SIGNALS $d_cckr -c *************** *** 73,79 **** .SUFFIXES: .S .S.o: ! #$(CPP) $(CPPFLAGS) < $< | grep -v '^#' > $*.s $(AS) $(ASFLAGS) $(TARGET_ARCH) -o $@ $*.s @rm -f $*.s --- 73,79 ---- .SUFFIXES: .S .S.o: ! $(CPP) $(CPPFLAGS) < $< | grep -v '^#' > $*.s # works for linux $(AS) $(ASFLAGS) $(TARGET_ARCH) -o $@ $*.s @rm -f $*.s diff -c -r sim5.0/src/nest.h.SH sim5.0-linux/src/nest.h.SH *** sim5.0/src/nest.h.SH Thu Aug 14 06:27:49 1997 --- sim5.0-linux/src/nest.h.SH Sun Jun 28 10:52:16 1998 *************** *** 18,23 **** --- 18,27 ---- * \$Header: nest.h.SH,v 2.5 88/03/31 20:41:21 dupuy Rel $ */ + #if defined(__linux__) && defined(__ELF__) /* and defined(__RedHat5__) I wish*/ + #define _POSIX_C_SOURCE 1 + #endif + #if ($voidflags & $defvoidused) != $defvoidused #$define void int /* is void to be avoided? */ #$define M_VOID /* Xenix strikes again */