summaryrefslogtreecommitdiff
path: root/sysdeps/powerpc/ffs.c
diff options
context:
space:
mode:
authorUlrich Drepper <drepper@redhat.com>2004-04-04 05:53:24 +0000
committerUlrich Drepper <drepper@redhat.com>2004-04-04 05:53:24 +0000
commit4e73e1151d457981323a7316861a2493a57dbc6c (patch)
tree0463068f1077177d19586e8251b05c6b8c26ea97 /sysdeps/powerpc/ffs.c
parentecb2b2fb8aca5aacdae057257891e426d2f32b2f (diff)
Update.
* string/test-ffs.c: Also test ffsl and ffsll. * sysdeps/powerpc/ffs.c: Don't define ffsl for ppc64.
Diffstat (limited to 'sysdeps/powerpc/ffs.c')
-rw-r--r--sysdeps/powerpc/ffs.c5
1 files changed, 4 insertions, 1 deletions
diff --git a/sysdeps/powerpc/ffs.c b/sysdeps/powerpc/ffs.c
index 60f7460886..b2b7b7c071 100644
--- a/sysdeps/powerpc/ffs.c
+++ b/sysdeps/powerpc/ffs.c
@@ -1,6 +1,6 @@
/* Find first set bit in a word, counted from least significant end.
For PowerPC.
- Copyright (C) 1991, 1992, 1997, 1998 Free Software Foundation, Inc.
+ Copyright (C) 1991, 1992, 1997, 1998, 2004 Free Software Foundation, Inc.
This file is part of the GNU C Library.
Contributed by Torbjorn Granlund (tege@sics.se).
@@ -20,6 +20,7 @@
02111-1307 USA. */
#define ffsl __something_else
+#include <limits.h>
#include <string.h>
#undef ffs
@@ -35,8 +36,10 @@ __ffs (int x)
return 32 - cnt;
}
weak_alias (__ffs, ffs)
+#if ULONG_MAX == UINT_MAX
#undef ffsl
weak_alias (__ffs, ffsl)
+#endif
#else
#include <sysdeps/generic/ffs.c>