1 | /* Ensures that the FINDLIB_REPLACE_FUNCS macro in configure.in works
|
---|
2 | Copyright (C) 2004 Free Software Foundation, Inc.
|
---|
3 |
|
---|
4 | This program is free software; you can redistribute it and/or modify
|
---|
5 | it under the terms of the GNU General Public License as published by
|
---|
6 | the Free Software Foundation; either version 2, or (at your option)
|
---|
7 | any later version.
|
---|
8 |
|
---|
9 | This program 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
|
---|
12 | GNU General Public License for more details.
|
---|
13 |
|
---|
14 | You should have received a copy of the GNU General Public License
|
---|
15 | along with this program; if not, write to the Free Software
|
---|
16 | Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301,
|
---|
17 | USA.
|
---|
18 | */
|
---|
19 |
|
---|
20 | /* Written by James Youngman. */
|
---|
21 |
|
---|
22 |
|
---|
23 | #ifdef HAVE_CONFIG_H
|
---|
24 | #include <config.h>
|
---|
25 | #endif
|
---|
26 |
|
---|
27 |
|
---|
28 | extern void forcefindlib(void); /* prevent GCC warning... */
|
---|
29 |
|
---|
30 |
|
---|
31 |
|
---|
32 | /* forcefindlib
|
---|
33 | *
|
---|
34 | * This function exists only to be pulled into libfind.a by the
|
---|
35 | * FINDLIB_REPLACE_FUNCS macro in configure.in. We already have
|
---|
36 | * AC_REPLACE_FUNCS, but that adds to LIBOBJS, and that's a gnulib thing
|
---|
37 | * in the case of findutils. Hence we have out own library of replacement
|
---|
38 | * functions which aren't in gnulib (or aren't in it any more). An example
|
---|
39 | * of this is waitpid(). I develop on a system that doesn't
|
---|
40 | * lack waitpid, for example. Therefore FINDLIB_REPLACE_FUNCS(waitpid)
|
---|
41 | * never puts waitpid.o into FINDLIBOBJS. Hence, to ensure that these
|
---|
42 | * macros are tested every time, we use FINDLIB_REPLACE_FUNCS on a function
|
---|
43 | * that never exists anywhere, so always needs to be pulled in. That function
|
---|
44 | * is forcefindlib().
|
---|
45 | */
|
---|
46 | void
|
---|
47 | forcefindlib(void)
|
---|
48 | {
|
---|
49 | /* does nothing, exists only to ensure that FINDLIB_REPLACE_FUNCS works. */
|
---|
50 | }
|
---|