[129516] trunk/dports/lang/llvm-3.6

larryv at macports.org larryv at macports.org
Sun Dec 14 23:55:02 PST 2014


Revision: 129516
          https://trac.macports.org/changeset/129516
Author:   larryv at macports.org
Date:     2014-12-14 23:55:02 -0800 (Sun, 14 Dec 2014)
Log Message:
-----------
clang-3.6: Use a patch to omit ARM runtime (#46119)

The current `reinplace` substitutions don't work with the latest
makefiles. Replacing them with a patch fixes the `-arm_runtime` build
failures and should prevent future hard-to-find replacement errors.

Modified Paths:
--------------
    trunk/dports/lang/llvm-3.6/Portfile

Added Paths:
-----------
    trunk/dports/lang/llvm-3.6/files/disable-arm-runtime.patch

Modified: trunk/dports/lang/llvm-3.6/Portfile
===================================================================
--- trunk/dports/lang/llvm-3.6/Portfile	2014-12-15 07:54:56 UTC (rev 129515)
+++ trunk/dports/lang/llvm-3.6/Portfile	2014-12-15 07:55:02 UTC (rev 129516)
@@ -107,6 +107,10 @@
                          move-clang-resources.patch \
                          fix-libclang_rt-dylib-ids.patch \
                          lion-xcrun-fallback.patch
+    if {![variant_isset arm_runtime]} {
+        # Alternate fix for #33272.
+        patchfiles-append   disable-arm-runtime.patch
+    }
 
     build.target        clang-only
     destroot.target     install-clang
@@ -234,15 +238,6 @@
 
 post-patch {
     if {${subport} eq "clang-${llvm_version}"} {
-        # http://trac.macports.org/ticket/33272
-        if {![variant_isset arm_runtime]} {
-            reinplace {/^SubDirs/ s/arm//} ${worksrcpath}/projects/compiler-rt/lib/Makefile.mk
-            reinplace {/^UniversalArchs/ s/arm[^ )]* *//g} ${worksrcpath}/projects/compiler-rt/make/platform/clang_darwin.mk
-
-            reinplace {/cc_kext_ios5/ s/^/#/} ${worksrcpath}/projects/compiler-rt/make/platform/clang_darwin.mk
-            reinplace {s/cc_kext_ios5.a//} ${worksrcpath}/tools/clang/runtime/compiler-rt/Makefile
-        }
-
         reinplace {s/VERBOSE := 0/VERBOSE := 1/} ${worksrcpath}/projects/compiler-rt/make/config.mk
 
         reinplace "s|@@PREFIX@@|${prefix}|g" \

Added: trunk/dports/lang/llvm-3.6/files/disable-arm-runtime.patch
===================================================================
--- trunk/dports/lang/llvm-3.6/files/disable-arm-runtime.patch	                        (rev 0)
+++ trunk/dports/lang/llvm-3.6/files/disable-arm-runtime.patch	2014-12-15 07:55:02 UTC (rev 129516)
@@ -0,0 +1,36 @@
+Index: llvm-3.6svn/projects/compiler-rt/make/platform/clang_darwin.mk
+===================================================================
+--- llvm-3.6svn.orig/projects/compiler-rt/make/platform/clang_darwin.mk
++++ llvm-3.6svn/projects/compiler-rt/make/platform/clang_darwin.mk
+@@ -101,7 +101,6 @@ UniversalArchs.cc_kext += $(call CheckAr
+ # Configuration for use with kernel/kexts for iOS 5.0 and earlier (which used 
+ # a different code generation strategy). Note: the x86_64 slice is unused but
+ # it avoids build problems (see pr14013).
+-Configs += cc_kext_ios5
+ UniversalArchs.cc_kext_ios5 := $(call CheckArches,x86_64,cc_kext_ios5,$(IOSSIM_SDK))
+ UniversalArchs.cc_kext_ios5 += $(call CheckArches,armv7,cc_kext_ios5,$(IOS_SDK))
+ 
+@@ -133,6 +132,8 @@ UniversalArchs.ubsan_osx := $(call Check
+ #UniversalArchs.profile_ios := $(filter-out armv7, $(UniversalArchs.profile_ios))
+ #endif
+ 
++RC_SUPPORTED_ARCHS := i386 x86_64 x86_64h
++
+ # If RC_SUPPORTED_ARCHS is defined, treat it as a list of the architectures we
+ # are intended to support and limit what we try to build to that.
+ ifneq ($(RC_SUPPORTED_ARCHS),)
+Index: llvm-3.6svn/tools/clang/runtime/compiler-rt/Makefile
+===================================================================
+--- llvm-3.6svn.orig/tools/clang/runtime/compiler-rt/Makefile
++++ llvm-3.6svn/tools/clang/runtime/compiler-rt/Makefile
+@@ -99,10 +99,6 @@ ifneq ($(IOS_SDK)$(IOSSIM_SDK),)
+ RuntimeLibrary.darwin.Configs += ios.a profile_ios.a
+ endif
+ 
+-ifneq ($(IOS_SDK),)
+-RuntimeLibrary.darwin.Configs += cc_kext_ios5.a
+-endif
+-
+ ifneq ($(IOSSIM_SDK),)
+ RuntimeLibrary.darwin.Configs += asan_iossim_dynamic.dylib
+ endif
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://lists.macosforge.org/pipermail/macports-changes/attachments/20141214/b8d0c551/attachment-0001.html>


More information about the macports-changes mailing list