PowerPC: Fix -Wundef warning for __PTHREAD_MUTEX_HAVE_ELISION.
[glibc.git] / string / Makefile
blob5a76872131698e77d6b5d0504089b939240e9b81
1 # Copyright (C) 1991-2014 Free Software Foundation, Inc.
2 # This file is part of the GNU C Library.
4 # The GNU C Library is free software; you can redistribute it and/or
5 # modify it under the terms of the GNU Lesser General Public
6 # License as published by the Free Software Foundation; either
7 # version 2.1 of the License, or (at your option) any later version.
9 # The GNU C Library is distributed in the hope that it will be useful,
10 # but WITHOUT ANY WARRANTY; without even the implied warranty of
11 # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
12 # Lesser General Public License for more details.
14 # You should have received a copy of the GNU Lesser General Public
15 # License along with the GNU C Library; if not, see
16 # <http://www.gnu.org/licenses/>.
19 # Sub-makefile for string portion of library.
21 subdir := string
23 include ../Makeconfig
25 headers := string.h strings.h memory.h endian.h bits/endian.h \
26 argz.h envz.h byteswap.h bits/byteswap.h bits/byteswap-16.h \
27 bits/string.h bits/string2.h bits/string3.h
29 routines := strcat strchr strcmp strcoll strcpy strcspn \
30 strverscmp strdup strndup \
31 strerror _strerror strlen strnlen \
32 strncat strncmp strncpy \
33 strrchr strpbrk strsignal strspn strstr strtok \
34 strtok_r strxfrm memchr memcmp memmove memset \
35 mempcpy bcopy bzero ffs ffsll stpcpy stpncpy \
36 strcasecmp strncase strcasecmp_l strncase_l \
37 memccpy memcpy wordcopy strsep strcasestr \
38 swab strfry memfrob memmem rawmemchr strchrnul \
39 $(addprefix argz-,append count create ctsep next \
40 delete extract insert stringify \
41 addsep replace) \
42 envz basename \
43 strcoll_l strxfrm_l string-inlines memrchr \
44 xpg-strerror strerror_l
46 strop-tests := memchr memcmp memcpy memmove mempcpy memset memccpy \
47 stpcpy stpncpy strcat strchr strcmp strcpy strcspn \
48 strlen strncmp strncpy strpbrk strrchr strspn memmem \
49 strstr strcasestr strnlen strcasecmp strncasecmp \
50 strncat rawmemchr strchrnul bcopy bzero memrchr
51 tests := tester inl-tester noinl-tester testcopy test-ffs \
52 tst-strlen stratcliff tst-svc tst-inlcall \
53 bug-strncat1 bug-strspn1 bug-strpbrk1 tst-bswap \
54 tst-strtok tst-strxfrm bug-strcoll1 tst-strfry \
55 bug-strtok1 $(addprefix test-,$(strop-tests)) \
56 bug-envz1 tst-strxfrm2 tst-endian tst-svc2 \
57 tst-strtok_r
59 xtests = tst-strcoll-overflow
61 ifeq ($(run-built-tests),yes)
62 tests-special += $(objpfx)tst-svc-cmp.out
63 endif
65 include ../Rules
67 tester-ENV = LANGUAGE=C
68 inl-tester-ENV = LANGUAGE=C
69 noinl-tester-ENV = LANGUAGE=C
70 tst-strxfrm-ENV = LOCPATH=$(common-objpfx)localedata
71 tst-strxfrm2-ENV = LOCPATH=$(common-objpfx)localedata
72 bug-strcoll1-ENV = LOCPATH=$(common-objpfx)localedata
73 test-strcasecmp-ENV = LOCPATH=$(common-objpfx)localedata
74 test-strncasecmp-ENV = LOCPATH=$(common-objpfx)localedata
75 CFLAGS-inl-tester.c = -fno-builtin
76 CFLAGS-noinl-tester.c = -fno-builtin
77 CFLAGS-tst-strlen.c = -fno-builtin
78 CFLAGS-stratcliff.c = -fno-builtin
79 CFLAGS-test-ffs.c = -fno-builtin
80 CFLAGS-tst-inlcall.c = -fno-builtin
82 ifeq ($(run-built-tests),yes)
83 $(objpfx)tst-svc-cmp.out: tst-svc.expect $(objpfx)tst-svc.out
84 cmp $^ > $@; \
85 $(evaluate-test)
86 endif