Freebsd port #13

Merged
merged 8 commits into from Sep 27, 2011

Projects

None yet

5 participants

@fperrin
fperrin commented Sep 25, 2011

This branch contains a series of tweaks to the build system (mostly) that enables opalang ot be built on FreeBSD. The code should still build fine on Linux and Mac systems.

One additionnal change (the one contained in the no-java branch) is necessary to build opalang under GNU/kFreeBSD, as on this system java is broken.

@aszlig
aszlig commented on 22b433a Sep 25, 2011

hm, might make more sense to remove bashisms from those scripts and use /bin/sh.
just created an issue in my fork, so if i should have some time these days, i'll work on it.

@aszlig

okay, if that works for bsd sed (but i guess it won't), it will definitely break gnu sed, as the * multiplier doesn't have to be quoted there (but the + has, because it's a gnu extension).
i'd write it that way:
"^ *import *\\([^ ][^ ]*\\) *$"
(i put the [^ ] there, because sed is greedy and .* already eats up whitespaces until the end of the line)

Hum, indeed, I have one * quoted, and one that isn't. GNU sed accepts both, IIUC the "Regular Expressions" node of sed.info. It's possible that it worked in BSD sed only by accident...

Actually, it is possible to use the `-r' flad to sed (like I did in the other sed call) and use "modern" regexp, where +, * and () are special characters. That would make the regexp clearer, and without double escaping:

let dep_regexp = "^ *import +([^ ]+) *$" in
  Cmd(S[sed; A"-n"; A"-r"; A("s%"^dep_regex^"%\\1.opx%p");
@frsinot
frsinot commented Sep 26, 2011

It seems to work on MacOS X too, and your commits are clean. So I'm going: 1. to thank you for the great work 2. to merge into master.

Independently, we can discuss about dependency to bash. I don't see clearly what the arguments are against this dependency, but I can be convinced.

@git-mlstate git-mlstate pushed a commit that referenced this pull request Sep 27, 2011
François-Régis Sinot [contrib] merge: FreeBSD port, pull request #13 from git://github.com…
…/fperrin/opalang
f37a024
@git-mlstate git-mlstate merged commit 39997a8 into MLstate:master Sep 27, 2011
@alokmenghrajani
Contributor

You need md5 for mac os too. I tried to build on mac os x (10.8), and things failed because of this.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment