Moved to slp format

This commit is contained in:
2020-08-22 21:40:41 -05:00
parent 8b396069b3
commit 34b40e4580
2 changed files with 24 additions and 9 deletions

View File

@@ -8,23 +8,27 @@
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
# GNU General Public License for more details. # GNU General Public License for more details.
ARCH = x86_64 export SRCPKG = libarchive
DEPENDS = bzip2,glibc,libnettle,libxml2,xz,zlib export DEPENDS = bzip2,glibc,libnettle,libxml2,xz,zlib
export ARCH = x86_64
export URL = http://www.libarchive.org/
BUILDDEPS = gcc BUILDDEPS = gcc
SRCPKG =
URL = http://www.libarchive.org/
REPO = main REPO = main
BRIEF = Multi-format archive and compression library BRIEF = Multi-format archive and compression library
DESC = Multi-format archive and compression library DESC = Multi-format archive and compression library
SNAPVER = 1 SLVER = 2
ARCHIVE := $(PWD)/SRC/$(shell ls SRC|egrep '(bz2|gz|tar|xz)$$'|tail -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') TYPE := $(shell file -ib $(ARCHIVE)|cut -d';' -f1|tr -d '\n')
SRCDIR := $(shell tar -tf $(ARCHIVE)|head -1|sed 's/\/.*//') SRCDIR := $(shell tar -tf $(ARCHIVE)|head -1|sed 's/\/.*//')
PATCHDIR := $(PWD)/SRC/patches PATCHDIR := $(PWD)/SRC/patches
VERSION := $(shell echo $(SRCDIR)|egrep -o '\-[0-9].*'|sed 's/^-//')-$(SNAPVER) export VERSION := $(shell echo $(SRCDIR)|egrep -o '\-[0-9].*'| \
sed 's/^-//')-$(SLVER)
include /usr/share/snap/Makefile.snaplinux include /usr/share/sl/Makefile.snaplinux
DEV := $(PWD)/libarchive-dev
DEVROOT := $(DEV)/ROOT
$(SRCDIR)/configure: $(ARCHIVE) $(SRCDIR)/configure: $(ARCHIVE)
@if [ '$(TYPE)' == 'application/x-bzip2' ]; then \ @if [ '$(TYPE)' == 'application/x-bzip2' ]; then \
@@ -64,7 +68,17 @@ $(ROOT): $(SRCDIR)/.libs/libarchive.so.$(VERSION)
mkdir -v $(ROOT); \ mkdir -v $(ROOT); \
fi fi
@cd $(SRCDIR) && make install DESTDIR=$(ROOT) @cd $(SRCDIR) && make install DESTDIR=$(ROOT) && \
install -v -d $(DEV)/SL && \
install -v -d $(DEVROOT) && \
for file in `find $(ROOT)| \
egrep 'pkgconfig\/|\.a$$|\.h$$|\.la$$|\.pc$$'`; do \
path=`dirname $$file|sed "s[$(ROOT)[$(DEVROOT)["`; \
mkdir -p $$path; \
mv $$file $$path; \
done
find $(ROOT) -type d -empty -delete && \
cd $(DEV) && make -f ../Makefile.libarchive-dev && mv *.slp ../
test: $(ROOT) test: $(ROOT)
@cd $(SRCDIR); \ @cd $(SRCDIR); \
@@ -72,7 +86,8 @@ test: $(ROOT)
clean: clean:
@rm -rvf $(ROOT) \ @rm -rvf $(ROOT) \
$(SNAPINFO) \ $(DEV) \
$(SLINFO) \
$(MANIFEST) \ $(MANIFEST) \
$(FILES) \ $(FILES) \
$(SRCDIR) $(SRCDIR)