The following changes were made to Makefile:
* Added BRIEF * Moved to new version scheme * Moved make and make install out of variables * Commented make test since there doesn't appear to be any tests
This commit is contained in:
20
Makefile
20
Makefile
@@ -11,19 +11,16 @@
|
||||
DEPENDS =
|
||||
ARCH = x86_64
|
||||
URL = https://wiki.linuxfoundation.org/networking/iproute2
|
||||
BRIEF = Utilities for TCP/IP traffic control
|
||||
DESC = Iproute2 is a collection of utilities for controlling TCP / IP \
|
||||
networking and traffic control in Linux.
|
||||
SNAPVER = sr0
|
||||
SNAPVER = 1
|
||||
|
||||
ARCHIVE := $(PWD)/SRC/$(shell ls SRC|egrep '(bz2|gz|tar|xz)$$'|tail -1)
|
||||
TYPE := $(shell file -ib $(ARCHIVE)|cut -d';' -f1|tr -d '\n')
|
||||
SRCDIR := $(shell tar -tf $(ARCHIVE)|head -1|sed 's/\/.*//')
|
||||
PATCHDIR := $(PWD)/SRC/patches
|
||||
VERSION := $(shell echo $(SRCDIR)|egrep -o '\-[0-9].*'|sed 's/^-//')$(SNAPVER)
|
||||
|
||||
MAKE = make
|
||||
MAKEINST = make install
|
||||
SNAPHACKS =
|
||||
VERSION := $(shell echo $(SRCDIR)|egrep -o '\-[0-9].*'|sed 's/^-//')-$(SNAPVER)
|
||||
|
||||
include /usr/share/snap/Makefile.snaplinux
|
||||
|
||||
@@ -58,8 +55,7 @@ $(SRCDIR)/config.log: $(SRCDIR)/configure
|
||||
--target=x86_64-snap-linux-gnu
|
||||
|
||||
$(SRCDIR)/genl/genl: $(SRCDIR)/config.log
|
||||
@cd $(SRCDIR); \
|
||||
$(MAKE)
|
||||
@cd $(SRCDIR) && make
|
||||
|
||||
$(ROOT): $(SRCDIR)/genl/genl
|
||||
@if [ -d $(ROOT) ]; then \
|
||||
@@ -68,14 +64,10 @@ $(ROOT): $(SRCDIR)/genl/genl
|
||||
mkdir -v $(ROOT); \
|
||||
fi
|
||||
|
||||
@cd $(SRCDIR); \
|
||||
$(MAKEINST) DESTDIR=$(ROOT)
|
||||
|
||||
@$(SNAPHACKS)
|
||||
@cd $(SRCDIR) && make install DESTDIR=$(ROOT)
|
||||
|
||||
test: $(ROOT)
|
||||
@cd $(SRCDIR); \
|
||||
make test
|
||||
# @cd $(SRCDIR) && make test
|
||||
|
||||
clean:
|
||||
@rm -rvf $(ROOT) \
|
||||
|
||||
Reference in New Issue
Block a user