Skip site navigation (1)Skip section navigation (2)
Date:      Mon, 12 May 2003 14:15:06 +0300
From:      Giorgos Keramidas <keramida@freebsd.org>
To:        jeev <jeev@boldinternet.net>
Cc:        doc@freebsd.org
Subject:   Re: possible typo
Message-ID:  <20030512111505.GC711@gothmog.gr>
In-Reply-To: <000001c31854$cfa432f0$0200a8c0@mainframe>
References:  <000001c31854$cfa432f0$0200a8c0@mainframe>

next in thread | previous in thread | raw e-mail | index | archive | help
On 2003-05-12 00:05, jeev <jeev@boldinternet.net> wrote:
> http://www.freebsd.org/doc/en_US.ISO8859-1/books/handbook/dns.html
>
> on that page:
>
> Build a statically linked copy of named-xfer, and copy it into the sandbox:
>
> # cd /usr/src/lib/libisc && make clean all
> # cd /usr/src/lib/libbind && make clean all
> # cd /usr/src/libexec/named-xfer && make NOSHARED=yes all
> # cp named-xfer /etc/namedb/bin && chmod 555 /etc/namedb/bin/named-xfer
>
> should be something like the following:
>
> cp /usr/obj/usr/src/libexec/named-xfer/named-xfer /etc/namedb/bin && chmod
> 555 /etc/namedb/bin/named-xfer
>
> because the built named-xfer file is not in /usr/src/libexec/named-xfer,
> it's in the obj dir, thanks.

If you have an existing obj tree it will be used, unless "make cleandir"
deletes it.  The instructions are a bit more complicated then, and look
something like this:

	# cd /usr/src/lib/libisc
	# make cleandir && make cleandir && make depend && make all
	# cd /usr/src/lib/libbind
	# make cleandir && make cleandir && make depend && make all
	# cd /usr/src/libexec/named-xfer
	# make cleandir && make cleandir && make depend && make NOSHARED=yes all
	# cp named-xfer /etc/namedb/bin && chmod 555 /etc/namedb/bin/named-xfer

I think it's a good idea to build this outside of the normal obj tree,
to avoid messing around with previous files that are probably left
there.  Then, after the copying is successfully finished, some cleaning
up is required:

	# cd /usr/src/lib/libisc
	# make cleandir
	# cd /usr/src/lib/libbind
	# make cleandir
	# cd /usr/src/libexec/named-xfer
	# make cleandir

If nobody sees some problem with these commands, I'll update the
instructions to something like this:

: Index: advanced-networking/chapter.sgml
: ===================================================================
: RCS file: /home/ncvs/doc/en_US.ISO8859-1/books/handbook/advanced-networking/chapter.sgml,v
: retrieving revision 1.214
: diff -u -r1.214 chapter.sgml
: --- advanced-networking/chapter.sgml	10 May 2003 12:12:02 -0000	1.214
: +++ advanced-networking/chapter.sgml	12 May 2003 11:12:48 -0000
: @@ -5000,16 +5000,36 @@
:  	  <para>Build a statically linked copy of
:  	    <application>named-xfer</application>, and copy it into the sandbox:</para>
:
: -	      <screen>&prompt.root; <userinput>cd /usr/src/lib/libisc && make clean all</userinput>
: -&prompt.root; <userinput>cd /usr/src/lib/libbind && make clean all</userinput>
: -&prompt.root; <userinput>cd /usr/src/libexec/named-xfer && make NOSHARED=yes all</userinput>
: +	      <screen>&prompt.root; <userinput>cd /usr/src/lib/libisc</userinput>
: +&prompt.root; <userinput>make cleandir && make cleandir && make depend && make all</userinput>
: +&prompt.root; <userinput>cd /usr/src/lib/libbind</userinput>
: +&prompt.root; <userinput>make cleandir && make cleandir && make depend && make all</userinput>
: +&prompt.root; <userinput>cd /usr/src/libexec/named-xfer</userinput>
: +&prompt.root; <userinput>make cleandir && make cleandir && make depend && make NOSHARED=yes all</userinput>
:  &prompt.root; <userinput>cp named-xfer /etc/namedb/bin && chmod 555 /etc/namedb/bin/named-xfer</userinput><co id="clean-cruft"></screen>
: +
: +	  <para>After your statically linked
: +	    <command>named-xfer</command> is installed some cleaning up
: +	    is required, to avoid leaving stale copies of libraries or
: +	    programs in your source tree:</para>
: +
: +	  <screen>&prompt.root; <userinput>cd /usr/src/lib/libisc</userinput>
: +&prompt.root; <userinput>make cleandir</userinput>
: +&prompt.root; <userinput>cd /usr/src/lib/libbind</userinput>
: +&prompt.root; <userinput>make cleandir</userinput>
: +&prompt.root; <userinput>cd /usr/src/libexec/named-xfer</userinput>
: +&prompt.root; <userinput>make cleandir</userinput></screen>
: +
:           <calloutlist>
:             <callout arearefs="clean-cruft">
:               <para>This step has been reported to fail occasionally.  If this
:                 happens to you, then issue the command:</para>
:
: -                 <screen>&prompt.root; <userinput>cd /usr/src && make cleandir && make cleandir</userinput></screen>
: +	     <screen>&prompt.root; <userinput>cd /usr/src && make cleandir && make cleandir</userinput></screen>
: +
: +	     <para>and delete your <filename>/usr/obj</filename> tree:</para>
: +
: +	     <screen>&prompt.root; <userinput>rm -fr /usr/obj && mkdir /usr/obj</userinput></screen>
:
:               <para>This will clean out any <quote>cruft</quote> from your
:                 source tree, and retrying the steps above should then work.</para>



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?20030512111505.GC711>