Don't abuse LDFLAGS and fix linking with -Wl,--as-needed.

Signed-off-by: Christian Ruppert <idl0r@gentoo.org>
Acked-by: Stefan Reinauer <stepan@coresystems.de>



git-svn-id: svn://svn.coreboot.org/coreboot/trunk@5263 2b7e53f0-3cfb-0310-b3e9-8179ed1497e1
This commit is contained in:
Christian Ruppert 2010-03-21 21:22:51 +00:00 committed by Stefan Reinauer
parent bd0381a705
commit 121f0b8cf0
1 changed files with 3 additions and 3 deletions

View File

@ -36,7 +36,7 @@ OBJS = superiotool.o ali.o fintek.o ite.o nsc.o smsc.o winbond.o
OS_ARCH = $(shell uname)
ifeq ($(OS_ARCH), Darwin)
LDFLAGS = -framework IOKit -framework DirectIO -lpci -lz
LIBS = -framework IOKit -framework DirectIO -lpci -lz
endif
# Support for PCI-attached "Super I/Os" (e.g. in VIA VT82686A/B).
@ -44,7 +44,7 @@ CONFIG_PCI = yes
ifeq ($(CONFIG_PCI), yes)
CFLAGS += -DPCI_SUPPORT
LDFLAGS += -lpci
LIBS += -lpci
OBJS += pci.o via.o
endif
@ -53,7 +53,7 @@ all: $(PROGRAM)
superiotool.o: *.c superiotool.h
$(PROGRAM): $(OBJS) superiotool.h
$(CC) $(LDFLAGS) -o $(PROGRAM) $(OBJS)
$(CC) $(LDFLAGS) -o $(PROGRAM) $(OBJS) $(LIBS)
install: $(PROGRAM)
mkdir -p $(DESTDIR)$(PREFIX)/sbin