summaryrefslogtreecommitdiff
path: root/modules
diff options
context:
space:
mode:
authorEric Blake <eblake@redhat.com>2011-07-15 15:08:34 -0600
committerEric Blake <eblake@redhat.com>2011-07-15 15:13:31 -0600
commit9c6e26caf1aeb2f0de445dc3fa568b6e82701bc2 (patch)
tree8078d3098f8a0b04d6b93434dddc344b0318b75d /modules
parent634254cdcf5136652dc851a6e34431c554348ddb (diff)
downloadgnulib-9c6e26caf1aeb2f0de445dc3fa568b6e82701bc2.tar.gz
ffsl, ffsll: new modules
* modules/ffsl: New file. * modules/ffsll: Likewise. * m4/ffsl.m4: Likewise. * m4/ffsll.m4: Likewise. * lib/ffsl.c: Likewise. * lib/ffsl.h: Likewise. * lib/ffsll.c: Likewise. * m4/string_h.m4 (gl_HEADER_STRING_H_BODY) (gl_HEADER_STRING_H_DEFAULTS): Add defaults. * modules/string (Makefile.am): Substitute witnesses. * lib/strings.in.h (ffsl, ffsll): Declare. * modules/ffsl-tests: New test file. * modules/ffsll-tests: Likewise. * tests/test-ffsl.c: Likewise. * tests/test-ffsll.c: Likewise. * MODULES.html.sh (Integer arithmetic functions): Mention it. * doc/glibc-functions/ffsl.texi (ffsl): Likewise. * doc/glibc-functions/ffsll.texi (ffsll): Likewise. Signed-off-by: Eric Blake <eblake@redhat.com>
Diffstat (limited to 'modules')
-rw-r--r--modules/ffsl30
-rw-r--r--modules/ffsl-tests12
-rw-r--r--modules/ffsll30
-rw-r--r--modules/ffsll-tests12
-rw-r--r--modules/string6
5 files changed, 89 insertions, 1 deletions
diff --git a/modules/ffsl b/modules/ffsl
new file mode 100644
index 0000000000..a3217ec08e
--- /dev/null
+++ b/modules/ffsl
@@ -0,0 +1,30 @@
+Description:
+Finds the index of the least-significant set bit.
+
+Files:
+lib/ffsl.h
+lib/ffsl.c
+m4/ffsl.m4
+
+Depends-on:
+extensions
+string
+ffs [test $HAVE_FFSL = 0]
+
+configure.ac:
+gl_FUNC_FFSL
+if test $HAVE_FFSL = 0; then
+ AC_LIBOBJ([ffsl])
+fi
+gl_STRING_MODULE_INDICATOR([ffsl])
+
+Makefile.am:
+
+Include:
+<string.h>
+
+License:
+LGPLv2+
+
+Maintainer:
+Eric Blake
diff --git a/modules/ffsl-tests b/modules/ffsl-tests
new file mode 100644
index 0000000000..25154af0de
--- /dev/null
+++ b/modules/ffsl-tests
@@ -0,0 +1,12 @@
+Files:
+tests/test-ffsl.c
+tests/macros.h
+tests/signature.h
+
+Depends-on:
+
+configure.ac:
+
+Makefile.am:
+TESTS += test-ffsl
+check_PROGRAMS += test-ffsl
diff --git a/modules/ffsll b/modules/ffsll
new file mode 100644
index 0000000000..7caf10048c
--- /dev/null
+++ b/modules/ffsll
@@ -0,0 +1,30 @@
+Description:
+Finds the index of the least-significant set bit.
+
+Files:
+lib/ffsl.h
+lib/ffsll.c
+m4/ffsll.m4
+
+Depends-on:
+extensions
+string
+ffs [test $HAVE_FFSLL = 0]
+
+configure.ac:
+gl_FUNC_FFSLL
+if test $HAVE_FFSLL = 0; then
+ AC_LIBOBJ([ffsll])
+fi
+gl_STRING_MODULE_INDICATOR([ffsl])
+
+Makefile.am:
+
+Include:
+<string.h>
+
+License:
+LGPLv2+
+
+Maintainer:
+Eric Blake
diff --git a/modules/ffsll-tests b/modules/ffsll-tests
new file mode 100644
index 0000000000..759f382543
--- /dev/null
+++ b/modules/ffsll-tests
@@ -0,0 +1,12 @@
+Files:
+tests/test-ffsll.c
+tests/macros.h
+tests/signature.h
+
+Depends-on:
+
+configure.ac:
+
+Makefile.am:
+TESTS += test-ffsll
+check_PROGRAMS += test-ffsll
diff --git a/modules/string b/modules/string
index a78508cdeb..2f5471b1f2 100644
--- a/modules/string
+++ b/modules/string
@@ -29,6 +29,8 @@ string.h: string.in.h $(top_builddir)/config.status $(CXXDEFS_H) $(ARG_NONNULL_H
-e 's|@''PRAGMA_SYSTEM_HEADER''@|@PRAGMA_SYSTEM_HEADER@|g' \
-e 's|@''PRAGMA_COLUMNS''@|@PRAGMA_COLUMNS@|g' \
-e 's|@''NEXT_STRING_H''@|$(NEXT_STRING_H)|g' \
+ -e 's/@''GNULIB_FFSL''@/$(GNULIB_FFSL)/g' \
+ -e 's/@''GNULIB_FFSLL''@/$(GNULIB_FFSLL)/g' \
-e 's/@''GNULIB_MBSLEN''@/$(GNULIB_MBSLEN)/g' \
-e 's/@''GNULIB_MBSNLEN''@/$(GNULIB_MBSNLEN)/g' \
-e 's/@''GNULIB_MBSCHR''@/$(GNULIB_MBSCHR)/g' \
@@ -65,7 +67,9 @@ string.h: string.in.h $(top_builddir)/config.status $(CXXDEFS_H) $(ARG_NONNULL_H
-e 's/@''GNULIB_STRSIGNAL''@/$(GNULIB_STRSIGNAL)/g' \
-e 's/@''GNULIB_STRVERSCMP''@/$(GNULIB_STRVERSCMP)/g' \
< $(srcdir)/string.in.h | \
- sed -e 's|@''HAVE_MBSLEN''@|$(HAVE_MBSLEN)|g' \
+ sed -e 's|@''HAVE_FFSL''@|$(HAVE_FFSL)|g' \
+ -e 's|@''HAVE_FFSLL''@|$(HAVE_FFSLL)|g' \
+ -e 's|@''HAVE_MBSLEN''@|$(HAVE_MBSLEN)|g' \
-e 's|@''HAVE_MEMCHR''@|$(HAVE_MEMCHR)|g' \
-e 's|@''HAVE_DECL_MEMMEM''@|$(HAVE_DECL_MEMMEM)|g' \
-e 's|@''HAVE_MEMPCPY''@|$(HAVE_MEMPCPY)|g' \