mirror of https://git.kore.io/kore.git
Add openssl paths for homebrew/ports for osx.
These are the default paths openssl should be installed under for both projects. This at least kills the need for user CFLAGS for a normal build. Inspired by #70.
This commit is contained in:
parent
a64808c6b0
commit
4dff0b57ae
12
src/cli.c
12
src/cli.c
|
@ -879,7 +879,7 @@ cli_compile_cfile(void *arg)
|
||||||
int idx, f, i;
|
int idx, f, i;
|
||||||
struct cfile *cf = arg;
|
struct cfile *cf = arg;
|
||||||
char *flags[CFLAGS_MAX], *p;
|
char *flags[CFLAGS_MAX], *p;
|
||||||
char *args[30 + CFLAGS_MAX], *ipath[2], *cppstandard;
|
char *args[32 + CFLAGS_MAX], *ipath[2], *cppstandard;
|
||||||
#if defined(KORE_USE_PGSQL)
|
#if defined(KORE_USE_PGSQL)
|
||||||
char *ppath;
|
char *ppath;
|
||||||
#endif
|
#endif
|
||||||
|
@ -887,10 +887,6 @@ cli_compile_cfile(void *arg)
|
||||||
(void)cli_vasprintf(&ipath[0], "-I%s/src", rootdir);
|
(void)cli_vasprintf(&ipath[0], "-I%s/src", rootdir);
|
||||||
(void)cli_vasprintf(&ipath[1], "-I%s/src/includes", rootdir);
|
(void)cli_vasprintf(&ipath[1], "-I%s/src/includes", rootdir);
|
||||||
|
|
||||||
/*
|
|
||||||
* These compiler options should be settable
|
|
||||||
* somehow by the user if they so choose.
|
|
||||||
*/
|
|
||||||
idx = 0;
|
idx = 0;
|
||||||
args[idx++] = compiler;
|
args[idx++] = compiler;
|
||||||
args[idx++] = ipath[0];
|
args[idx++] = ipath[0];
|
||||||
|
@ -901,6 +897,12 @@ cli_compile_cfile(void *arg)
|
||||||
args[idx++] = "-I/usr/local/include";
|
args[idx++] = "-I/usr/local/include";
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
|
#if defined(__MACH__)
|
||||||
|
/* Add default openssl include path from homebrew / ports under OSX. */
|
||||||
|
args[idx++] = "-I/opt/local/include";
|
||||||
|
args[idx++] = "-I/usr/local/opt/openssl/include";
|
||||||
|
#endif
|
||||||
|
|
||||||
/* Add any user specified flags. */
|
/* Add any user specified flags. */
|
||||||
if ((p = getenv("CFLAGS")) != NULL)
|
if ((p = getenv("CFLAGS")) != NULL)
|
||||||
f = kore_split_string(p, " ", flags, CFLAGS_MAX);
|
f = kore_split_string(p, " ", flags, CFLAGS_MAX);
|
||||||
|
|
Loading…
Reference in New Issue