Mercurial > urweb
comparison src/config.sml.in @ 1673:dae2c6fbf16c
Make Ubuntu linking patch more general
author | Adam Chlipala <adam@chlipala.net> |
---|---|
date | Tue, 10 Jan 2012 17:38:00 -0500 |
parents | df8f18d50746 |
children | c414850f206f |
comparison
equal
deleted
inserted
replaced
1672:ea131de361d9 | 1673:dae2c6fbf16c |
---|---|
16 val ccArgs = "@CCARGS@" | 16 val ccArgs = "@CCARGS@" |
17 | 17 |
18 val openssl = "@OPENSSL_LDFLAGS@ @OPENSSL_LIBS@" | 18 val openssl = "@OPENSSL_LDFLAGS@ @OPENSSL_LIBS@" |
19 | 19 |
20 (* Something is rotten in the state of Ubuntu 11.10, so here's a manual fix that I hope doesn't break other platforms. *) | 20 (* Something is rotten in the state of Ubuntu 11.10, so here's a manual fix that I hope doesn't break other platforms. *) |
21 val openssl = case String.tokens Char.isSpace openssl of | 21 val openssl = |
22 ["-lssl", "-lcrypto"] => "-lcrypto -lssl" | 22 let |
23 | _ => openssl | 23 val tokens = String.tokens Char.isSpace openssl |
24 in | |
25 if List.exists (fn s => s = "-lssl") tokens then | |
26 String.concatWith " " (List.filter (fn s => s <> "-lssl") tokens @ ["-lssl"]) | |
27 else | |
28 openssl | |
29 end | |
24 | 30 |
25 val pgheader = "@PGHEADER@" | 31 val pgheader = "@PGHEADER@" |
26 val msheader = "@MSHEADER@" | 32 val msheader = "@MSHEADER@" |
27 val sqheader = "@SQHEADER@" | 33 val sqheader = "@SQHEADER@" |
28 | 34 |