BSD Config
Joakim
joakim at airpost.net
Mon Nov 11 10:51:51 PST 2013
On Monday, 11 November 2013 at 18:02:18 UTC, Tyro[17] wrote:
> Reason... I had every intention of volunteering to become the
> so called build master for DMD. I thought it a bit presumptuous
> to do such a thing without actually knowing how to build the
> compiler on the supported platforms. I'm using DragonFlyBSD but
> as far as I know it is 100% source/binary compatible with
> FreeBSD.
As Walter said in that thread, you don't have to build everything
yourself if you're the build master. You're just responsible for
the end product, which may simply mean prodding those responsible
for the OS builds that you're unfamiliar with
(http://forum.dlang.org/thread/l5ec4p$18p2$1@digitalmars.com#post-l5edpl:241a8i:241:40digitalmars.com).
DragonFly forked from FreeBSD 4 and the dmd2 FreeBSD port doesn't
compile on anything less than FreeBSD 8. Also, the dmd codebase
hardcodes for FreeBSD, so even if some source would compile on
DragonFly also, it won't until you add in the DragonFly name into
the all the appropriate ifdefs.
> Either way, I've progressed well beyond this point. My current
> problem is there are a number of undefined references to
> Port::'et al' in the following files (list abbreviated to
> remove eliminate all duplicates):
>
> lexer.c: Port::strtold(char const*, char**)
> lexer.c: Port::strtod(char const*, char**)
> lexer.c: Port::strtof(char const*, char**)
>
> mars.c: browse(char const*)
>
> mtype.c: Port::snan
> mtype.c: Port::ldbl_infinity
> mtype.c: Port::ldbl_nan
> mtype.c: Port::ldbl_max
>
> blockopt.c: util_progress()
>
> cgelem.c: util_progress()
>
> constfold.c: Port::fmodl(long double, long double)
> constfold.c: Port::ldbl_nan
> constfold.c: Port::isNan(long double)
>
> e2ir.c: Port::isSignallingNan(long double)
>
> expression.c: Port::isNan(long double)
> expression.c: Port::fequal(long double, long double)
> expression.c: Port::strtold(char const*, char**)
> expression.c: Port::isInfinity(double)
>
> go.c: util_progress()
>
> inifile.c: Port::strupr(char*)
> inifile.c: Port::memicmp(char const*, char const* int)
>
> doc.c: Port::memicmp(char const*, char const* int)
>
> ctfeexpr.c: Port::isNan(long double)
This is because DragonFly is not included in the ifdefs. Look at
dmd2/root/port.c. You'll see that all these Port::* functions
are defined specifically for FreeBSD and the other supported
platforms but DragonFly isn't mentioned anywhere. You have to go
through and add DragonFly into all the appropriate source files
for it to work on DragonFly, not just for dmd but especially in
druntime and a little bit in Phobos too. It might make sense to
add a general BSD define, but then you'll have to test that on
all the other BSDs also.
In any case, none of this is required to be build master, as dmd
only supports FreeBSD officially and that already works.
> I could start over with FreeBSD now that I know what the
> problem with that system was. But after installing, configuring
> and deleting three flavors of BSD for as many times as I did
> starting on Wednesday of last week, I have no desire to do it
> again. At least not right now.
If you are interested in volunteering for build master, none of
this was necessary, so I wouldn't let it put you off. I suggest
you talk to Walter or Brad about what knowledge is required to do
that job and figure out if you fit the bill. You will not have
to do any of the above porting work as build master, simply keep
the trains running on time AFAIK. :)
More information about the Digitalmars-d
mailing list