2001-03-16 22:47:14 +00:00
|
|
|
/* vi: set sw=4 ts=4: */
|
|
|
|
/*
|
2007-10-10 14:41:07 +00:00
|
|
|
* Stub for linking busybox binary against libbusybox.
|
2001-03-16 22:47:14 +00:00
|
|
|
*
|
2007-10-10 14:41:07 +00:00
|
|
|
* Copyright (C) 2007 Denis Vlasenko
|
2001-03-16 22:47:14 +00:00
|
|
|
*
|
2007-10-10 14:41:07 +00:00
|
|
|
* Licensed under GPLv2, see file License in this tarball for details.
|
2001-03-16 22:47:14 +00:00
|
|
|
*/
|
|
|
|
|
2004-02-01 10:03:05 +00:00
|
|
|
#include <assert.h>
|
2007-02-03 17:27:14 +00:00
|
|
|
#include "busybox.h"
|
|
|
|
|
2006-11-09 00:00:12 +00:00
|
|
|
/* Apparently uclibc defines __GLIBC__ (compat trick?). Oh well. */
|
|
|
|
#if ENABLE_STATIC && defined(__GLIBC__) && !defined(__UCLIBC__)
|
2006-10-20 13:42:57 +00:00
|
|
|
#warning Static linking against glibc produces buggy executables
|
2006-11-10 23:25:53 +00:00
|
|
|
#warning (glibc does not cope well with ld --gc-sections).
|
2006-10-29 19:37:13 +00:00
|
|
|
#warning See sources.redhat.com/bugzilla/show_bug.cgi?id=3400
|
2006-12-18 21:49:06 +00:00
|
|
|
#warning Note that glibc is unsuitable for static linking anyway.
|
|
|
|
#warning If you still want to do it, remove -Wl,--gc-sections
|
2007-11-05 19:31:01 +00:00
|
|
|
#warning from scripts/trylink and remove this warning.
|
2007-05-18 07:37:06 +00:00
|
|
|
#error Aborting compilation.
|
2006-10-20 13:42:57 +00:00
|
|
|
#endif
|
|
|
|
|
2007-10-10 14:41:07 +00:00
|
|
|
#if ENABLE_BUILD_LIBBUSYBOX
|
2007-04-09 03:05:48 +00:00
|
|
|
int main(int argc, char **argv)
|
|
|
|
{
|
2007-10-11 10:05:36 +00:00
|
|
|
return lbb_main(argc, argv);
|
2007-04-09 03:05:48 +00:00
|
|
|
}
|
2007-10-10 14:41:07 +00:00
|
|
|
#endif
|