|
@@ -0,0 +1,95 @@
|
|
|
+--- yaboot-1.3.17.orig/Makefile 2011-10-18 06:11:10.000000000 +0200
|
|
|
++++ yaboot-1.3.17/Makefile 2018-06-08 23:26:05.000000000 +0200
|
|
|
+@@ -7,7 +7,7 @@ VERSION = 1.3.17
|
|
|
+ DEBUG = 0
|
|
|
+ # make install vars
|
|
|
+ ROOT =
|
|
|
+-PREFIX = usr/local
|
|
|
++PREFIX = usr
|
|
|
+ MANDIR = man
|
|
|
+ # command used to get root (needed for tarball creation)
|
|
|
+ GETROOT = fakeroot
|
|
|
+@@ -25,7 +25,7 @@ KERNELADDR = 0x00000000
|
|
|
+ # Set this to the prefix of your cross-compiler, if you have one.
|
|
|
+ # Else leave it empty.
|
|
|
+ #
|
|
|
+-CROSS =
|
|
|
++CROSS ?=
|
|
|
+
|
|
|
+ CC := $(CROSS)gcc
|
|
|
+ LD := $(CROSS)ld
|
|
|
+@@ -39,7 +39,7 @@ YBCFLAGS += -DVERSION="\"${VERSION}${VER
|
|
|
+ YBCFLAGS += -DTEXTADDR=$(TEXTADDR) -DDEBUG=$(DEBUG)
|
|
|
+ YBCFLAGS += -DMALLOCADDR=$(MALLOCADDR) -DMALLOCSIZE=$(MALLOCSIZE)
|
|
|
+ YBCFLAGS += -DKERNELADDR=$(KERNELADDR)
|
|
|
+-YBCFLAGS += -Werror -fdiagnostics-show-option
|
|
|
++YBCFLAGS += -fdiagnostics-show-option
|
|
|
+ YBCFLAGS += -I ./include
|
|
|
+ YBCFLAGS += -fno-strict-aliasing
|
|
|
+
|
|
|
+@@ -59,22 +59,18 @@ ifeq ($(CONFIG_FS_XFS),y)
|
|
|
+ YBCFLAGS += -DCONFIG_FS_XFS
|
|
|
+ endif
|
|
|
+
|
|
|
+-ifeq ($(CONFIG_FS_REISERFS),y)
|
|
|
+-YBCFLAGS += -DCONFIG_FS_REISERFS
|
|
|
+-endif
|
|
|
+-
|
|
|
+ # Link flags
|
|
|
+ #
|
|
|
+-LFLAGS = -Ttext $(TEXTADDR) -Bstatic -melf32ppclinux
|
|
|
++LFLAGS = -static -Ttext $(TEXTADDR) -melf32ppclinux
|
|
|
+
|
|
|
+ # Libraries
|
|
|
+ #
|
|
|
+-LLIBS = -lext2fs
|
|
|
++#LLIBS = -lext2fs -static
|
|
|
+
|
|
|
+ # For compiling userland utils
|
|
|
+ #
|
|
|
+ UCFLAGS = -Os $(CFLAGS) -Wall -I/usr/include
|
|
|
+-UCFLAGS += -Werror -fdiagnostics-show-option
|
|
|
++UCFLAGS += -fdiagnostics-show-option
|
|
|
+
|
|
|
+ # For compiling build-tools that run on the host.
|
|
|
+ #
|
|
|
+@@ -85,7 +81,7 @@ HOSTCFLAGS = -O2 $(CFLAGS) -Wall -I/usr/
|
|
|
+
|
|
|
+ OBJS = second/crt0.o second/yaboot.o second/cache.o second/prom.o second/file.o \
|
|
|
+ second/partition.o second/fs.o second/cfg.o second/setjmp.o second/cmdline.o \
|
|
|
+- second/fs_of.o second/fs_ext2.o second/fs_iso.o second/fs_swap.o \
|
|
|
++ second/fs_of.o second/fs_iso.o second/fs_swap.o \
|
|
|
+ second/iso_util.o \
|
|
|
+ lib/nonstd.o \
|
|
|
+ lib/nosys.o lib/string.o lib/strtol.o lib/vsprintf.o lib/ctype.o lib/malloc.o lib/strstr.o
|
|
|
+@@ -98,14 +94,10 @@ ifeq ($(CONFIG_FS_XFS),y)
|
|
|
+ OBJS += second/fs_xfs.o
|
|
|
+ endif
|
|
|
+
|
|
|
+-ifeq ($(CONFIG_FS_REISERFS),y)
|
|
|
+-OBJS += second/fs_reiserfs.o
|
|
|
+-endif
|
|
|
+-
|
|
|
+ # compilation
|
|
|
+ lgcc = `$(CC) -m32 -print-libgcc-file-name`
|
|
|
+
|
|
|
+-all: yaboot addnote mkofboot
|
|
|
++all: yaboot
|
|
|
+
|
|
|
+ yaboot: $(OBJS)
|
|
|
+ $(LD) $(LFLAGS) $(OBJS) $(LLIBS) $(lgcc) -o second/$@
|
|
|
+@@ -181,13 +173,11 @@ strip: all
|
|
|
+ strip util/addnote
|
|
|
+ strip --remove-section=.comment --remove-section=.note util/addnote
|
|
|
+
|
|
|
+-install: all strip
|
|
|
++install: all
|
|
|
+ install -d -o root -g root -m 0755 ${ROOT}/etc/
|
|
|
+ install -d -o root -g root -m 0755 ${ROOT}/${PREFIX}/sbin/
|
|
|
+ install -d -o root -g root -m 0755 ${ROOT}/${PREFIX}/lib
|
|
|
+ install -d -o root -g root -m 0755 ${ROOT}/${PREFIX}/lib/yaboot
|
|
|
+- install -d -o root -g root -m 0755 ${ROOT}/${PREFIX}/${MANDIR}/man5/
|
|
|
+- install -d -o root -g root -m 0755 ${ROOT}/${PREFIX}/${MANDIR}/man8/
|
|
|
+ install -o root -g root -m 0644 second/yaboot ${ROOT}/$(PREFIX)/lib/yaboot
|
|
|
+ install -o root -g root -m 0755 util/addnote ${ROOT}/${PREFIX}/lib/yaboot/addnote
|
|
|
+ install -o root -g root -m 0644 first/ofboot ${ROOT}/${PREFIX}/lib/yaboot/ofboot
|