author | kergoth <kergoth> | 2002-11-05 23:26:33 (UTC) |
---|---|---|
committer | kergoth <kergoth> | 2002-11-05 23:26:33 (UTC) |
commit | 76f38e36b7a875a1763d1e6ce5e00cc8dd736263 (patch) (side-by-side diff) | |
tree | 758e4858912d3ef391200d312a188fc9bffa91d9 /scripts | |
parent | b14da9c14c5f1968fb4ba07c3fa0b3888e57ff2f (diff) | |
download | opie-76f38e36b7a875a1763d1e6ce5e00cc8dd736263.zip opie-76f38e36b7a875a1763d1e6ce5e00cc8dd736263.tar.gz opie-76f38e36b7a875a1763d1e6ce5e00cc8dd736263.tar.bz2 |
Adjust makefile to check both /usr/share/qt and /usr/lib/qt for QTDIR, and to check for the existance of qt-mt and qt both
-rw-r--r-- | scripts/kconfig/Makefile | 22 |
1 files changed, 21 insertions, 1 deletions
diff --git a/scripts/kconfig/Makefile b/scripts/kconfig/Makefile index 7553311..caad231 100644 --- a/scripts/kconfig/Makefile +++ b/scripts/kconfig/Makefile @@ -1,25 +1,45 @@ VERSION=1.2 CC=gcc CXX=g++ CFLAGS=-O2 -Wall -g -fPIC CXXFLAGS=$(CFLAGS) -I$(HOSTQTDIR)/include LDFLAGS= LXXFLAGS=$(LDFLAGS) -L$(HOSTQTDIR)/lib -Wl,-rpath,$(HOSTQTDIR)/lib LEX=flex YACC=bison YFLAGS=-d -t -v ifndef HOSTQTDIR +ifeq ($(shell if [ -e /usr/share/qt ]; then echo foundit; fi),foundit) HOSTQTDIR=/usr/share/qt +else +ifeq ($(shell if [ -e /usr/lib/qt ]; then echo foundit; fi),foundit) +HOSTQTDIR=/usr/lib/qt +endif +endif +endif + +ifndef QTLIB +ifeq ($(shell if [ -e $(HOSTQTDIR)/lib/libqt.so ]; then echo foundit; fi),foundit) +QTLIB=-lqt +else +ifeq ($(shell if [ -e $(HOSTQTDIR)/lib/libqt-mt.so ]; then echo foundit; fi),foundit) +QTLIB=-lqt-mt +else +QTLIB=-lqt +$(warning Unable to locate libqt.so!) +endif endif +endif + MOC=$(wildcard $(HOSTQTDIR)/bin/moc) parse_SRC=zconf.y conf_SRC=conf.c $(parse_SRC) mconf_SRC=mconf.c $(parse_SRC) qconf_SRC=qconf.cc lkcc_SRC=cml1.y cml1.l help.l cml1.h expr1.c HDR=expr.h lkc.h lkc_proto.h qconf.h OTHER=README lkc_spec lkc_overview Makefile.kernel convert-all prepare-all.diff fixup-all.diff \ kconfig.i extconf.rb example INST=zconf.y zconf.l confdata.c expr.c symbol.c menu.c conf.c mconf.c qconf.cc kconfig_load.c images.c $(parse_SRC) $(HDR) INSTGEN=lex.zconf.c zconf.tab.c zconf.tab.h @@ -102,25 +122,25 @@ mconf: $(mconf_OBJ) conf: $(conf_OBJ) $(CC) $(LDFLAGS) $^ -o $@ ifeq ($(MOC),) qconf: @echo Unable to find the QT installation. Please make sure that the @echo QT development package is correctly installed and the HOSTQTDIR @echo environment variable is set to the correct location. @false else qconf: $(qconf_OBJ) libkconfig.so - $(CXX) $(LXXFLAGS) $^ -lqt -o $@ + $(CXX) $(LXXFLAGS) $^ $(QTLIB) -o $@ endif lkcc: $(lkcc_OBJ) $(CC) $(LDFLAGS) $^ -o $@ libkconfig.so: $(parse_OBJ) $(CC) -shared $^ -o $@ lkc_defs.h: lkc_proto.h sed < $< > $@ 's/P(\([^,]*\),.*/#define \1 (\*\1_p)/' clean: |