Re: Not able to compile GENERIC kernel

2009-09-25 Thread mfv
On Sunday, 20 September 2009 12:55:44 Giorgos Keramidas wrote:
 On Sun, 20 Sep 2009 11:15:15 -0400, mfv mrk...@acm.org wrote:
  Hello,
 
  After rebuilding FreeBSD for many years I am not able to build a
  GENERIC kernel for the last few days.  It always stops when
  compiling acpi.
 
  The source code is up to date for 7 -STABLE for i386 on a amd64
  cpu. I have always been able to recompile a GENERIC kernel since
  release 5.1 and do not know what I am doing wrong.
 
  Any help would be greatly appreciated.
 
  With thanks.
 
  Marek
 
  The following is the tail end of make buildkernel:
 
  cc -O2 -fno-strict-aliasing -pipe -D_KERNEL -DKLD_MODULE -std=c99 -
  nostdinc -I
  /usr/src/sys/modules/acpi/acpi/../../../contrib/dev/acpica
  -DHAVE_KERNEL_OPTION_ HEADERS -include
  /usr/obj/usr/src/sys/GENERIC/opt_global.h -I. -I@ -I@/contrib/a ltq
  -finline-limit=8000 --param inline-unit-growth=100 --param large-
  function-growth=1000 -fno-common -g -I/usr/obj/usr/src/sys/GENERIC
  -mno-align-long-strings -mpreferred-stack-boundary=2 -mno-mmx
  -mno-3dnow -mno-sse -mno-sse2 -mno-sse3 - ffreestanding -Wall
  -Wredundant-decls -Wnested-externs -Wstrict-prototypes -Wmi
  ssing-prototypes -Wpointer- arith -Winline -Wcast-qual -Wundef
  -Wno-pointer-sign -fformat-extensions -c
  /usr/src/sys/modules/acpi/acpi/../../../i386/acpica/acpi _machdep.c
  @ -/usr/src/sys
  ln: @/sys: Operation not permitted
  *** Error code 1
 
 Can you wipe our /usr/obj and start with a clean object tree?  You
  may also have stale build artifacts in /usr/src so something like
  this might be a good idea:
 
 # rm -fr /usr/obj/usr
 # cd /usr/src
 # make cleandir ; make cleandir
 

Thanks to all for your comments and insights.

I was finally able to compile a GENERIC kernel by performing radical 
surgery:

   1. cd /usr/src/sys
   2. rm -r *
   3. Update source tree using csup
   4. cd /usr/src
   5. make cleanworld
   6. make buildkernel

I did this over three days.  On the third day it finally worked.  My 
suspicion is that for some reason my source code was scrambled.

Thanks again for your comments.  Using them as a starting point I 
discovered cleanworld and have a better understanding of the compile 
process.

Cheers...

Marek
___
freebsd-questions@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to freebsd-questions-unsubscr...@freebsd.org


Not able to compile GENERIC kernel

2009-09-20 Thread mfv
Hello,

After rebuilding FreeBSD for many years I am not able to build a GENERIC 
kernel for the last few days.   It always stops when compiling acpi.

The source code is up to date for 7 -STABLE for i386 on a amd64 cpu.  I 
have always been able to recompile a GENERIC kernel since release 5.1 
and do not know what I am doing wrong.

Any help would be greatly appreciated.

With thanks.

Marek

The following is the tail end of make buildkernel:

cc -O2 -fno-strict-aliasing -pipe -D_KERNEL -DKLD_MODULE -std=c99 -
nostdinc -I /usr/src/sys/modules/acpi/acpi/../../../contrib/dev/acpica
-DHAVE_KERNEL_OPTION_ HEADERS -include
/usr/obj/usr/src/sys/GENERIC/opt_global.h -I. -I@ -I@/contrib/a ltq
-finline-limit=8000 --param inline-unit-growth=100 --param large-
function-growth=1000 -fno-common -g -I/usr/obj/usr/src/sys/GENERIC
-mno-align-long-strings -mpreferred-stack-boundary=2 -mno-mmx -mno-3dnow
-mno-sse -mno-sse2 -mno-sse3 - ffreestanding -Wall -Wredundant-decls
-Wnested-externs -Wstrict-prototypes -Wmi ssing-prototypes -Wpointer-
arith -Winline -Wcast-qual -Wundef -Wno-pointer-sign -fformat-extensions 
-c /usr/src/sys/modules/acpi/acpi/../../../i386/acpica/acpi _machdep.c
@ -/usr/src/sys
ln: @/sys: Operation not permitted
*** Error code 1

Stop in /usr/src/sys/modules/acpi/acpi.
*** Error code 1

Stop in /usr/src/sys/modules/acpi.
*** Error code 1

Stop in /usr/src/sys/modules.
*** Error code 1

Stop in /usr/obj/usr/src/sys/GENERIC.
*** Error code 1

Stop in /usr/src.
*** Error code 1

Stop in /usr/src.

[root] /usr/src #
___
freebsd-questions@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to freebsd-questions-unsubscr...@freebsd.org


Re: Not able to compile GENERIC kernel

2009-09-20 Thread Giorgos Keramidas
On Sun, 20 Sep 2009 11:15:15 -0400, mfv mrk...@acm.org wrote:
 Hello,

 After rebuilding FreeBSD for many years I am not able to build a
 GENERIC kernel for the last few days.  It always stops when compiling
 acpi.

 The source code is up to date for 7 -STABLE for i386 on a amd64 cpu.
 I have always been able to recompile a GENERIC kernel since release
 5.1 and do not know what I am doing wrong.

 Any help would be greatly appreciated.

 With thanks.

 Marek

 The following is the tail end of make buildkernel:

 cc -O2 -fno-strict-aliasing -pipe -D_KERNEL -DKLD_MODULE -std=c99 -
 nostdinc -I /usr/src/sys/modules/acpi/acpi/../../../contrib/dev/acpica
 -DHAVE_KERNEL_OPTION_ HEADERS -include
 /usr/obj/usr/src/sys/GENERIC/opt_global.h -I. -I@ -I@/contrib/a ltq
 -finline-limit=8000 --param inline-unit-growth=100 --param large-
 function-growth=1000 -fno-common -g -I/usr/obj/usr/src/sys/GENERIC
 -mno-align-long-strings -mpreferred-stack-boundary=2 -mno-mmx -mno-3dnow
 -mno-sse -mno-sse2 -mno-sse3 - ffreestanding -Wall -Wredundant-decls
 -Wnested-externs -Wstrict-prototypes -Wmi ssing-prototypes -Wpointer-
 arith -Winline -Wcast-qual -Wundef -Wno-pointer-sign -fformat-extensions
 -c /usr/src/sys/modules/acpi/acpi/../../../i386/acpica/acpi _machdep.c
 @ -/usr/src/sys
 ln: @/sys: Operation not permitted
 *** Error code 1

Can you wipe our /usr/obj and start with a clean object tree?  You may
also have stale build artifacts in /usr/src so something like this might
be a good idea:

# rm -fr /usr/obj/usr
# cd /usr/src
# make cleandir ; make cleandir

___
freebsd-questions@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to freebsd-questions-unsubscr...@freebsd.org


Re: Not able to compile GENERIC kernel

2009-09-20 Thread Christer Solskogen

Giorgos Keramidas wrote:


# rm -fr /usr/obj/usr
# cd /usr/src
# make cleandir ; make cleandir



I've seen serveral placeses that make cleandir should be run twice. I 
dont understand why. Could somebody explain?


--
chs

___
freebsd-questions@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to freebsd-questions-unsubscr...@freebsd.org


Re: Not able to compile GENERIC kernel

2009-09-20 Thread Giorgos Keramidas
On Sun, 20 Sep 2009 21:10:00 +0200, Christer Solskogen 
christer.solsko...@gmail.com wrote:
 Giorgos Keramidas wrote:

 # rm -fr /usr/obj/usr
 # cd /usr/src
 # make cleandir ; make cleandir


 I've seen serveral placeses that make cleandir should be run twice. I
 dont understand why. Could somebody explain?

The first run cleans file sunder $(MAKEOBJDIRPREFIX), or under
`/usr/obj' if MAKEOBJDIRPREFIX is unset.

The second run cleans files in the source tree itself.

___
freebsd-questions@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to freebsd-questions-unsubscr...@freebsd.org


Re: Not able to compile GENERIC kernel

2009-09-20 Thread Mel Flynn
On Sunday 20 September 2009 23:26:58 Giorgos Keramidas wrote:
 On Sun, 20 Sep 2009 21:10:00 +0200, Christer Solskogen 
christer.solsko...@gmail.com wrote:
  Giorgos Keramidas wrote:
  # rm -fr /usr/obj/usr
  # cd /usr/src
  # make cleandir ; make cleandir
 
  I've seen serveral placeses that make cleandir should be run twice. I
  dont understand why. Could somebody explain?
 
 The first run cleans file sunder $(MAKEOBJDIRPREFIX), or under
 `/usr/obj' if MAKEOBJDIRPREFIX is unset.
 
 The second run cleans files in the source tree itself.

Which you'll see if you don't use the designated build{world|kernel} targets, 
but cd into a directory and start typing make orquite the pitfall, run 
make obj depend, rather then make obj  make depend. In the first case, the 
.depend file ends up in .CURDIR, not .OBJDIR.

Also, perhaps it's better to advise make cleanworld for the rm -rf, as this 
target accomplishes the same, deals better with chflags(2) and leaves 
/usr/obj/usr/ports in tact for those who have set WRKDIRPREFIX to /usr/obj for 
ports.
-- 
Mel
___
freebsd-questions@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to freebsd-questions-unsubscr...@freebsd.org


Re: Not able to compile GENERIC kernel

2009-09-20 Thread Giorgos Keramidas
On Mon, 21 Sep 2009 03:46:13 +0200, Mel Flynn 
mel.flynn+fbsd.questi...@mailing.thruhere.net wrote:
 On Sunday 20 September 2009 23:26:58 Giorgos Keramidas wrote:
 On Sun, 20 Sep 2009 21:10:00 +0200, Christer Solskogen 
 christer.solsko...@gmail.com wrote:
  Giorgos Keramidas wrote:
  # rm -fr /usr/obj/usr
  # cd /usr/src
  # make cleandir ; make cleandir
 
  I've seen serveral placeses that make cleandir should be run twice. I
  dont understand why. Could somebody explain?

 The first run cleans file sunder $(MAKEOBJDIRPREFIX), or under
 `/usr/obj' if MAKEOBJDIRPREFIX is unset.

 The second run cleans files in the source tree itself.

 Which you'll see if you don't use the designated build{world|kernel} targets,
 but cd into a directory and start typing make orquite the pitfall, run
 make obj depend, rather then make obj  make depend. In the first case, the
 .depend file ends up in .CURDIR, not .OBJDIR.

 Also, perhaps it's better to advise make cleanworld for the rm -rf, as this
 target accomplishes the same, deals better with chflags(2) and leaves
 /usr/obj/usr/ports in tact for those who have set WRKDIRPREFIX to /usr/obj for
 ports.

That's a good point.  Thanks.  I'll remember it the next time I suggest
that someone wipes their entire `/usr/obj' tree :)

___
freebsd-questions@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to freebsd-questions-unsubscr...@freebsd.org