Change build-llvm.py and build-lldb-llvm-clang's patching mechanisms to
authorJason Molenda <jmolenda@apple.com>
Wed, 27 Sep 2017 23:44:54 +0000 (23:44 +0000)
committerJason Molenda <jmolenda@apple.com>
Wed, 27 Sep 2017 23:44:54 +0000 (23:44 +0000)
assume git-style diffs.  Committing for Francis Ricci.

Differential Revision: https://reviews.llvm.org/D38328

llvm-svn: 314366

lldb/scripts/Xcode/build-llvm.py
lldb/scripts/build-lldb-llvm-clang

index 4a18abe..4d868de 100755 (executable)
@@ -224,7 +224,7 @@ def apply_patches(spec):
             f, spec['name'] + '.*.diff')]
     for p in patches:
         run_in_directory(["patch",
-                          "-p0",
+                          "-p1",
                           "-i",
                           os.path.join(lldb_source_path(),
                                        'scripts',
index 822e994..c71188d 100755 (executable)
@@ -33,7 +33,7 @@ cd ..
 for patch_file in ../scripts/llvm.*.diff
 do
        echo "Applying patch from '$patch_file'"
-    patch -p0 < "$patch_file"
+    patch -p1 < "$patch_file"
 done
 
 # change directory to "./llvm/tools/clang"
@@ -41,7 +41,7 @@ cd tools/clang
 for patch_file in ../../../scripts/clang.*.diff
 do
        echo "Applying patch from '$patch_file'"
-    patch -p0 < "$patch_file"
+    patch -p1 < "$patch_file"
 done
 
 # change directory to "./"