jjb: Fix ppc64el linux build for modules
authorMichael Jeanson <mjeanson@efficios.com>
Thu, 17 Oct 2019 20:32:43 +0000 (16:32 -0400)
committerMichael Jeanson <mjeanson@efficios.com>
Thu, 17 Oct 2019 20:32:43 +0000 (16:32 -0400)
Signed-off-by: Michael Jeanson <mjeanson@efficios.com>
scripts/lttng-modules/param-build.sh

index 21e219cb33d2a30364312333d7b73a489dbe29ca..e016e135173081916b6c728f8daa22e7448970a7 100644 (file)
@@ -312,9 +312,11 @@ extract_distro_headers() {
     rm -f "${LINUX_HDROBJ_DIR}/scripts/*.o"
     rm -f "${LINUX_HDROBJ_DIR}/scripts/*/*.o"
 
-    # On powerpc this object is required to link modules
+    # On powerpc 32bits this object is required to link modules
     if [ "${karch}" = "powerpc" ]; then
-        cp -a --parents arch/powerpc/lib/crtsavres.[So] "${LINUX_HDROBJ_DIR}/"
+        if [ "x$(scripts/config -s CONFIG_PPC64)" = "xn" ]; then
+            cp -a --parents arch/powerpc/lib/crtsavres.[So] "${LINUX_HDROBJ_DIR}/"
+        fi
     fi
 
     # On arm64 between 4.13 and 1.15 this object is required to build with ftrace support
@@ -370,9 +372,11 @@ extract_distro_headers() {
     # And regen the modules support files
     make modules_prepare CC="$CC"
 
-    # On powerpc this object is required to link modules
+    # On powerpc 32bits this object is required to link modules
     if [ "${karch}" = "powerpc" ]; then
-        make arch/powerpc/lib/crtsavres.o CC="$CC"
+        if [ "x$(scripts/config -s CONFIG_PPC64)" = "xn" ]; then
+            make arch/powerpc/lib/crtsavres.o CC="$CC"
+        fi
     fi
 
     # On arm64 between 4.13 and 4.15 this object is required to build with ftrace support
@@ -558,7 +562,7 @@ elif [ "x${arch}" != "x" ]; then
             ;;
     esac
 else
-    echo "Not arch or cross_arch specified"
+    echo "No arch or cross_arch specified"
     exit 1
 fi
 
This page took 0.023463 seconds and 4 git commands to generate.