~linaro-toolchain-dev/cortex-strings/trunk

« back to all changes in this revision

Viewing changes to Makefile.am

  • Committer: Michael Hope
  • Date: 2010-09-13 08:30:44 UTC
  • mfrom: (14.1.1 cortex-strings)
  • Revision ID: michael.hope@linaro.org-20100913083044-0rr37rigcpd0gg7q
Added autogen.sh.  Tidied up the NEON configure rules using AM_CONDITIONAL.  Made make distcheck pass.

Show diffs side-by-side

added added

removed removed

Lines of Context:
3
3
# Used to record the compiler version in the executables
4
4
COMPILER = $(shell $(CC) --version 2>&1 | head -n1)
5
5
 
 
6
if WITH_NEON
 
7
# Pull in the NEON specific files
 
8
neon_sources = \
 
9
        src/neon/memcpy.S \
 
10
        src/neon/memset.S
 
11
neon_bionic_sources = \
 
12
        reference/bionic/memcpy.S
 
13
neon_cppflags = -mfpu=neon
 
14
neon_dirs = neon
 
15
endif
 
16
 
6
17
# The main library
7
18
lib_LTLIBRARIES = \
8
19
        libcortex-strings.la
38
49
 
39
50
# Main library
40
51
libcortex_strings_la_SOURCES = \
41
 
        src/neon/memcpy.S \
42
 
        src/neon/memset.S \
 
52
        $(neon_sources) \
43
53
        src/thumb-2/strcmp.c \
44
54
        src/thumb-2/strcpy.c \
45
55
        src/thumb-2/strlen.c
46
56
 
47
57
# Options for the tests
48
 
tests_test_memcpy_LDADD = libcortex-strings.la
49
 
tests_test_memcpy_CFLAGS = -Itests $(AM_CFLAGS)
50
 
tests_test_memset_LDADD = libcortex-strings.la
51
 
tests_test_memset_CFLAGS = -Itests $(AM_CFLAGS)
52
 
tests_test_strcmp_LDADD = libcortex-strings.la
53
 
tests_test_strcmp_CFLAGS = -Itests $(AM_CFLAGS)
54
 
tests_test_strcpy_LDADD = libcortex-strings.la
55
 
tests_test_strcpy_CFLAGS = -Itests $(AM_CFLAGS)
56
 
tests_test_strlen_LDADD = libcortex-strings.la
57
 
tests_test_strlen_CFLAGS = -Itests $(AM_CFLAGS)
 
58
tests_cflags = -I$(srcdir)/tests $(AM_CFLAGS)
 
59
tests_ldadd = libcortex-strings.la
 
60
tests_test_memcpy_LDADD = $(tests_ldadd)
 
61
tests_test_memcpy_CFLAGS = $(tests_cflags)
 
62
tests_test_memset_LDADD = $(tests_ldadd)
 
63
tests_test_memset_CFLAGS = $(tests_cflags)
 
64
tests_test_strcmp_LDADD = $(tests_ldadd)
 
65
tests_test_strcmp_CFLAGS = $(tests_cflags)
 
66
tests_test_strcpy_LDADD = $(tests_ldadd)
 
67
tests_test_strcpy_CFLAGS = $(tests_cflags)
 
68
tests_test_strlen_LDADD = $(tests_ldadd)
 
69
tests_test_strlen_CFLAGS = $(tests_cflags)
58
70
 
59
71
TESTS = $(check_PROGRAMS)
60
72
 
61
73
# Libraries containing the difference reference versions
62
74
libbionic_a_SOURCES = \
63
 
        reference/bionic/memcmp.S \
 
75
        $(neon_bionic_sources) \
64
76
        reference/bionic/memcmp16.S \
65
77
        reference/bionic/strlen.c \
66
78
        reference/bionic/memset.S \
67
 
        reference/bionic/memcpy.S
 
79
        reference/bionic/memcmp.S
68
80
 
69
81
libcsl_a_SOURCES = \
70
82
        reference/csl/memcpy.c \
71
 
        reference/csl/memset.c
 
83
        reference/csl/memset.c \
 
84
        reference/csl/arm_asm.h
72
85
 
73
86
libglibc_a_SOURCES = \
74
87
        reference/glibc/memmove.S \
79
92
libnewlib_a_SOURCES = \
80
93
        reference/newlib/strcmp.c \
81
94
        reference/newlib/strlen.c \
82
 
        reference/newlib/strcpy.c
 
95
        reference/newlib/strcpy.c \
 
96
        reference/newlib/arm_asm.h
83
97
 
84
98
libplain_a_SOURCES = \
85
99
        reference/plain/memset.c \
118
132
# Good 'ol Dhrystone
119
133
dhry_SOURCES = \
120
134
        benchmarks/dhry/dhry_1.c \
121
 
        benchmarks/dhry/dhry_2.c
 
135
        benchmarks/dhry/dhry_2.c \
 
136
        benchmarks/dhry/dhry.h
122
137
 
123
138
dhry_CFLAGS = -Dcompiler="\"$(COMPILER)\"" -Doptions="\"$(CFLAGS)\""
124
139
dhry_LDADD = libcortex-strings.la
126
141
dhry_native_SOURCES = $(dhry_SOURCES)
127
142
dhry_native_CFLAGS = $(dhry_CFLAGS)
128
143
 
129
 
AM_CPPFLAGS = $(if $(filter yes,$(with_neon)),-mfpu=neon)
 
144
AM_CPPFLAGS = $(neon_cppflags)
130
145
AM_CFLAGS = -std=gnu99 -Wall $(AM_CPPFLAGS)
131
146
 
 
147
EXTRA_DIST = \
 
148
        tests/hp-timing.h \
 
149
        tests/test-string.h \
 
150
        tests/test-skeleton.c \
 
151
        autogen.sh
 
152
 
132
153
add_on_dist = add-on-dist
133
154
add_on_dest = $(add_on_dist)/$(PACKAGE)/sysdeps/arm/eabi/arm/$(submachine)
134
 
add_on_dirs = thumb-2 $(submachine) $(if $(filter yes,$(with_neon)),neon)
 
155
add_on_dirs = thumb-2 $(submachine) $(neon_dirs)
 
156
 
135
157
add_on_src = \
136
158
        $(wildcard $(add_on_dirs:%=$(srcdir)/src/%/*.c)) \
137
159
        $(wildcard $(add_on_dirs:%=$(srcdir)/src/%/*.S)) \