rust/cargo-c: update to 0.10.7+cargo-0.84.0
[oi-userland.git] / components / network / bridge / patches / 01-Makefile.in.patch
blob491dfe5dbad2fdc8b1b54d37d39d1b234d86656e
1 --- ./Makefile.in.~1~ 2014-04-07 16:12:08.000000000 +0200
2 +++ ./Makefile.in 2016-11-19 23:20:28.106965778 +0100
3 @@ -45,11 +45,16 @@
4 LD = ld
5 RM = /bin/rm
6 CAT = /bin/cat
7 +MKDIR = /bin/mkdir
8 +MKDIR_P = $(MKDIR) -p
9 REM_DRV = /usr/sbin/rem_drv
10 ADD_DRV = /usr/sbin/add_drv
11 MODLOAD = /usr/sbin/modload
12 MODUNLOAD = /usr/sbin/modunload
14 +SRCDIR = @srcdir@
15 +DESTDIR = @prefix@
17 INSTALL = @INSTALL@
19 CONFIGURE_FILES = Makefile config.status config.cache config.h config.log
20 @@ -62,31 +67,32 @@
21 clean:
22 $(RM) -f *.o brdg brdgadm
24 -brdg.o: brdg.c
25 +brdg.o: $(SRCDIR)/brdg.c
26 $(CC) -c $(KCFLAGS) $< -o $@
28 brdg: brdg.o
29 $(LD) $(LD_FLAGS) -dn -r $^ -o $@
31 -brdgadm.o: brdgadm.c
32 +brdgadm.o: $(SRCDIR)/brdgadm.c
33 $(CC) -c $(CFLAGS) $< -o $@
35 -dlpiutil.o: dlpiutil.c dlpiutil.h
36 +dlpiutil.o: $(SRCDIR)/dlpiutil.c $(SRCDIR)/dlpiutil.h
37 $(CC) -c $(CFLAGS) $< -o $@
39 brdgadm: brdgadm.o dlpiutil.o
40 $(CC) $(CFLAGS) -lsocket -lnsl $^ -o $@
42 install: all
43 - -$(INSTALL) -m 0755 -o root -g sys brdg $(MOD_PATH)
44 - $(INSTALL) -d -m 0755 -o root -g bin $(BINDIR)
45 - -$(INSTALL) -m 0755 -o root -g bin brdgadm $(BINDIR)
46 - $(MODLOAD) brdg
47 + $(INSTALL) -d -m 0755 $(DESTDIR)$(MOD_PATH) || $(MKDIR_P) $(DESTDIR)$(MOD_PATH)
48 + -$(INSTALL) -m 0755 brdg $(DESTDIR)$(MOD_PATH)
49 + $(INSTALL) -d -m 0755 $(DESTDIR)$(BINDIR) || $(MKDIR_P) $(DESTDIR)$(BINDIR)
50 + -$(INSTALL) -m 0755 brdgadm $(DESTDIR)$(BINDIR)
51 + -[ -z "$(DESTDIR)" ] && $(MODLOAD) brdg
53 uninstall:
54 - -$(MODUNLOAD) -i `modinfo | awk '/brdg/{ print $1 }'`
55 - -$(RM) $(MOD_PATH)/brdg
56 - -$(RM) $(BINDIR)/brdgadm
57 + -[ -z "$(DESTDIR)" ] && -$(MODUNLOAD) -i `modinfo | awk '/brdg/{ print $1 }'`
58 + -[ -z "$(DESTDIR)" ] && $(RM) $(MOD_PATH)/brdg
59 + -[ -z "$(DESTDIR)" ] && $(RM) $(BINDIR)/brdgadm
61 distclean:
62 rm -f $(CONFIGURE_FILES)