X-Git-Url: http://git.ozlabs.org/?p=petitboot;a=blobdiff_plain;f=rules.mk;h=23b23d7e95ce2fdd48f350c53753428afc91edcd;hp=9b6d5ba110bf013059efde0c2f3d35291e42ceba;hb=fe7bfb4f2fa5b582be94409473130674b7d8687f;hpb=b90e4c95a69fcd5a561db71df940f0b5085b1c41 diff --git a/rules.mk b/rules.mk index 9b6d5ba..23b23d7 100644 --- a/rules.mk +++ b/rules.mk @@ -2,6 +2,7 @@ VPATH = $(srcdir) CPPFLAGS += -I$(top_srcdir) -I$(top_srcdir)/lib -I$(builddir) +LDFLAGS += $(CFLAGS) # we need paths to be overridable at build-time DEFS += '-DPREFIX="$(prefix)"' '-DPKG_SHARE_DIR="$(pkgdatadir)"' \ @@ -16,8 +17,7 @@ parser_test = test/parser-test # install targets and components daemons = $(pb_discover) -#parsers = kboot native yaboot (todo) -parsers = kboot +parsers = kboot yaboot uis = $(pb_test) tests = $(parser_test) @@ -37,10 +37,10 @@ talloc_objs = lib/talloc/talloc.o waiter_objs = lib/waiter/waiter.o # daemon objs -parser_objs = discover/parser.o discover/parser-utils.o \ +parser_objs = discover/parser.o discover/parser-conf.o discover/paths.o \ $(foreach p, $(parsers), discover/$(p)-parser.o) -discover_objs = discover/udev.o discover/discover-server.o \ - discover/device-handler.o discover/paths.o +discover_objs = discover/udev.o discover/discover-server.o \ + discover/device-handler.o discover/paths.o discover/parser-utils.o # client objs ui_common_objs = ui/common/discover-client.o @@ -94,7 +94,7 @@ $(pb_discover): $(pb_discover_objs) $(LINK.o) -o $@ $^ # parser-test -parser_test_objs = $(parser_objs) test/parser-test.o +parser_test_objs = $(lib_objs) $(parser_objs) test/parser-test.o $(parser_test_objs): $(makefiles) $(parser_test): $(parser_test_objs) @@ -109,7 +109,7 @@ install: all $(rules) $(INSTALL) $(addprefix $(top_srcdir)/ui/twin/artwork/,$(artwork)) \ $(DESTDIR)$(pkgdatadir)/artwork/ $(INSTALL) -d $(DESTDIR)$(pkgdatadir)/utils - $(INSTALL) $(top_srcdir)/$(rules) $(DESTDIR)$(pkgdatadir)/utils + $(INSTALL) -m 644 $(top_srcdir)/$(rules) $(DESTDIR)$(pkgdatadir)/utils dist: $(PACKAGE)-$(VERSION).tar.gz @@ -124,10 +124,10 @@ $(PACKAGE)-$(VERSION).tar.gz: $(PACKAGE)-$(VERSION) tar czvf $@ $^ $(PACKAGE)-$(VERSION): clean - for f in $$(git-ls-files); do \ + for f in $$(git --git-dir=$(top_srcdir)/.git ls-files); do \ d=$@/$$(dirname $$f); \ mkdir -p $$d; \ - cp -a $$f $$d; \ + cp -a $(top_srcdir)/$$f $$d; \ done clean: