summaryrefslogtreecommitdiffstats
path: root/patches/01_fix-src-makefile.patch
blob: b7cac482fa182134069ef859c59d20f913d88ee0 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
Author: "P. J. McDermott" <pj@pehjota.net>
Subject: Fix src/Makefile

Before:

    $ opkbuild -bcT install
    [...]
    make -C src install
    make[2]: Entering directory '/pkg/lilo/tmp/src/src'
    mkdir -p $DESTDIR/sbin $DESTDIR/etc 
    mkdir -p $DESTDIR/boot $DESTDIR/usr/sbin
    if [ -f chain.b -a  1 -eq 0 ]; then cp chain.b $DESTDIR/boot; fi
    if [ -f mbr.b   -a  1 -eq 0 ]; then cp mbr.b   $DESTDIR/boot; fi
    if [ -f diag1.img ]; then cp -f diag1.img $DESTDIR/boot; fi
    if [ -f diag2.img ]; then cp -f diag2.img $DESTDIR/boot; fi
    strip lilo
    cp lilo $DESTDIR/sbin/lilo
    [ -x lilo.static ] && strip lilo.static
    Makefile:225: recipe for target 'install' failed
    make[2]: *** [install] Error 1
    make[2]: Leaving directory '/pkg/lilo/tmp/src/src'
    Makefile:106: recipe for target 'install' failed
    make[1]: *** [install] Error 2
    make[1]: Leaving directory '/pkg/lilo/tmp/src'
    ../build:13: recipe for target 'install' failed
    make: *** [install] Error 2

diff -Naur src.orig/src/Makefile src/src/Makefile
--- src.orig/src/Makefile	2013-06-07 09:23:05.000000000 -0400
+++ src/src/Makefile	2014-06-27 13:56:49.112704987 -0400
@@ -245,7 +245,7 @@
 
 	strip lilo
 	cp lilo $$DESTDIR$(SBIN_DIR)/lilo
-	[ -x lilo.static ] && strip lilo.static
+	if [ -x lilo.static ]; then strip lilo.static; fi
 	cp ../mkrescue $$DESTDIR$(USRSBIN_DIR)/mkrescue
 	cp ../keytab-lilo.pl $$DESTDIR$(USRSBIN_DIR)/keytab-lilo