Module: xenomai-3 Branch: stable-3.0.x Commit: 48b2e57e29ca1c33eba14abb4b5eaa15431130fa URL: http://git.xenomai.org/?p=xenomai-3.git;a=commit;h=48b2e57e29ca1c33eba14abb4b5eaa15431130fa
Author: Philippe Gerum <r...@xenomai.org> Date: Tue May 30 09:03:41 2017 +0200 lib/copperplate: drop useless wrapper to main() Referencing __real_main() only makes sense from the bootstrap module (boilerplate/init), which is glued to a DSO/final executable when symbol wrapping is in effect, exclusively. The wrapper found in copperplate is a left over from a former implementation of the auto init feature, which may cause an undefined reference to main() when loading libcopperplate.so dynamically. Let's drop it. --- lib/copperplate/Makefile.am | 3 +-- lib/copperplate/wrappers.c | 27 --------------------------- 2 files changed, 1 insertion(+), 29 deletions(-) diff --git a/lib/copperplate/Makefile.am b/lib/copperplate/Makefile.am index 3546e72..2ad5e1e 100644 --- a/lib/copperplate/Makefile.am +++ b/lib/copperplate/Makefile.am @@ -16,8 +16,7 @@ libcopperplate_la_SOURCES = \ semobj.c \ threadobj.c \ timerobj.c \ - traceobj.c \ - wrappers.c + traceobj.c libcopperplate_la_CPPFLAGS = \ @XENO_USER_CFLAGS@ \ diff --git a/lib/copperplate/wrappers.c b/lib/copperplate/wrappers.c deleted file mode 100644 index 9d2490c..0000000 --- a/lib/copperplate/wrappers.c +++ /dev/null @@ -1,27 +0,0 @@ -/* - * Copyright (C) 2013 Philippe Gerum <r...@xenomai.org>. - * - * This library is free software; you can redistribute it and/or - * modify it under the terms of the GNU Lesser General Public - * License as published by the Free Software Foundation; either - * version 2 of the License, or (at your option) any later version. - * - * This library is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU - * Lesser General Public License for more details. - - * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free Software - * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA. - */ -#include <boilerplate/compiler.h> - -int main(int argc, char *const argv[]); - -int __real_main(int argc, char *const argv[]); - -__weak int __real_main(int argc, char *const argv[]) -{ - return main(argc, argv); -} _______________________________________________ Xenomai-git mailing list Xenomai-git@xenomai.org https://xenomai.org/mailman/listinfo/xenomai-git