forked from caroman/erlogr
-
Notifications
You must be signed in to change notification settings - Fork 2
/
Copy pathrebar.config
68 lines (58 loc) · 2.71 KB
/
rebar.config
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
{lfe_first_files, ["src/lgeo-util.lfe"]}.
{eunit_compile_opts, [
{src_dirs, ["test"]}
]}.
{deps, [
{lfe, ".*", {git, "https://github.com/rvirding/lfe.git", {tag, "v0.10.1"}}},
{lutil, ".*", {git, "https://github.com/lfex/lutil.git", {tag, "0.7.0"}}},
{lcfg, ".*", {git, "https://github.com/lfex/lcfg.git", {tag, "0.3.0"}}}
]}.
{port_specs, [
{"priv/lgeo_gdal.so", ["c_src/lgeo_gdal.c"]},
{"priv/lgeo_ogr.so", ["c_src/lgeo_ogr.c"]},
{"priv/lgeo_osr.so", ["c_src/lgeo_osr.c"]},
{"priv/lgeo_geos_geom.so", ["c_src/lgeo_geos_geom.c"]},
{"priv/lgeo_geos_index.so", ["c_src/lgeo_geos_index.c"]},
{"priv/lgeo_geos_io.so", ["c_src/lgeo_geos_io.c"]}
]}.
{port_env, [
%% add MS Visual C++ support to rebar on Windows
{"win32", "CC", "cl.exe"},
{"win32", "CXX", "cl.exe"},
{"win32", "LINKER", "link.exe"},
%% DRV_* and EXE_* Templates are identical
{"win32", "DRV_CXX_TEMPLATE",
"$CXX /c $CXXFLAGS $DRV_CFLAGS $PORT_IN_FILES /Fo$PORT_OUT_FILE"},
{"win32", "DRV_CC_TEMPLATE",
"$CC /c $CFLAGS $DRV_CFLAGS $PORT_IN_FILES /Fo$PORT_OUT_FILE"},
{"win32", "DRV_LINK_TEMPLATE",
"$LINKER $PORT_IN_FILES $LDFLAGS $DRV_LDFLAGS /OUT:$PORT_OUT_FILE"},
%% DRV_* and EXE_* Templates are identical
{"win32", "EXE_CXX_TEMPLATE",
"$CXX /c $CXXFLAGS $EXE_CFLAGS $PORT_IN_FILES /Fo$PORT_OUT_FILE"},
{"win32", "EXE_CC_TEMPLATE",
"$CC /c $CFLAGS $EXE_CFLAGS $PORT_IN_FILES /Fo$PORT_OUT_FILE"},
{"win32", "EXE_LINK_TEMPLATE",
"$LINKER $PORT_IN_FILES $LDFLAGS $EXE_LDFLAGS /OUT:$PORT_OUT_FILE"},
%% ERL_CFLAGS are ok as -I even though strictly it should be /I
{"win32", "ERL_LDFLAGS", " /LIBPATH:$ERL_EI_LIBDIR erl_interface.lib ei.lib"},
{"win32", "DRV_CFLAGS", "/Zi /Wall $ERL_CFLAGS"},
{"win32", "DRV_LDFLAGS", "/DLL $ERL_LDFLAGS"},
%% GDAL & GEOS specifc settings
{"(linux|solaris|darwin)", "LDFLAGS", "$LDFLAGS -lgdal -lgeos_c"},
{"(linux|solaris|darwin)", "CFLAGS", "$CFLAGS -I/usr/include/gdal"},
{"win32", "DRV_LDFLAGS", "$DRV_LDFLAGS gdal.lib geos_c.lib"}
]}.
{plugins, [
{pc, ".*", {git, "https://github.com/blt/port_compiler.git", {tag, "v1.1.0"}}},
{lodox, ".*", {git, "https://github.com/quasiquoting/lodox.git", {tag, "0.12.1"}}},
{'lfe-compile', ".*", {git, "https://github.com/lfe-rebar3/compile.git", {tag, "0.2.1"}}},
{'lfe-version', ".*", {git, "https://github.com/lfe-rebar3/version.git", {tag, "0.2.1"}}},
{'lfe-repl', ".*", {git, "https://github.com/lfe-rebar3/repl.git", {tag, "0.1.1"}}},
{'lfe-clean', ".*", {git, "https://github.com/lfe-rebar3/clean.git", {tag, "0.1.0"}}}
]}.
{provider_hooks, [
{pre, [{compile, {pc, compile}},
{compile, {lfe, compile}},
{clean, {pc, clean}}]}
]}.