Print this page
fix gld to use 32bit only if we are using gld 64bit
Split |
Close |
Expand all |
Collapse all |
--- old/usr/src/grub/grub-0.97/grub/Makefile.solaris
+++ new/usr/src/grub/grub-0.97/grub/Makefile.solaris
1 1 #
2 2 # Copyright 2007 Sun Microsystems, Inc. All rights reserved.
↓ open down ↓ |
2 lines elided |
↑ open up ↑ |
3 3 # Use is subject to license terms.
4 4 #
5 5 # ident "%Z%%M% %I% %E% SMI"
6 6 #
7 7 include ../../Makefile.grub
8 8 include ../Makefile.solaris.defs
9 9
10 10
11 11 GRUB = grub
12 12 GRUB_OBJS = asmstub.o main.o
13 -$(GRUB) := LIBS = ../stage2/libgrub.a ../lib/libcommon.a -lcurses
13 +$(GRUB) := LIBS = ../stage2/libgrub.a ../lib/libcommon.a -lcurses -m32
14 14 $(GRUB) := LDFLAGS += $(LDLIBS.cmd)
15 15 $(GRUB) := CCLD = $(CC)
16 16
17 17 #
18 18 # The grub shell interposes on the getopt() family. Should direct bindings be
19 19 # enabled, these interfaces should be explicitly defined as interposes. Use a
20 20 # mapfile to associate the necessary interposer definitions.
21 21 #
22 22 MAPFILES = $(MAPFILE.INT)
23 23
24 24 INCLUDES = -I. -I.. -I../stage1 -I../stage2 -I../lib
25 25 CFLAGS += -O2
26 26 LINKFLAGS += -O2 $(MAPFILES:%=-Wl,-M%)
27 27 CPPFLAGS += -DGRUB_UTIL=1 -DFSYS_EXT2FS=1 -DFSYS_FAT=1 -DFSYS_FFS=1 \
28 28 -DFSYS_ISO9660=1 -DFSYS_JFS=1 -DFSYS_MINIX=1 \
29 29 -DFSYS_REISERFS=1 -DFSYS_ZFS=1 -DFSYS_UFS2=1 -DFSYS_VSTAFS=1 \
30 30 -DFSYS_XFS=1 -DUSE_MD5_PASSWORDS=1 -DSUPPORT_HERCULES=1 \
31 31 -DSUPPORT_SERIAL=1
32 32
33 33 PROGRAMS = $(GRUB)
34 34
35 35 INSTALL_DIR = $(ROOT_BOOT_GRUB)/bin
36 36 INSTALL_TARGETS = $(PROGRAMS:%=$(INSTALL_DIR)/%)
37 37
38 38 $(INSTALL_DIR)/% := FILEMODE = 0555
39 39
40 40 #
41 41 # Source files to be installed in $(SRC_DIR).
42 42 #
43 43 SRC_DIR = $(ROOT_SRC)/grub
44 44 SRC_FILES = Makefile.am Makefile.in asmstub.c main.c
45 45
46 46 INSTALL_TARGETS += $(SRC_FILES:%=$(SRC_DIR)/%)
47 47
48 48
49 49 all: $(PROGRAMS)
50 50
51 51 $(GRUB): $(GRUB_OBJS) $(MAPFILES)
52 52 $(LINK) -o $@ $(GRUB_OBJS) $(LIBS)
53 53 $(POST_PROCESS)
54 54
55 55 $(GRUB_OBJS): $$(@:.o=.c)
56 56 $(CC) $(CFLAGS) -c -o $@ $(@:.o=.c)
57 57
58 58
59 59 install: all $(INSTALL_TARGETS)
60 60
61 61 $(INSTALL_DIR)/%: $(INSTALL_DIR) %
62 62 $(INS.file)
63 63
64 64 $(SRC_DIR)/%: $(SRC_DIR) %
65 65 $(INS.file)
66 66
67 67 $(INSTALL_DIR) $(SRC_DIR):
68 68 $(INS.dir)
69 69
70 70
71 71 clean: _FORCE
72 72 $(RM) *.o
73 73
74 74 clobber: clean
75 75 $(RM) $(PROGRAMS)
76 76
77 77 _FORCE:
↓ open down ↓ |
54 lines elided |
↑ open up ↑ |
XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX