Re: buildworld and installworld

From: Ruslan Ermilov (ru_at_freebsd.org)
Date: 01/23/04

  • Next message: Peter Jeremy: "Re: Fix make release for 4-STABLE"
    Date: Fri, 23 Jan 2004 21:31:23 +0200
    To: Maxim Konovalov <maxim@macomnet.ru>
    
    
    

    On Fri, Jan 23, 2004 at 10:03:57PM +0300, Maxim Konovalov wrote:
    > freebsd-questions@ material.
    >
    > On Fri, 23 Jan 2004, 20:58+0200, Andrey Sharandakov wrote:
    >
    > > Hi!
    > >
    > > 1. How can I change default dir. for buildworld output?
    > > (/ust/obj to /some_dir/obj)
    >
    > make MAKEOBJDIRPREFIX=/some_dir/obj
    >
    WRONG! While I've made the above work in -CURRENT, this still
    doesn't work in RELENG_4 and shouldn't be relied upon. From
    <bsd.obj.mk>:

    # MAKEOBJDIRPREFIX Specifies somewhere other than /usr/obj to root the object
    # tree. Note: MAKEOBJDIRPREFIX is an *environment* variable
    # and works properly only if set as an environment variable,
    # not as a global or command line variable!
    #
    # E.g. use `env MAKEOBJDIRPREFIX=/somewhere/obj make'

    Compare:

    $ pwd
    /tmp/foo/src
    $ MAKEOBJDIRPREFIX=/tmp/foo/obj make -f bsd.obj.mk -V .OBJDIR
    /tmp/foo/obj/tmp/foo/src
    $ make MAKEOBJDIRPREFIX=/tmp/foo/obj -f bsd.obj.mk -V .OBJDIR
    /tmp/foo/src

    Passing MAKEOBJDIRPREFIX as a command line variable with ``buildworld''
    only works because make(1) enters all command line variables in
    environment before starting any subprocesses.

    Cheers,

    -- 
    Ruslan Ermilov
    FreeBSD committer
    ru@FreeBSD.org
    
    



  • Next message: Peter Jeremy: "Re: Fix make release for 4-STABLE"