Date: Sun, 26 Nov 1995 17:45:51 +1100 From: Bruce Evans <bde@zeta.org.au> To: current@FreeBSD.ORG, scrappy@hub.org Subject: Re: Problem making /usr/src... Message-ID: <199511260645.RAA19202@godzilla.zeta.org.au>
next in thread | raw e-mail | index | archive | help
>Hi... > Has anyone noticed/fixed this: >===> bin/sh >cc -O -DSHELL -I. -I/usr/src/bin/sh -static /usr/src/bin/sh/builtins.c -o /usr/src/bin/sh/builtins >/usr/lib/crt0.o: Undefined symbol `_main' referenced from text segment >/var/tmp/cc0217011.o: Undefined symbol `_bltincmd' referenced from text segment >... It's because there is a bogus implicit dependency of the source file `builtins' on the created file builtins.c. The first run creates builtins.c and the second run tries to create `builtins' from builtins.c using `cc -o builtins builtins.c ...'. This fails because builtins.c is one of the sources for `sh', not for `builtins'. The problem doesn't occur if you have an obj directory. > Oh, something to note, in case it gets asked. This is going through >the 'make' steps that Bruce outlined yesterday, with the 2.2-Current >kernel running, and /usr/src/lib installed...I'm just trying to make >the *bin stuff now I forgot to mention (:-): # create obj directories as required # # create them all at first, or in case you missed one cd /usr/src make obj # # or a few at a time cd /usr/src/foobin make obj # # or one at a time cd /usr/src/foobin/barprog make obj Missing obj directories and can be found by mounting /usr/src readonly after creating most obj directories (this also finds buggy makefiles) or by searching for .o's and .depend's in /usr/src (`make obj' unfortunately always creates all obj directories whether necessary or not). Bruce
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?199511260645.RAA19202>