From cd637629c43e829f9f14c99122fa552c621e8fbf Mon Sep 17 00:00:00 2001 From: "Markus F.X.J. Oberhumer" Date: Sun, 23 Jul 2017 02:18:39 +0200 Subject: [PATCH] Update stub/src/arch/powerpc Makefiles. --- src/stub/src/arch/powerpc/32/Makefile.extra | 6 ++++-- src/stub/src/arch/powerpc/64/Makefile | 4 +++- src/stub/src/arch/powerpc/64/Makefile.extra | 7 +++---- src/stub/src/arch/powerpc/64le/Makefile.extra | 7 +++---- 4 files changed, 13 insertions(+), 11 deletions(-) diff --git a/src/stub/src/arch/powerpc/32/Makefile.extra b/src/stub/src/arch/powerpc/32/Makefile.extra index 75733dbf..04f46f76 100644 --- a/src/stub/src/arch/powerpc/32/Makefile.extra +++ b/src/stub/src/arch/powerpc/32/Makefile.extra @@ -1,3 +1,5 @@ +# build lzma_d_cf.S and lzma_d_cs.S + MAKEFLAGS += -rR .SUFFIXES: .SECONDEXPANSION: @@ -33,8 +35,8 @@ lzma_d_c%.S : tc_list = method-lzma powerpc-linux.elf default lzma_d_c%.S : tc_bfdname = elf32-powerpc c := tc.method-lzma.gcc -$c = $(tc.powerpc-linux.elf.gcc) -$c += -mcpu=405 -fPIC +$c = $(tc.powerpc-linux.elf.gcc) -mcpu=405 +$c += -fPIC $c += -fomit-frame-pointer $c += -fno-unit-at-a-time $c += -ffunction-sections diff --git a/src/stub/src/arch/powerpc/64/Makefile b/src/stub/src/arch/powerpc/64/Makefile index 8810fd41..ff0b0eff 100644 --- a/src/stub/src/arch/powerpc/64/Makefile +++ b/src/stub/src/arch/powerpc/64/Makefile @@ -1 +1,3 @@ -#include ../64le/Makefile +# convenience Makefile +default %: + $(MAKE) -C ../../../.. $@ diff --git a/src/stub/src/arch/powerpc/64/Makefile.extra b/src/stub/src/arch/powerpc/64/Makefile.extra index b97ce805..06875887 100644 --- a/src/stub/src/arch/powerpc/64/Makefile.extra +++ b/src/stub/src/arch/powerpc/64/Makefile.extra @@ -1,6 +1,5 @@ -# How to transform from source code in src/stub/src/c/lzma_d_c.c -# to the pieces for use in UPX runtime decompression stub. -# +# build lzma_d_cf.S and lzma_d_cs.S + MAKEFLAGS += -rR .SUFFIXES: .SECONDEXPANSION: @@ -36,7 +35,7 @@ lzma_d_c%.S : tc_list = method-lzma powerpc64-linux.elf default lzma_d_c%.S : tc_bfdname = elf64-powerpc c := tc.method-lzma.gcc -$c = powerpc64-linux-gcc-4.9.2 +$c = $(tc.powerpc64-linux.elf.gcc) $c += -fPIC $c += -fomit-frame-pointer $c += -fno-unit-at-a-time diff --git a/src/stub/src/arch/powerpc/64le/Makefile.extra b/src/stub/src/arch/powerpc/64le/Makefile.extra index c4fdacc8..e469fd5e 100644 --- a/src/stub/src/arch/powerpc/64le/Makefile.extra +++ b/src/stub/src/arch/powerpc/64le/Makefile.extra @@ -1,6 +1,5 @@ -# How to transform from source code in src/stub/src/c/lzma_d_c.c -# to the pieces for use in UPX runtime decompression stub. -# +# build lzma_d_cf.S and lzma_d_cs.S + MAKEFLAGS += -rR .SUFFIXES: .SECONDEXPANSION: @@ -37,7 +36,7 @@ lzma_d_c%.S : tc_bfdname = elf64-powerpcle c := tc.method-lzma.gcc $c = $(tc.powerpc64le-linux.elf.gcc) -$c += -mcpu=405 -fPIC +$c += -fPIC $c += -fomit-frame-pointer $c += -fno-unit-at-a-time $c += -ffunction-sections