Packages
fast_xml
1.1.7
1.1.60
1.1.59
1.1.58
1.1.57
1.1.56
1.1.55
1.1.53
1.1.52
1.1.51
1.1.49
1.1.48
1.1.47
1.1.46
1.1.45
1.1.43
1.1.41
1.1.40
1.1.39
1.1.38
1.1.37
1.1.36
1.1.35
1.1.34
1.1.32
1.1.31
1.1.30
1.1.29
1.1.28
1.1.27
1.1.26
1.1.24
1.1.23
1.1.22
1.1.20
1.1.19
1.1.18
1.1.15
1.1.14
1.1.13
1.1.12
1.1.11
1.1.10
1.1.9
1.1.8
1.1.7
1.1.6
1.1.5
1.1.4
1.1.3
1.1.2
Fast Expat-based Erlang / Elixir XML parsing library
Current section
Files
Jump to
Current section
Files
Makefile.mix
# This file is used to compile C NIF module in Elixir buildchain
MIX = mix
CFLAGS = -g -O2 -Wall
#CFLAGS = -g -O3 -ansi -pedantic -Wall -Wextra -Wno-unused-parameter
ERLANG_PATH = $(shell erl -eval 'io:format("~s", [lists:concat([code:root_dir(), "/erts-", erlang:system_info(version), "/include"])])' -s init stop -noshell)
CFLAGS += -I$(ERLANG_PATH)
LDFLAGS += -lexpat
ifneq ($(OS),Windows_NT)
CFLAGS += -fPIC
ifeq ($(shell uname),Darwin)
LDFLAGS += -dynamiclib -undefined dynamic_lookup
endif
endif
.PHONY: all fast_xml clean
all: fast_xml
fast_xml:
$(MIX) compile
priv/lib/fxml_stream.so: c_src/fxml_stream.c
@mkdir -p priv/lib
$(CC) $(CFLAGS) $(LDFLAGS) -o $@ c_src/fxml_stream.c
priv/lib/fxml.so: c_src/fxml.c
@mkdir -p priv/lib
$(CC) $(CFLAGS) $(LDFLAGS) -o $@ c_src/fxml.c
clean:
$(RM) priv/lib/fxml_stream.so
$(RM) priv/lib/fxml.so
# Local Variables:
# mode: makefile
# End:
# vim: set filetype=makefile