Is it safe to interrupt (Ctrl + C) while building a port or kernel?

2011-11-03 Thread Антон Клесс
Sometimes, while building process of some port or system kernel are in 
progress, you suddenly remember that you did something wrong and have to stop, 
solve your mistake and start one more time.

Is it clear to interrupt the building process just by pressing Ctrl + C?

If it's so, do I need to run make clean before I start make one more time?


Thank you!
___
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: Is it safe to interrupt (Ctrl + C) while building a port or kernel?

2011-11-03 Thread Robert Bonomi
 From owner-freebsd-questi...@freebsd.org  Thu Nov  3 12:10:08 2011
 From: =?koi8-r?B?4c7Uz84g68zF09M=?= rc5h...@yandex.ru
 To: freebsd-questions@freebsd.org
 Date: Thu, 03 Nov 2011 21:10:19 +0400
 Subject: Is it safe to interrupt (Ctrl + C) while building a port or kernel?

 Sometimes, while building process of some port or system kernel are in 
 progress, you suddenly remember that you did something wrong and have to 
 stop, solve your mistake and start one more time.

 Is it clear to interrupt the building process just by pressing Ctrl + C?

Yes.

 If it's so, do I need to run make clean before I start make one more time?

Authoritative answer:  It depends.

On what you 'did wrong, and what it takes to fix it.

e.g.,  if you're building a kernel the 'classial' way, that is 'configure,
make depend, cd , make',  and realize you left something out of the config
file, after you edit the config file, you have to rerun _all_ those steps.

___
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: Is it safe to interrupt (Ctrl + C) while building a port or kernel?

2011-11-03 Thread Damien Fleuriot


On 11/3/11 6:20 PM, Robert Bonomi wrote:
 From owner-freebsd-questi...@freebsd.org  Thu Nov  3 12:10:08 2011
 From: =?koi8-r?B?4c7Uz84g68zF09M=?= rc5h...@yandex.ru
 To: freebsd-questions@freebsd.org
 Date: Thu, 03 Nov 2011 21:10:19 +0400
 Subject: Is it safe to interrupt (Ctrl + C) while building a port or kernel?

 Sometimes, while building process of some port or system kernel are in 
 progress, you suddenly remember that you did something wrong and have to 
 stop, solve your mistake and start one more time.

 Is it clear to interrupt the building process just by pressing Ctrl + C?
 
 Yes.
 
 If it's so, do I need to run make clean before I start make one more 
 time?
 
 Authoritative answer:  It depends.
 
 On what you 'did wrong, and what it takes to fix it.
 
 e.g.,  if you're building a kernel the 'classial' way, that is 'configure,
 make depend, cd , make',  and realize you left something out of the config
 file, after you edit the config file, you have to rerun _all_ those steps.
 

Is it even advisable to build the kernel the old way ?

I feel safer with cd /usr/src  make buildkernel
___
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: Is it safe to interrupt (Ctrl + C) while building a port or kernel?

2011-11-03 Thread Антон Клесс
03.11.2011, 21:20, Robert Bonomi bon...@mail.r-bonomi.com:

   If it's so, do I need to run make clean before I start make one more 
 time?
  Authoritative answer:  It depends.

  On what you 'did wrong, and what it takes to fix it.

  e.g.,  if you're building a kernel the 'classial' way, that is 'configure,
  make depend, cd , make',  and realize you left something out of the config
  file, after you edit the config file, you have to rerun _all_ those steps.

Does it matter, if I always use make buildkernel make installkernel way to 
rebuild kernels?

  make buildkernel

..
oh! something wrong!
Ctrl + C
..
mistake fixed!

  make buildkernel
  make installkernel

- is right?
___
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: Is it safe to interrupt (Ctrl + C) while building a port or kernel?

2011-11-03 Thread Robert Bonomi

On Thu, 03 Nov 2011 18:29:06 +0100, Damien Fleuriot m...@my.gd) wrote:
 On 11/3/11 6:20 PM, Robert Bonomi wrote:
  From owner-freebsd-questi...@freebsd.org  Thu Nov  3 12:10:08 2011
  From: =?koi8-r?B?4c7Uz84g68zF09M=?= rc5h...@yandex.ru
  To: freebsd-questions@freebsd.org
  Date: Thu, 03 Nov 2011 21:10:19 +0400
  Subject: Is it safe to interrupt (Ctrl + C) while building a port or 
  kernel?
 
  Sometimes, while building process of some port or system kernel are in 
  progress, you suddenly remember that you did something wrong and have to 
  stop, solve your mistake and start one more time.
 
  Is it clear to interrupt the building process just by pressing Ctrl + C?
  
  Yes.
  
  If it's so, do I need to run make clean before I start make one more 
  time?
  
  Authoritative answer:  It depends.
  
  On what you 'did wrong, and what it takes to fix it.
  
  e.g.,  if you're building a kernel the 'classial' way, that is 'configure,
  make depend, cd , make',  and realize you left something out of the config
  file, after you edit the config file, you have to rerun _all_ those steps.
  

 Is it even advisable to build the kernel the old way ?

On a slow processor, it makes a *BIG* differnence.
Even more so if you build everything you need into the kernel.

'make buildkernel' always recompiles an relinks *everything*. whether or
not any dependenies for the module have changed.

I've tried 'make buildkernel' on a 'loaded' 486 box, and had it take
close to TWENTY FOUR HOURS to complete.  With one minor tweak to the
config file, e.g. changing one of the 'shared memory' constants,  and
it is _another_ 24+ hours.  *Lots* of it building loadable modules that
I have no need for, nor any intention of ever useing.

Using the 'old' way, a first-time kernel build was under 40 minutes, and
a 'tweak' re-build was under 15.

That box is long gone, but on a 733mhz PIII I can go from editing a config
file to running on the new kernel in less than 5 minutes (wall clock).  The 
largest part of that time is running 'make depend'. (Second-largest is the
rebooting. :)

I don't know about anybody else, but _I_ consider that speed differential
a *big* advantage to the 'old way'. :)

I am likely _not_ the typical user -- I run a monolithic kernel, with 
everything I need 'compiled in'; *no* loadable modules.  Yeah, it can
be a nuisance if I need something that isn't compiled in, but I don't
get ny unexpected surprises.  It also does wonders as far as reducing
the required 'root partition' size.  I run a 64mb(!!) partition, with
less than 1/2 of it occupied by the system install.  With the running
kernel, a copy of the prior running one as a fall-back, and a GENERIC
for worst-case recovery.
___
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: Is it safe to interrupt (Ctrl + C) while building a port or kernel?

2011-11-03 Thread Warren Block

On Thu, 3 Nov 2011, ? ? wrote:


Is it clear to interrupt the building process just by pressing Ctrl + C?

If it's so, do I need to run make clean before I start make one more time?


With ports, a make clean before rebuilding is a good idea.  The build 
might not be able to continue cleanly, or might have to build 
differently, depending on what was changed.


For /usr/src, I just remove /usr/obj/usr and build again, but also use 
devel/ccache so there's not much penalty for doing that.

___
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: Is it safe to interrupt (Ctrl + C) while building a port or kernel?

2011-11-03 Thread Erik Trulsson
On Thu, Nov 03, 2011 at 01:48:47PM -0500, Robert Bonomi wrote:
 
 On Thu, 03 Nov 2011 18:29:06 +0100, Damien Fleuriot m...@my.gd) wrote:
  On 11/3/11 6:20 PM, Robert Bonomi wrote:
   From owner-freebsd-questi...@freebsd.org  Thu Nov  3 12:10:08 2011
   From: =?koi8-r?B?4c7Uz84g68zF09M=?= rc5h...@yandex.ru
   To: freebsd-questions@freebsd.org
   Date: Thu, 03 Nov 2011 21:10:19 +0400
   Subject: Is it safe to interrupt (Ctrl + C) while building a port or 
   kernel?
  
   Sometimes, while building process of some port or system kernel are in 
   progress, you suddenly remember that you did something wrong and have to 
   stop, solve your mistake and start one more time.
  
   Is it clear to interrupt the building process just by pressing Ctrl + 
   C?
   
   Yes.
   
   If it's so, do I need to run make clean before I start make one more 
   time?
   
   Authoritative answer:  It depends.
   
   On what you 'did wrong, and what it takes to fix it.
   
   e.g.,  if you're building a kernel the 'classial' way, that is 'configure,
   make depend, cd , make',  and realize you left something out of the config
   file, after you edit the config file, you have to rerun _all_ those steps.
   
 
  Is it even advisable to build the kernel the old way ?
 
 On a slow processor, it makes a *BIG* differnence.
 Even more so if you build everything you need into the kernel.
 
 'make buildkernel' always recompiles an relinks *everything*. whether or
 not any dependenies for the module have changed.

If that is a problem then just use 'make -DNO_CLEAN buildkernel' and
it won't reompile stuff that doesn't need to be recompiled.  (Works for
buildworld as well.)


-- 
Insert your favourite quote here.
Erik Trulsson
ertr1...@student.uu.se
___
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: Is it safe to interrupt (Ctrl + C) while building a port or kernel?

2011-11-03 Thread Conrad J. Sabatier
On Thu, 03 Nov 2011 22:48:26 +0400
Антон Клесс rc5h...@yandex.ru wrote:

 03.11.2011, 21:20, Robert Bonomi bon...@mail.r-bonomi.com:
 
    If it's so, do I need to run make clean before I start make
  one more time?
   Authoritative answer:  It depends.
 
   On what you 'did wrong, and what it takes to fix it.
 
   e.g.,  if you're building a kernel the 'classial' way, that is
  'configure, make depend, cd , make',  and realize you left
  something out of the config file, after you edit the config file,
  you have to rerun _all_ those steps.
 
 Does it matter, if I always use make buildkernel make installkernel
 way to rebuild kernels?
 
   make buildkernel
 
 ..
 oh! something wrong!
 Ctrl + C
 ..
 mistake fixed!
 
   make buildkernel
   make installkernel
 
 - is right?

That's fine, yes.  But I wouldn't do an unconditional installkernel
after buildkernel (suppose buildkernel failed in some way)?

Either include both targets in the same make command:

make buildkernel installkernel

Or make the second conditional on the outcome of the first:

make buildkernel  make installkernel

You might also save yourself some time by using -DNO_CLEAN after
changing your kernel config.

-- 
Conrad J. Sabatier
conr...@cox.net
___
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: Is it safe to interrupt (Ctrl + C) while building a port or kernel?

2011-11-03 Thread RW
On Thu, 3 Nov 2011 12:20:46 -0500 (CDT)
Robert Bonomi wrote:

  From owner-freebsd-questi...@freebsd.org  Thu Nov  3 12:10:08 2011
  From: =?koi8-r?B?4c7Uz84g68zF09M=?= rc5h...@yandex.ru
  To: freebsd-questions@freebsd.org
  Date: Thu, 03 Nov 2011 21:10:19 +0400
  Subject: Is it safe to interrupt (Ctrl + C) while building a port
  or kernel?

  Is it clear to interrupt the building process just by pressing Ctrl
  + C?
 
 Yes.

Whilst it's not strictly-speaking building, I would avoid interrupting
an install.
___
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: Is it safe to interrupt (Ctrl + C) while building a port or kernel?

2011-11-03 Thread Conrad J. Sabatier
On Thu, 3 Nov 2011 13:48:47 -0500 (CDT)
Robert Bonomi bon...@mail.r-bonomi.com wrote:
[snip] 
 I am likely _not_ the typical user -- I run a monolithic kernel, with 
 everything I need 'compiled in'; *no* loadable modules.  Yeah, it can
 be a nuisance if I need something that isn't compiled in, but I don't
 get ny unexpected surprises.  It also does wonders as far as reducing
 the required 'root partition' size.  I run a 64mb(!!) partition, with
 less than 1/2 of it occupied by the system install.  With the running
 kernel, a copy of the prior running one as a fall-back, and a GENERIC
 for worst-case recovery.

If you don't use modules, why build them at all?  Just set
NO_MODULES=yes in /etc/make.conf and save yourself that much time.

-- 
Conrad J. Sabatier
conr...@cox.net
___
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