Skip site navigation (1)Skip section navigation (2)
Date:      Thu, 26 Feb 2009 13:23:37 -0900
From:      Mel <fbsd.questions@rachie.is-a-geek.net>
To:        freebsd-questions@freebsd.org
Cc:        Tim Judd <tajudd@gmail.com>
Subject:   Re: Heimdal vs MIT KerberosV
Message-ID:  <200902261323.37744.fbsd.questions@rachie.is-a-geek.net>
In-Reply-To: <ade45ae90902260948s1a74ca80qbcfdbc5a1c4949e@mail.gmail.com>
References:  <ade45ae90902260948s1a74ca80qbcfdbc5a1c4949e@mail.gmail.com>

next in thread | previous in thread | raw e-mail | index | archive | help
On Thursday 26 February 2009 08:48:35 Tim Judd wrote:
> It'd be just as easy for me to build
> MIT krb5 from ports and let it install into /usr/local.  That's fine -- but
> I wanted to stretch my knowledge on FreeBSD and the building process and
> would like to know what it would take to drop in MIT in exchange for
> Heimdal.  I'd guess a couple possible ways to do it, but I wanted to ask
> the experts before I broke FreeBSD.  :)
>
> Options as I see them:
>    1) Take the port directory and replace the contents of
> /usr/src/kerberos5 with security/krb5 from ports
>    2) Take the tarball from MIT and drop it into /usr/src/kerberos5
>
>
> If anything were to work, I'd expect #1 to.  So what is the expert's
> opinion, is it really this easy?

Neither will work. The ports build system is a vastly different superset of 
the src system. Ports core makefiles are in /usr/ports/Mk, and src 
in /usr/share/mk. Ports take very little from /usr/share/mk, only sys.mk for 
default flags, bsd.own.mk for default ownerships, the bsd.ports*.mk to point 
to $PORTSDIR and exclude /etc/src.conf and that's about it.

Further more, the base system doesn't use 'configure', patches are applied to 
make it work for FreeBSD without this hurdle. In short, if you want to learn 
about the src make system, this isn't a good project. A better project is 
read the pmake tutorial, the make(1) manpage, comments in /usr/share/mk/*.mk 
and start writing your own software with this build system.
Start with something like:
========
cat <<EOF > BSDmakefile
PROG=hello

.include <bsd.prog.mk>
EOF
cat <<'EOF' > hello.c
#include <stdio.h>

int main(int argc, char **argv)
{
	printf("Hello world!\n");
	return 0;
}
EOF
make
=========

Building WITHOUT_KERBEROS and installing MIT-port, is best option to use that 
implementation. You may need to remove libraries by hand, not sure if make 
delete-old-libs covers it.
-- 
Mel

Problem with today's modular software: they start with the modules
    and never get to the software part.



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