From 7a384fde367c1436d39e94fe597ce3bfa05ceeb5 Mon Sep 17 00:00:00 2001 From: Ingo Weinhold Date: Thu, 26 Sep 2002 22:31:53 +0000 Subject: [PATCH] Extended the Addon rule by another parameter: . Supply "true" to prevent the usage of the -nostart linker option. git-svn-id: file:///srv/svn/repos/haiku/trunk/current@1196 a95241bf-73f2-0310-859d-f6bbb57e9c96 --- Jamrules | 16 +++++++++++++--- 1 file changed, 13 insertions(+), 3 deletions(-) diff --git a/Jamrules b/Jamrules index 30ce976af2..8c1b72374e 100644 --- a/Jamrules +++ b/Jamrules @@ -508,7 +508,13 @@ rule SimpleTest rule Addon { - # Addon : : ; + # Addon : : : ; + # : Name of the add-on. + # : Path where the add-on shall live relative to the add-on dir. + # : Source files. + # : true, if the target shall be executable as well + + local isExecutable = $(4) ; # SetupIncludes ; SetupObjectsDir ; @@ -519,8 +525,12 @@ rule Addon targetdir = [ FDirName $(OBOS_ADDON_DIR) $(2) ] ; MakeLocate $(1) : $(targetdir) ; - LINKFLAGS on $(1) = [ on $(1) return $(LINKFLAGS) ] - -nostart -Xlinker -soname=\"$(1)\" ; + + local linkFlags = -Xlinker -soname=\"$(1)\" ; + if $(isExecutable) != true { + linkFlags = -nostart $(linkFlags) ; + } + LINKFLAGS on $(1) = [ on $(1) return $(LINKFLAGS) ] $(linkFlags) ; } rule R5KernelAddon