-
Notifications
You must be signed in to change notification settings - Fork 27
/
rebar.config
50 lines (46 loc) · 1.88 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
{sub_dirs, ["rel"]}.
{port_specs, [
{"priv/mydef.so", ["c_src/mydef.c"], [{env, [{"CC", "gcc"}]}]},
{"priv/testnif.so", ["c_src/testnif.c"]}
]}.
%% , [{env, ["CC", "gcc -fPIC -bundle -flat_namespace -undefined suppress -I/usr/local/mysql/include"]}]
%% [{env, ["CC", "gcc -fPIC -bundle -flat_namespace -undefined suppress -I/usr/local/lib/erlang/erts-5.9/include/"]}]
{port_env, [
%% {"CFLAGS", "$CFLAGS -I/usr/local/mysql/include"}
{"CC", "gcc -I/usr/local/mysql/include"}
]}.
%% == Port Compiler ==
%% Port compilation environment variables. See rebar_port_compiler.erl for
%% more info. Default is `[]'
%% {port_env, [
%% {"CFLAGS", "$CFLAGS -arch x86_64 -g -Os -pipe -no-cpp-precomp"},
%% %%{"CFLAGS", "-fPIC -bundle -flat_namespace -undefined suppress -I/usr/local/lib/erlang/erts-5.9/include/"},
%% ]}.
%% port_specs
%% List of filenames or wildcards to be compiled. May also contain a tuple
%% consisting of a regular expression to be applied against the system
%% architecture as a filter.
%% {port_specs, [{"priv/so_name.so", ["c_src/*.c"]},
%% {"linux", "priv/hello_linux", ["c_src/hello_linux.c"]},
%% {"linux", "priv/hello_linux", ["c_src/*.c"], [{env, []}]}]}.
%%
%% Erlang compiler options
{erl_opts, [debug_info,
{i, "include"}
%% {outdir, "ebin"},
%% {src_dirs, [
%% 'src/*'
%% ,'src/crontab/*'
%% ,'src/data/*'
%% ,'src/json/*'
%% ,'src/mysql/*'
%% ,'src/test/*'
%% ,'src/pt/*'
%% ,'src/mod/*'
%% ,'src/lib/*'
%% ]}
%% {platform_define, "(linux|solaris|freebsd|darwin)", 'HAVE_SENDFILE'}
%% {platform_define, "darwin", 'HAVE_SENDFILE'}
]
}.
%% vim: ft=erlang :