diff --git a/Makefile b/Makefile index 9bf27bf..8493678 100644 --- a/Makefile +++ b/Makefile @@ -12,9 +12,10 @@ export SRCPKG = attr export DEPENDS = glibc,libattr export ARCH = x86_64 export URL = http://savannah.nongnu.org/projects/attr +REPO = main BRIEF = Filesystem extended attributes utilities DESC = Commands for Manipulating Filesystem Extended Attributes -SNAPVER = 3 +SNAPVER = 4 ARCHIVE := $(PWD)/SRC/$(shell ls SRC|egrep '(bz2|gz|tar|xz)$$'|tail -1) TYPE := $(shell file -ib $(ARCHIVE)|cut -d';' -f1|tr -d '\n') @@ -23,28 +24,24 @@ PATCHDIR := $(PWD)/SRC/patches export VERSION := $(shell echo $(SRCDIR)|egrep -o '\-[0-9].*'| \ sed 's/^-//')-$(SNAPVER) -LIBATTR := $(PWD)/libattr -export LIBATTRROOT := $(LIBATTR)/ROOT -LIBATTRDEV := $(PWD)/libattr-dev -export LIBATTRDEVROOT := $(LIBATTRDEV)/ROOT - -MAKE = make -MAKEINST = make install install-dev install-lib -SNAPHACKS = +DEV := $(PWD)/libattr-dev +DEVROOT := $(DEV)/ROOT +LIB := $(PWD)/libattr +LIBROOT := $(LIB)/ROOT include /usr/share/snap/Makefile.snaplinux -$(LIBATTRROOT): $(ROOT) - @install -v -d $(LIBATTR)/SNAP && \ - install -v -d $(LIBATTRROOT) - @cd $(SRCDIR) && make install-lib DESTDIR=$(LIBATTRROOT) - @cd $(LIBATTR) && make -f ../Makefile.libattr && mv *.snap ../ +$(LIBROOT): $(DEVROOT) + @install -v -d $(LIB)/SNAP $(LIBROOT) && \ + cd $(SRCDIR) && make install-lib DESTDIR=$(LIBROOT) && \ + rm -vrf $(LIBROOT)/bin $(LIBROOT)/usr/share/locale \ + $(LIBROOT)/usr/share/man && \ + cd $(LIB) && make -f ../Makefile.libattr && mv *.snap ../ -$(LIBATTRDEVROOT): $(ROOT) - @install -v -d $(LIBATTRDEV)/SNAP && \ - install -v -d $(LIBATTRDEVROOT) - @cd $(SRCDIR) && make install-dev DESTDIR=$(LIBATTRDEVROOT) - @cd $(LIBATTRDEV) && make -f ../Makefile.libattrdev && mv *.snap ../ +$(DEVROOT): $(ROOT) + @install -v -d $(DEV)/SNAP $(DEVROOT) && \ + cd $(SRCDIR) && make install-dev DESTDIR=$(DEVROOT) && \ + cd $(DEV) && make -f ../Makefile.libattr-dev && mv *.snap ../ $(SRCDIR): $(ARCHIVE) @if [ '$(TYPE)' == 'application/x-bzip2' ]; then \ @@ -77,23 +74,14 @@ $(SRCDIR)/config.log: $(SRCDIR) $(SRCDIR)/attr: $(SRCDIR)/config.log @cd $(SRCDIR) && make -$(ROOT): $(SRCDIR)/attr +$(ROOT): $(SRCDIR)/attr $(DEVROOT) $(LIBROOT) @if [ -d $(ROOT) ]; then \ touch $(ROOT); \ else \ mkdir -v $(ROOT); \ fi - @install -v -d $(LIBATTR)/SNAP && \ - install -v -d $(LIBATTRROOT) && \ - install -v -d $(LIBATTRDEV)/SNAP && \ - install -v -d $(LIBATTRDEVROOT) && \ - cd $(SRCDIR) && make install-lib DESTDIR=$(LIBATTRROOT) && \ - make install-dev DESTDIR=$(LIBATTRDEVROOT) && \ - make install DESTDIR=$(ROOT) && \ - gzip $(ROOT)/usr/share/doc/attr/COPYING* && \ - gzip $(LIBATTRROOT)/usr/share/doc/attr/COPYING* && \ - cd $(LIBATTR) && make -f ../Makefile.libattr && mv *.snap ../ && \ - cd $(LIBATTRDEV) && make -f ../Makefile.libattrdev && mv *.snap ../ + @cd $(SRCDIR) && make install DESTDIR=$(ROOT) && \ + rm -vrf $(ROOT)/usr/share/doc test: $(ROOT) @cd $(SRCDIR); \ @@ -101,8 +89,8 @@ test: $(ROOT) clean: @rm -rvf $(ROOT) \ - $(LIBATTR) \ - $(LIBATTRDEV) \ + $(DEV) \ + $(LIB) \ $(SNAPINFO) \ $(MANIFEST) \ $(FILES) \ diff --git a/Makefile.libattr b/Makefile.libattr index 6f27708..bd76b73 100644 --- a/Makefile.libattr +++ b/Makefile.libattr @@ -9,6 +9,7 @@ # GNU General Public License for more details. DEPENDS = glibc +REPO = core BRIEF = Access control list shared library DESC = Shared library for manipulating POSIX Access Control Lists diff --git a/Makefile.libattrdev b/Makefile.libattr-dev similarity index 98% rename from Makefile.libattrdev rename to Makefile.libattr-dev index 8173e60..81ddb40 100644 --- a/Makefile.libattrdev +++ b/Makefile.libattr-dev @@ -9,6 +9,7 @@ # GNU General Public License for more details. DEPENDS = glibc,libattr +REPO = dev BRIEF = Access control list shared library DESC = Shared library for manipulating POSIX Access Control Lists