mirror of
https://github.com/talgo-cloud/talgo-libwebp.git
synced 2026-03-15 10:15:58 -07:00
Make to use dependencies and variables.
This commit is contained in:
parent
ad17bf0e32
commit
caba001de3
1 changed files with 17 additions and 17 deletions
34
Makefile
34
Makefile
|
|
@ -1,33 +1,33 @@
|
||||||
BUILDDIR=/tmp
|
repo=github.com/harukasan/go-libwebp
|
||||||
WORKDIR=github.com/harukasan/go-libwebp
|
build_dir=/tmp
|
||||||
CURDIR=$(shell pwd)
|
cur_dir=$(shell pwd)
|
||||||
|
libwebp_so = ${LIBWEBP_PREFIX}/lib/libwebp.so
|
||||||
|
|
||||||
all: test
|
all: test
|
||||||
|
|
||||||
test:
|
test:
|
||||||
go test -v ${WORKDIR}/...
|
go test -v $(repo)/...
|
||||||
|
|
||||||
libwebp:
|
libwebp: $(libwebp_so)
|
||||||
test -e ${LIBWEBP_PREFIX}/lib/libwebp.so || ( \
|
|
||||||
cd ${BUILDDIR} \
|
$(libwebp_so):
|
||||||
&& wget http://downloads.webmproject.org/releases/webp/libwebp-${LIBWEBP_VERSION}.tar.gz \
|
cd $(build_dir) \
|
||||||
&& tar xf libwebp-${LIBWEBP_VERSION}.tar.gz \
|
&& wget http://downloads.webmproject.org/releases/webp/libwebp-${LIBWEBP_VERSION}.tar.gz \
|
||||||
&& cd libwebp-${LIBWEBP_VERSION} \
|
&& tar xf libwebp-${LIBWEBP_VERSION}.tar.gz \
|
||||||
&& ./configure --prefix=${LIBWEBP_PREFIX} \
|
&& cd libwebp-${LIBWEBP_VERSION} \
|
||||||
&& make \
|
&& ./configure --prefix=${LIBWEBP_PREFIX} \
|
||||||
&& make install \
|
&& make \
|
||||||
)
|
&& make install
|
||||||
|
|
||||||
docker-test:
|
docker-test:
|
||||||
docker run -v ${CURDIR}:/go/src/github.com/harukasan/go-libwebp -it go-libwebp
|
docker run -v $(cur_dir):/go/src/$(repo) -it go-libwebp
|
||||||
|
|
||||||
docker-sh:
|
docker-sh:
|
||||||
docker run -v ${CURDIR}:/go/src/github.com/harukasan/go-libwebp -it go-libwebp sh
|
docker run -v $(cur_dir):/go/src/$(repo) -it go-libwebp sh
|
||||||
|
|
||||||
docker-build:
|
docker-build:
|
||||||
docker build -t go-libwebp .
|
docker build -t go-libwebp .
|
||||||
|
|
||||||
|
|
||||||
.PHONY: \
|
.PHONY: \
|
||||||
all \
|
all \
|
||||||
test \
|
test \
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue