< prev index next >

jdk/make/launcher/LauncherCommon.gmk

Print this page

        

@@ -1,7 +1,7 @@
 #
-# Copyright (c) 2011, 2015, Oracle and/or its affiliates. All rights reserved.
+# Copyright (c) 2011, 2016, Oracle and/or its affiliates. All rights reserved.
 # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
 #
 # This code is free software; you can redistribute it and/or modify it
 # under the terms of the GNU General Public License version 2 only, as
 # published by the Free Software Foundation.  Oracle designates this

@@ -120,11 +120,11 @@
           $(SUPPORT_OUTPUTDIR)/modules_libs/jdk.jdwp.agent/libjdwp.a \
           $(SUPPORT_OUTPUTDIR)/native/java.base/$(LIBRARY_PREFIX)fdlibm$(STATIC_LIBRARY_SUFFIX) \
           -framework CoreFoundation \
           -framework Foundation \
           -framework SystemConfiguration \
-          -lstdc++ -liconv
+          -lstdc++ $(ICONV_LIBS)
     else
       $1_LIBS += $(SUPPORT_OUTPUTDIR)/native/java.base/libjli_static.a
     endif
     $1_LIBS += -framework Cocoa -framework Security \
         -framework ApplicationServices

@@ -133,10 +133,19 @@
   ifeq ($(OPENJDK_TARGET_OS), aix)
     $1_LDFLAGS += -L$(SUPPORT_OUTPUTDIR)/native/java.base
     $1_LIBS += -ljli_static
   endif
 
+  ifeq ($(OPENJDK_TARGET_OS), bsd)
+    ifeq ($(OPENJDK_TARGET_OS_ENV), bsd.netbsd)
+      $1_LDFLAGS += -L$(SUPPORT_OUTPUTDIR)/native/java.base
+      $1_LIBS += -ljli_static
+    else
+      $1_LIBS += -ljli
+    endif
+  endif
+
   ifeq ($(USE_EXTERNAL_LIBZ), true)
     $1_LIBS += -lz
   endif
 
   ifeq ($$($1_WINDOWS_STATIC_LINK), true)

@@ -148,21 +157,20 @@
   endif
 
   # The linker on older SuSE distros (e.g. on SLES 10) complains with:
   # "Invalid version tag `SUNWprivate_1.1'. Only anonymous version tag is allowed in executable."
   # if feeded with a version script which contains named tags.
+  $1_MAPFILE :=
   ifeq ($(USING_BROKEN_SUSE_LD),yes)
     ifneq ($(wildcard $(JDK_TOPDIR)/make/mapfiles/launchers/mapfile-$(OPENJDK_TARGET_CPU).anonymous), )
       $1_MAPFILE := $(JDK_TOPDIR)/make/mapfiles/launchers/mapfile-$(OPENJDK_TARGET_CPU).anonymous
-    else
-      $1_MAPFILE :=
     endif
   else
+    ifneq ($(OPENJDK_TARGET_OS), bsd)
     ifneq ($(wildcard $(JDK_TOPDIR)/make/mapfiles/launchers/mapfile-$(OPENJDK_TARGET_CPU)), )
       $1_MAPFILE := $(JDK_TOPDIR)/make/mapfiles/launchers/mapfile-$(OPENJDK_TARGET_CPU)
-    else
-      $1_MAPFILE :=
+      endif
     endif
   endif
 
   $$(eval $$(call SetupNativeCompilation, BUILD_LAUNCHER_$1, \
       EXTRA_FILES := $(LAUNCHER_SRC)/main.c, \

@@ -181,15 +189,18 @@
           $$($1_LDFLAGS), \
       LDFLAGS_linux := \
           -L$(SUPPORT_OUTPUTDIR)/modules_libs/java.base$(OPENJDK_TARGET_CPU_LIBDIR)/jli, \
       LDFLAGS_solaris := $$($1_LDFLAGS_solaris) \
           -L$(SUPPORT_OUTPUTDIR)/modules_libs/java.base$(OPENJDK_TARGET_CPU_LIBDIR)/jli, \
+      LDFLAGS_bsd := \
+          -L$(SUPPORT_OUTPUTDIR)/modules_libs/java.base$(OPENJDK_TARGET_CPU_LIBDIR)/jli, \
       MAPFILE := $$($1_MAPFILE), \
       LIBS := $(JDKEXE_LIBS) $$($1_LIBS), \
       LIBS_unix := $$($1_LIBS_unix), \
       LIBS_linux := -lpthread -ljli $(LIBDL) -lc, \
       LIBS_solaris := -ljli -lthread $(LIBDL) -lc, \
+      LIBS_bsd := -lpthread, \
       LIBS_windows := $$($1_WINDOWS_JLI_LIB) \
           $(SUPPORT_OUTPUTDIR)/native/java.base/libjava/java.lib advapi32.lib \
           $$($1_LIBS_windows), \
       OBJECT_DIR := $(SUPPORT_OUTPUTDIR)/native/$(MODULE)/$1_objs, \
       OUTPUT_DIR := $$($1_OUTPUT_DIR), \
< prev index next >