Skip to contentSkip to conversation

Fix inclusion of new object files

PATCH In review Andrew Cooper 3 participants 3 messages Feb 23, 2024

lore
Share & tools
lore
#0 lore raw

PATCH 1/1 Fix inclusion of new object files

Right now, there's a mixup over the xen/ part of the path for new files.

+ NEW_FILES=./arch/x86/lp-hooks.o
+ for i in '$NEW_FILES'
++ dirname ./arch/x86/lp-hooks.o
+ mkdir -p output/./arch/x86
+ cp patched/./arch/x86/lp-hooks.o output/./arch/x86/lp-hooks.o
cp: cannot stat 'patched/./arch/x86/lp-hooks.o': No such file or directory

Alter the cd and find runes to use paths relative to the root of the different source trees.

---
CC: Roger Pau Monné <[email protected]>
CC: Ross Lagerwall <[email protected]>

I'm unsure whether there's a useful fixes tag to use. AFAICT it was broken even when 0564f0c7a57 claimed to have it working.

---
 livepatch-build | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
livepatch-build +1 -1
index cdb852cc7fea..948b2acfc2f6 100755
@@ -227,7 +227,7 @@ function create_patch()
         fi
     done
 
-    NEW_FILES=$(comm -23 <(cd patched/xen && find . -type f -name '*.o' | sort) <(cd original/xen && find . -type f -name '*.o' | sort))
+    NEW_FILES=$(comm -23 <(cd patched && find xen/ -type f -name '*.o' | sort) <(cd original && find xen/ -type f -name '*.o' | sort))
     for i in $NEW_FILES; do
         mkdir -p "output/$(dirname "$i")"
         cp "patched/$i" "output/$i"

base-commit: 1b5b03b3ce4187ce99bad580fd0ee36c6337313f

Signature · 1 line
2.30.2
Reviewed-by on v1 1/1
#1 lore raw
Quoted 38 lines · Andrew Cooper

Right now, there's a mixup over the xen/ part of the path for new files.

+ NEW_FILES=./arch/x86/lp-hooks.o
+ for i in '$NEW_FILES'
++ dirname ./arch/x86/lp-hooks.o
+ mkdir -p output/./arch/x86
+ cp patched/./arch/x86/lp-hooks.o output/./arch/x86/lp-hooks.o
cp: cannot stat 'patched/./arch/x86/lp-hooks.o': No such file or directory

Alter the cd and find runes to use paths relative to the root of the different source trees.

---
CC: Roger Pau Monné <[email protected]>
CC: Ross Lagerwall <[email protected]>

I'm unsure whether there's a useful fixes tag to use. AFAICT it was broken even when 0564f0c7a57 claimed to have it working.

---
 livepatch-build | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
livepatch-build +1 -1
index cdb852cc7fea..948b2acfc2f6 100755
@@ -227,7 +227,7 @@ function create_patch()
         fi
     done
 
-    NEW_FILES=$(comm -23 <(cd patched/xen && find . -type f -name '*.o' | sort) <(cd original/xen && find . -type f -name '*.o' | sort))
+    NEW_FILES=$(comm -23 <(cd patched && find xen/ -type f -name '*.o' | sort) <(cd original && find xen/ -type f -name '*.o' | sort))
     for i in $NEW_FILES; do
         mkdir -p "output/$(dirname "$i")"
         cp "patched/$i" "output/$i"
Quoted 2 lines

base-commit: 1b5b03b3ce4187ce99bad580fd0ee36c6337313f --

Reviewed-by on v1 1/1
#2 lore raw
In reply to Andrew Cooper
Quoted 9 lines · Andrew Cooper

Right now, there's a mixup over the xen/ part of the path for new files.

+ NEW_FILES=./arch/x86/lp-hooks.o
+ for i in '$NEW_FILES'
++ dirname ./arch/x86/lp-hooks.o
+ mkdir -p output/./arch/x86
+ cp patched/./arch/x86/lp-hooks.o output/./arch/x86/lp-hooks.o
cp: cannot stat 'patched/./arch/x86/lp-hooks.o': No such file or directory

Quoted 4 lines

Alter the cd and find runes to use paths relative to the root of the different source trees.

Hm, this never worked AFAICT.

Thanks, Roger.