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

apparent problem in building AKCL under Sun OS 4.1 on Sparcstation 1+



I can't make it work, but I'm not too experienced with C and Unix, so
i may be doing something wrong.


SHORT STORY

The symptom when trying to build kcl is
  ld: ../lsp/defmacro.o: bad secondary magic number
  *** Error code 4
  make: Fatal error: Command failed for target `raw_kcl1'
  Current working directory /usr1/local/akcl-1-470/unixport


CONJECTURE

A friend who is more knowledgeable figures that under 4.1 Sun has
started putting some information at the end of .o files to be used in
linking (called the "magic" info by Sun).  Apparently KCL also stores
stuff in that position, and there is now a colision. Page 25 of the 4.1
release notes says programs will have trouble if they "depend on the
object file format in a way that can be confused by extra information
now appearing at the end of some object files.."

Actually, the opposite is happening, where kcl appends extra stuff to the
end of an object file:
	cat  defmacro.data >> defmacro.o
and then Sun ld gets confused:
	ld: ../lsp/defmacro.o: bad secondary magic number


Has anybody else noticed this problem?

tnx, f


************ find more info from end of the build attempt  **********

...

(cd unixport; make saved_kcl)
if  fgrep ASSIGN-DOWN ../cmpnew/cmpvar.c > /dev/null ; \
	then make raw_kcl1 "KCL=kcl" "ODIR=../o" "EXTRAS=" "LIBS=-lm -lg" "LDCC=cc -DVOL=  -I/usr1/local/akcl-1-470/o -Bstatic -temp=." ; \
	else make raw_kcl1 "SYS_KCL=sys_boot.o" ; fi 
cc -DVOL=  -I/usr1/local/akcl-1-470/o -Bstatic -temp=. -c   -I../h sys_kcl.c

/o/gbc.o  ../o/bitop.o ../o/typespec.o ../o/eval.o  ../o/macros.o ../malex.o ../o/bds.o  ../o/frame.o ../o/predicate.o ../o/reference.o  ../o/assignment.o ../o/bind.o ../o/let.o  ../o/conditional.o ../o/block.o ../o/iteration.o  ../o/mapfun.o ../o/prog.o ../o/multival.o  ../o/catch.o ../o/symbol.o ../o/cfun.o  ../o/cmpaux.o o  ../o/number.o ../o/num_pred.o ../o/num_comp.o  ../o/num_arith.o ../o/num_sfun.o ../o/num_co.o  ../o/num_log.o ../o/num_rand.o ../o/earith.o  ../o/character.o  ../o/sequence.o  ../o/list.o ../o/hash.o ../o/array.o  ../o/string.o ../o/structure.o ../o/toplevel.o  ../o/file.o ../o/read.o ../o/backq.o  ../o/rm -f raw_kcl 
e.o ../cmpnew/cmputil.o ../cmpnew/cmptype.o  ../cmpnew/cmpbind.o ../cmpnew/cmpblock.o ../cmpnew/cmpcall.o  ../cmpnew/cmpcatch.o ../cmpnew/cmpenv.o ../cmpnew/cmpeval.o  ../cmpnew/cmpflet.o ../cmpnew/cmpfun.o ../cmpnew/cmpif.o  ../cmpnew/cmplabel.o ../cmpnew/cmplam.o ../cmpnew/cmplet.o  ../cmpnew/cmploc.o ../cmpnew/cmpmap.o ../cmpnew/cmpmulti.o  ../cmpnew/cmpspecial.o ../cmpnew/cmptag.o ../cmpnew/cmptop.o  ../cmpnew/cmpvar.o ../cmpnew/cmpvs.o ../cmpnew/cmpwt.o sys_kcl.o -lc -lm -lg ../o/akcllib.a
 [i left out some of the .o files in this part]

ld: ../lsp/defmacro.o: bad secondary magic number
*** Error code 4
make: Fatal error: Command failed for target `raw_kcl1'
Current working directory /usr1/local/akcl-1-470/unixport
*** Error code 1 (ignored)
../xbin/if-exists //schelter "../xbin/inc-version"
../xbin/if-exists saved_kcl "rm -f saved_kcl"
cat init_kcl.lsp | \
sed -e "sVersion(`cat ../majvers`.`cat ../minvers`) ` \
-e 'saved_ksa' \
-e 'slinks t)(setq compiler::*cc* "cc -DVOL=  -I/usr1/local/akcl-1-470/o -Bstatic -temp=.")(si::build-symbol-table)'| \
./raw_kcl ../unixport/ 
sh: ./raw_kcl: not found
*** Error code 1
make: Fatal error: Command failed for target `saved_kcl'
Current working directory /usr1/local/akcl-1-470/unixport
*** Error code 1
make: Fatal error: Command failed for target `all'
Current working directory /usr1/local/akcl-1-470
*** Error code 1
make: Fatal error: Command failed for target `all'
/usr1/local/akcl-1-470>#