Fix compilation warnings and prepare to be a dependency.
This commit is contained in:
13
.gitignore
vendored
13
.gitignore
vendored
@@ -1,9 +1,12 @@
|
|||||||
*.beam
|
*.beam
|
||||||
*.so
|
*.so
|
||||||
*.o
|
*.o
|
||||||
|
*.d
|
||||||
*.swp
|
*.swp
|
||||||
rebar
|
/rebar
|
||||||
ebin/
|
/ebin/
|
||||||
.eunit
|
/.eunit/
|
||||||
.rebar/
|
/.rebar/
|
||||||
_build/
|
/_build/
|
||||||
|
/compile_commands.json
|
||||||
|
/geef
|
||||||
|
|||||||
@@ -5,6 +5,9 @@
|
|||||||
{port_env, [
|
{port_env, [
|
||||||
{"DRV_LDFLAGS", "$DRV_LDFLAGS -lz -lgit2"},
|
{"DRV_LDFLAGS", "$DRV_LDFLAGS -lz -lgit2"},
|
||||||
|
|
||||||
|
%% fix rebar2 compilation for erlang-23 and above (replace automatic usage of -lerl_interface with -lei)
|
||||||
|
{"ERL_LDFLAGS", "-L$ERL_EI_LIBDIR -lei"},
|
||||||
|
|
||||||
%% OS X Leopard flags for 64-bit
|
%% OS X Leopard flags for 64-bit
|
||||||
{"darwin9.*-64$", "CXXFLAGS", "-m64"},
|
{"darwin9.*-64$", "CXXFLAGS", "-m64"},
|
||||||
{"darwin9.*-64$", "LDFLAGS", "-arch x86_64"},
|
{"darwin9.*-64$", "LDFLAGS", "-arch x86_64"},
|
||||||
|
|||||||
@@ -2,7 +2,7 @@
|
|||||||
%%% NIF functions, not to be used directly.
|
%%% NIF functions, not to be used directly.
|
||||||
|
|
||||||
-module(geef_nif).
|
-module(geef_nif).
|
||||||
-compile(export_all).
|
-compile([export_all,nowarn_export_all]).
|
||||||
|
|
||||||
-include("geef_records.hrl").
|
-include("geef_records.hrl").
|
||||||
|
|
||||||
@@ -85,7 +85,7 @@ reflog_read(_Handle, _Name) ->
|
|||||||
reflog_delete(_Handle, _Name) ->
|
reflog_delete(_Handle, _Name) ->
|
||||||
?NIF_FN.
|
?NIF_FN.
|
||||||
|
|
||||||
odb_object_exists(_Val, _Val) ->
|
odb_object_exists(_Val1, _Val2) ->
|
||||||
nif_error(?LINE).
|
nif_error(?LINE).
|
||||||
|
|
||||||
-spec odb_write(term(), iolist(), atom()) -> term().
|
-spec odb_write(term(), iolist(), atom()) -> term().
|
||||||
|
|||||||
@@ -1,5 +1,5 @@
|
|||||||
-module(config_test).
|
-module(config_test).
|
||||||
-compile([export_all]).
|
-compile([export_all,nowarn_export_all]).
|
||||||
-include_lib("eunit/include/eunit.hrl").
|
-include_lib("eunit/include/eunit.hrl").
|
||||||
-include("src/geef_records.hrl").
|
-include("src/geef_records.hrl").
|
||||||
|
|
||||||
|
|||||||
@@ -1,5 +1,5 @@
|
|||||||
-module(pkt_test).
|
-module(pkt_test).
|
||||||
-compile([export_all]).
|
-compile([export_all,nowarn_export_all]).
|
||||||
-include_lib("eunit/include/eunit.hrl").
|
-include_lib("eunit/include/eunit.hrl").
|
||||||
-include("src/geef_records.hrl").
|
-include("src/geef_records.hrl").
|
||||||
|
|
||||||
|
|||||||
@@ -1,5 +1,5 @@
|
|||||||
-module(ref_test).
|
-module(ref_test).
|
||||||
-compile([export_all]).
|
-compile([export_all,nowarn_export_all]).
|
||||||
|
|
||||||
-include_lib("eunit/include/eunit.hrl").
|
-include_lib("eunit/include/eunit.hrl").
|
||||||
-include("src/geef_records.hrl").
|
-include("src/geef_records.hrl").
|
||||||
|
|||||||
@@ -1,5 +1,5 @@
|
|||||||
-module(repo_test).
|
-module(repo_test).
|
||||||
-compile([export_all]).
|
-compile([export_all,nowarn_export_all]).
|
||||||
-include_lib("eunit/include/eunit.hrl").
|
-include_lib("eunit/include/eunit.hrl").
|
||||||
-include("src/geef_records.hrl").
|
-include("src/geef_records.hrl").
|
||||||
|
|
||||||
@@ -117,7 +117,7 @@ commit_tree_test(Repo) ->
|
|||||||
CommitId = geef_oid:parse("bf968373f95f8fed2a24f9d25ebf06521359c6bc"),
|
CommitId = geef_oid:parse("bf968373f95f8fed2a24f9d25ebf06521359c6bc"),
|
||||||
{ok, Commit} = geef_commit:lookup(Repo, CommitId),
|
{ok, Commit} = geef_commit:lookup(Repo, CommitId),
|
||||||
Resp = geef_commit:tree(Commit),
|
Resp = geef_commit:tree(Commit),
|
||||||
[?_assertMatch({ok, _}, Resp)].
|
[?_assertMatch({ok, _, _}, Resp)].
|
||||||
|
|
||||||
rm_r(Path) ->
|
rm_r(Path) ->
|
||||||
case filelib:is_dir(Path) of
|
case filelib:is_dir(Path) of
|
||||||
|
|||||||
@@ -1,5 +1,5 @@
|
|||||||
-module(revwalk_test).
|
-module(revwalk_test).
|
||||||
-compile([export_all]).
|
-compile([export_all,nowarn_export_all]).
|
||||||
-include_lib("eunit/include/eunit.hrl").
|
-include_lib("eunit/include/eunit.hrl").
|
||||||
|
|
||||||
repo_test_() ->
|
repo_test_() ->
|
||||||
|
|||||||
Reference in New Issue
Block a user