From 92878d9ed464c21da8303d5b7434944332fcb79e Mon Sep 17 00:00:00 2001 From: Dave Chapman Date: Sat, 17 Feb 2007 02:24:37 +0000 Subject: FS #6443 from Jonas Häggqvist - add an "install" target. MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit git-svn-id: svn://svn.rockbox.org/rockbox/trunk@12343 a1c6a512-1295-4272-9138-f99709370657 --- rbutil/Makefile | 15 +++++++++++++-- 1 file changed, 13 insertions(+), 2 deletions(-) diff --git a/rbutil/Makefile b/rbutil/Makefile index 426f0cade4..a7f9102fed 100644 --- a/rbutil/Makefile +++ b/rbutil/Makefile @@ -11,8 +11,13 @@ CXX=$(shell $(PREFIX)wx-config --cxx) -OBJS=rbutil.o rbutilApp.o rbutilFrm.o wizard_pages.o installlog.o +INC = +OBJS=rbutil.o rbutilApp.o rbutilFrm.o wizard_pages.o bootloaders.o installlog.o ipodpatcher/ipodpatcher.o ipodpatcher/ipodio-posix.o fwpatcher/md5.o fwpatcher/iriver.o +# Install into /usr/local by default +ifndef DESTDIR + DESTDIR=/usr/local +endif # type "make WIN=1" for a Windows build using the Debian mingw cross-compiler ifdef WIN @@ -27,7 +32,10 @@ endif all: rbutil$(EXT) .cpp.o : - $(CXX) -c `$(PREFIX)wx-config --cxxflags` -o $@ $< + $(CXX) $(INC) -c `$(PREFIX)wx-config --cxxflags` -o $@ $< + +.c.o : + $(CC) $(INC) -c `$(PREFIX)wx-config --cxxflags` -o $@ $< rbutil-rc.o: rbutil-rc.rc $(WINDRES) `$(PREFIX)wx-config --cxxflags` -O coff -F pe-i386 -o $@ $< @@ -38,3 +46,6 @@ rbutil$(EXT): $(OBJS) .PHONY: clean clean: rm -f rbutil rbutil.exe $(OBJS) *~ + +.PHONY: install + install -D rbutil$(EXT) $(DESTDIR)/bin/rbutil$(EXT) -- cgit v1.2.3