Compare commits
1 Commits
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
3c37329cf1 |
16
Makefile
16
Makefile
@@ -16,7 +16,7 @@
|
|||||||
# server. This might be one of core, main, dev, or
|
# server. This might be one of core, main, dev, or
|
||||||
# perhaps others.
|
# perhaps others.
|
||||||
# * BRIEF: Short description, should be 50 chars or less
|
# * BRIEF: Short description, should be 50 chars or less
|
||||||
# * SNAPVER: This is the package version. When a package is
|
# * SLVER: This is the package version. When a package is
|
||||||
# changed, but no changes are made to the source code
|
# changed, but no changes are made to the source code
|
||||||
# this value should be increased. This would include
|
# this value should be increased. This would include
|
||||||
# things like usher being modified, changes to default
|
# things like usher being modified, changes to default
|
||||||
@@ -34,7 +34,7 @@
|
|||||||
# * PATCHDIR: This directory should be ./SRC/patches and is
|
# * PATCHDIR: This directory should be ./SRC/patches and is
|
||||||
# required, whether or not patches are used.
|
# required, whether or not patches are used.
|
||||||
# * VERSION: This should be set automatically based on the
|
# * VERSION: This should be set automatically based on the
|
||||||
# version string in the source directory and SNAPVER.
|
# version string in the source directory and SLVER.
|
||||||
# The default command here should work in many cases,
|
# The default command here should work in many cases,
|
||||||
# but certain packages may need to use a different
|
# but certain packages may need to use a different
|
||||||
# method.
|
# method.
|
||||||
@@ -69,16 +69,16 @@ export URL = http://www.libpng.org/pub/png/libpng.html
|
|||||||
REPO = main
|
REPO = main
|
||||||
BRIEF = libpng is the official PNG reference library
|
BRIEF = libpng is the official PNG reference library
|
||||||
DESC = libpng is the official PNG reference library
|
DESC = libpng is the official PNG reference 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
|
||||||
export VERSION := $(shell echo $(SRCDIR)|egrep -o '\-[0-9].*'| \
|
export VERSION := $(shell echo $(SRCDIR)|egrep -o '\-[0-9].*'| \
|
||||||
sed 's/^-//')-$(SNAPVER)
|
sed 's/^-//')-$(SLVER)
|
||||||
|
|
||||||
include /usr/share/snap/Makefile.snaplinux
|
include /usr/share/sl/Makefile.snaplinux
|
||||||
|
|
||||||
DEV := $(PWD)/$(PACKAGE)-dev
|
DEV := $(PWD)/$(PACKAGE)-dev
|
||||||
DEVROOT := $(DEV)/ROOT
|
DEVROOT := $(DEV)/ROOT
|
||||||
@@ -126,7 +126,7 @@ $(ROOT): $(SRCDIR)/binfile
|
|||||||
fi
|
fi
|
||||||
|
|
||||||
@cd $(SRCDIR) && make install DESTDIR=$(ROOT) && \
|
@cd $(SRCDIR) && make install DESTDIR=$(ROOT) && \
|
||||||
install -v -d $(DEV)/SNAP && \
|
install -v -d $(DEV)/SL && \
|
||||||
install -v -d $(DEVROOT) && \
|
install -v -d $(DEVROOT) && \
|
||||||
for file in `find $(ROOT)| \
|
for file in `find $(ROOT)| \
|
||||||
egrep 'man3\/|pkgconfig\/|\.a$$|\.h$$|\.la$$|\.pc$$'`; do \
|
egrep 'man3\/|pkgconfig\/|\.a$$|\.h$$|\.la$$|\.pc$$'`; do \
|
||||||
@@ -135,7 +135,7 @@ $(ROOT): $(SRCDIR)/binfile
|
|||||||
mv $$file $$path; \
|
mv $$file $$path; \
|
||||||
done
|
done
|
||||||
find $(ROOT) -type d -empty -delete && \
|
find $(ROOT) -type d -empty -delete && \
|
||||||
cd $(DEV) && make -f ../Makefile.dev && mv *.snap ../
|
cd $(DEV) && make -f ../Makefile.dev && mv *.slp ../
|
||||||
|
|
||||||
test: $(ROOT)
|
test: $(ROOT)
|
||||||
@cd $(SRCDIR); \
|
@cd $(SRCDIR); \
|
||||||
@@ -144,7 +144,7 @@ test: $(ROOT)
|
|||||||
clean:
|
clean:
|
||||||
@rm -rvf $(ROOT) \
|
@rm -rvf $(ROOT) \
|
||||||
$(DEV) \
|
$(DEV) \
|
||||||
$(SNAPINFO) \
|
$(SLINFO) \
|
||||||
$(MANIFEST) \
|
$(MANIFEST) \
|
||||||
$(FILES) \
|
$(FILES) \
|
||||||
$(SRCDIR)
|
$(SRCDIR)
|
||||||
|
|||||||
@@ -13,4 +13,4 @@ REPO = dev
|
|||||||
BRIEF = Development files for libpng
|
BRIEF = Development files for libpng
|
||||||
DESC = Development files for libpng
|
DESC = Development files for libpng
|
||||||
|
|
||||||
include /usr/share/snap/Makefile.snaplinux
|
include /usr/share/sl/Makefile.snaplinux
|
||||||
|
|||||||
Reference in New Issue
Block a user