~ben-kietzman/mjson/mjson

« back to all changes in this revision

Viewing changes to src/Makefile.am

  • Committer: Rui Maciel
  • Date: 2010-08-22 19:46:40 UTC
  • Revision ID: git-v1:2c33cd06c9b0e67e392a38ee581ad2b1265be801
initial import of the v2 branch

Show diffs side-by-side

added added

removed removed

Lines of Context:
1
 
noinst_PROGRAMS = test
 
1
bin_PROGRAMS = main
2
2
 
3
3
# set the include path found by configure
4
4
INCLUDES = $(all_includes)
5
5
 
6
 
lib_LTLIBRARIES=libmjson.la
7
 
 
8
 
mjsondir=$(includedir)/mjson-$(MILESTONE)
9
 
mjson_HEADERS = json.h json_helper.h
10
 
libmjson_la_LDFLAGS=-release $(MILESTONE)
11
 
libmjson_la_SOURCES=\
12
 
        $(mjson_HEADERS) \
13
 
        json.c \
14
 
        json_helper.c \
15
 
        $(NULL)
16
 
 
17
6
# the library search path.
18
 
test_LDFLAGS = $(all_libraries)
19
 
test_LDADD = libmjson.la
20
 
test_SOURCES = test.c
21
 
 
22
 
EXTRA_DIST=.indent.pro
23
 
 
24
 
check-local:
25
 
        @for src in $(test_SOURCES) $(libmjson_la_SOURCES); do \
26
 
                echo "[TEST] $$src"; \
27
 
                INDENT_PROFILE="$(srcdir)/.indent.pro" indent -st $$src | diff -u $$src - || exit $?; \
28
 
        done
29
 
 
30
 
installcheck-local:
31
 
        cat $(srcdir)/test.c | \
32
 
                $(CC) -x c - -o /dev/null \
33
 
                $(shell PKG_CONFIG_PATH=$(pkgconfigdir):$$PKG_CONFIG_PATH pkg-config --cflags --libs mjson-@MILESTONE@)
 
7
main_LDFLAGS = $(all_libraries) 
 
8
noinst_HEADERS = json.h
 
9
main_SOURCES = json.c main.c
 
10
 
 
11
 
 
12
if HAVE_RE2C
 
13
$(srcdir)/json.c:       $(srcdir)/json.c.re2c
 
14
        re2c -o $(srcdir)/json.c $(srcdir)/json.c.re2c
 
15
endif