Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP
Browse files

Add possibility to compile epcap with PF_RING

  • Loading branch information...
commit 0b8a5af19b866b9949bfc9bfcc1c63410f61afdc 1 parent 1975bc0
@ates ates authored
Showing with 17 additions and 0 deletions.
  1. +17 −0 rebar.config.script
View
17 rebar.config.script
@@ -0,0 +1,17 @@
+case os:getenv("PFRING") of
+ false ->
+ CONFIG;
+ Value ->
+ case filelib:is_dir(Value) of
+ true ->
+ case lists:keysearch(port_env, 1, CONFIG) of
+ {value, {port_env, Flags}} ->
+ {"EXE_LDFLAGS", LDFLAGS} = hd(Flags),
+ NewFlags = LDFLAGS ++ " -static -L " ++ Value ++ " -lpfring -lpthread",
+ NewLDFLAGS = lists:keyreplace("EXE_LDFLAGS", 1, Flags, {"EXE_LDFLAGS", NewFlags}),
+ lists:keyreplace(port_env, 1, CONFIG, {port_env, NewLDFLAGS});
+ _ -> CONFIG
+ end;
+ _ -> CONFIG
+ end
+end.
Please sign in to comment.
Something went wrong with that request. Please try again.