Linux wireless drivers development
 help / color / mirror / Atom feed
* [PATCH] iw: Makefile changes for easier packaging
@ 2008-11-19  4:18 Robby Workman
  2008-11-19 11:58 ` Johannes Berg
  0 siblings, 1 reply; 5+ messages in thread
From: Robby Workman @ 2008-11-19  4:18 UTC (permalink / raw)
  To: linux-wireless; +Cc: antiwire

[-- Attachment #1: Type: TEXT/PLAIN, Size: 140 bytes --]

Attached is a trivial patch to make packaging a bit easier.
No strong feelings either way, so rejection will cause no
hard feelings :-)

-RW

[-- Attachment #2: Type: TEXT/PLAIN, Size: 1234 bytes --]

Trivial patch for easier packaging of iw
Signed-off-by: Robby Workman <rworkman@slackware.com>
---
diff --git a/Makefile b/Makefile
index 3fa0a83..df59b51 100644
--- a/Makefile
+++ b/Makefile
@@ -2,10 +2,14 @@
 
 MAKEFLAGS += --no-print-directory
 
+PREFIX ?= /usr
+BINDIR ?= $(PREFIX)/bin
+MANDIR ?= $(PREFIX)/share/man
+
 MKDIR ?= mkdir -p
 INSTALL ?= install
-PREFIX ?= /usr
 CC ?= "gcc"
+
 CFLAGS += -Wall -Wundef -Wstrict-prototypes -Wno-trigraphs -fno-strict-aliasing -fno-common -Werror-implicit-function-declaration `pkg-config --cflags libnl-1`
 CFLAGS += -O2 -g
 LDFLAGS += `pkg-config --libs libnl-1`
@@ -49,11 +53,11 @@ check:
 
 install: iw iw.8.gz
 	@$(NQ) ' INST iw'
-	$(Q)$(MKDIR) $(DESTDIR)$(PREFIX)/bin/
-	$(Q)$(INSTALL) -m 755 -o root -g root -t $(DESTDIR)$(PREFIX)/bin/ iw
+	$(Q)$(MKDIR) $(DESTDIR)$(BINDIR)
+	$(Q)$(INSTALL) -m 755 -t $(DESTDIR)$(BINDIR) iw
 	@$(NQ) ' INST iw.8'
-	$(Q)$(MKDIR) $(DESTDIR)$(PREFIX)/share/man/man8/
-	$(Q)$(INSTALL) -m 644 -o root -g root -t $(DESTDIR)$(PREFIX)/share/man/man8/ iw.8.gz
+	$(Q)$(MKDIR) $(DESTDIR)$(MANDIR)/man8/
+	$(Q)$(INSTALL) -m 644 -t $(DESTDIR)$(MANDIR)/man8/ iw.8.gz
 
 clean:
 	$(Q)rm -f iw *.o *~ *.gz version.h *-stamp

^ permalink raw reply related	[flat|nested] 5+ messages in thread

end of thread, other threads:[~2008-11-19 21:08 UTC | newest]

Thread overview: 5+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2008-11-19  4:18 [PATCH] iw: Makefile changes for easier packaging Robby Workman
2008-11-19 11:58 ` Johannes Berg
2008-11-19 16:18   ` Robby Workman
2008-11-19 20:24     ` Johannes Berg
2008-11-19 21:08       ` Robby Workman

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox