8062312: OpenJDK build fails when bundling freetype libraries
authorsimonis
Wed, 29 Oct 2014 14:51:51 +0100
changeset 27293 901a9a6f8658
parent 27292 7ff4b24b33ce
child 27294 dfd89723bd6f
child 27296 43273a116265
8062312: OpenJDK build fails when bundling freetype libraries Reviewed-by: prr, erikj
jdk/make/copy/Copy-java.desktop.gmk
--- a/jdk/make/copy/Copy-java.desktop.gmk	Wed Oct 29 14:10:34 2014 +0100
+++ b/jdk/make/copy/Copy-java.desktop.gmk	Wed Oct 29 14:51:51 2014 +0100
@@ -67,8 +67,11 @@
     FREETYPE_TARGET_LIB := $(JDK_OUTPUTDIR)/lib$(OPENJDK_TARGET_CPU_LIBDIR)/$(call SHARED_LIBRARY,freetype).6
   endif
 
+  # We can't use $(install-file) in this rule because it preserves symbolic links and
+  # libfreetype.so is usually a symbolic link to something like libfreetype.so.6 on Unix.
   $(FREETYPE_TARGET_LIB): $(FREETYPE_BUNDLE_LIB_PATH)/$(call SHARED_LIBRARY,freetype)
-	$(install-file)
+	$(MKDIR) -p $(@D)
+	$(CP) $< $@
         ifeq ($(OPENJDK_BUILD_OS), windows)
 	  $(CHMOD) +rx $@
         endif