Commit aeaab2ef authored by Lorenzo Setale's avatar Lorenzo Setale

uses custom IPFS_PKG_VERSION

parent 4da32963
......@@ -11,7 +11,7 @@ ifeq ($(ARCH),arm)
endif
IPFS_VERSION:=$(shell curl -s https://dist.ipfs.io/go-ipfs/versions | tail -n 1)
NUMBER_IPFS_VERSION:=$(shell echo ${IPFS_VERSION} | sed 's/v//')
IPFS_PKG_VERSION:=$(shell echo ${IPFS_VERSION} | sed 's/v//')-1
EMAIL ?= "hello@siderus.io"
DEBFULLNAME ?= "Siderus OU"
......@@ -29,39 +29,40 @@ _unpack_ipfs: _download_ipfs
.PHONY: _unpack_ipfs
_prepare_ipfs_deb: _unpack_ipfs
mkdir -p build/deb/${DEB_ARCH}/ipfs-${NUMBER_IPFS_VERSION}
cp -aR source/ipfs.deb/* build/deb/${DEB_ARCH}/ipfs-${NUMBER_IPFS_VERSION}/
@echo "Source: ipfs" >> build/deb/${DEB_ARCH}/ipfs-${NUMBER_IPFS_VERSION}/debian/control
@echo "Section: misc" >> build/deb/${DEB_ARCH}/ipfs-${NUMBER_IPFS_VERSION}/debian/control
@echo "Priority: optional" >> build/deb/${DEB_ARCH}/ipfs-${NUMBER_IPFS_VERSION}/debian/control
@echo "Maintainer: ${DEBFULLNAME} <${EMAIL}>" >> build/deb/${DEB_ARCH}/ipfs-${NUMBER_IPFS_VERSION}/debian/control
@echo "Build-Depends: debhelper (>= 9)" >> build/deb/${DEB_ARCH}/ipfs-${NUMBER_IPFS_VERSION}/debian/control
@echo "Standards-Version: ${NUMBER_IPFS_VERSION}" >> build/deb/${DEB_ARCH}/ipfs-${NUMBER_IPFS_VERSION}/debian/control
@echo "" >> build/deb/${DEB_ARCH}/ipfs-${NUMBER_IPFS_VERSION}/debian/control
@echo "Package: ipfs" >> build/deb/${DEB_ARCH}/ipfs-${NUMBER_IPFS_VERSION}/debian/control
# @echo "Depends: " >> build/deb/${DEB_ARCH}/ipfs-${NUMBER_IPFS_VERSION}/debian/control
@echo "Architecture: ${DEB_ARCH}" >> build/deb/${DEB_ARCH}/ipfs-${NUMBER_IPFS_VERSION}/debian/control
@echo "Description: IPFS is a global, versioned, peer-to-peer filesystem." >> build/deb/${DEB_ARCH}/ipfs-${NUMBER_IPFS_VERSION}/debian/control
@echo " It combines good ideas from Git, BitTorrent, Kademlia," >> build/deb/${DEB_ARCH}/ipfs-${NUMBER_IPFS_VERSION}/debian/control
@echo " SFS, and the Web. It is like a single bittorrent swarm," >> build/deb/${DEB_ARCH}/ipfs-${NUMBER_IPFS_VERSION}/debian/control
@echo " exchanging git objects. IPFS provides an interface as" >> build/deb/${DEB_ARCH}/ipfs-${NUMBER_IPFS_VERSION}/debian/control
@echo " simple as the HTTP web, but with permanence built in." >> build/deb/${DEB_ARCH}/ipfs-${NUMBER_IPFS_VERSION}/debian/control
@echo " You can also mount the world at /ipfs." >> build/deb/${DEB_ARCH}/ipfs-${NUMBER_IPFS_VERSION}/debian/control
@echo " This package is maintained and distributed by Siderus." >> build/deb/${DEB_ARCH}/ipfs-${NUMBER_IPFS_VERSION}/debian/control
mkdir -p build/deb/${DEB_ARCH}/ipfs-${IPFS_PKG_VERSION}
cp -aR source/ipfs.deb/* build/deb/${DEB_ARCH}/ipfs-${IPFS_PKG_VERSION}/
@echo "Source: ipfs" >> build/deb/${DEB_ARCH}/ipfs-${IPFS_PKG_VERSION}/debian/control
@echo "Section: misc" >> build/deb/${DEB_ARCH}/ipfs-${IPFS_PKG_VERSION}/debian/control
@echo "Priority: optional" >> build/deb/${DEB_ARCH}/ipfs-${IPFS_PKG_VERSION}/debian/control
@echo "Maintainer: ${DEBFULLNAME} <${EMAIL}>" >> build/deb/${DEB_ARCH}/ipfs-${IPFS_PKG_VERSION}/debian/control
@echo "Build-Depends: debhelper (>= 9)" >> build/deb/${DEB_ARCH}/ipfs-${IPFS_PKG_VERSION}/debian/control
@echo "Standards-Version: ${IPFS_PKG_VERSION}" >> build/deb/${DEB_ARCH}/ipfs-${IPFS_PKG_VERSION}/debian/control
@echo "" >> build/deb/${DEB_ARCH}/ipfs-${IPFS_PKG_VERSION}/debian/control
@echo "Package: ipfs" >> build/deb/${DEB_ARCH}/ipfs-${IPFS_PKG_VERSION}/debian/control
# @echo "Depends: " >> build/deb/${DEB_ARCH}/ipfs-${IPFS_PKG_VERSION}/debian/control
@echo "Architecture: ${DEB_ARCH}" >> build/deb/${DEB_ARCH}/ipfs-${IPFS_PKG_VERSION}/debian/control
@echo "Description: IPFS is a global, versioned, peer-to-peer filesystem." >> build/deb/${DEB_ARCH}/ipfs-${IPFS_PKG_VERSION}/debian/control
@echo " It combines good ideas from Git, BitTorrent, Kademlia," >> build/deb/${DEB_ARCH}/ipfs-${IPFS_PKG_VERSION}/debian/control
@echo " SFS, and the Web. It is like a single bittorrent swarm," >> build/deb/${DEB_ARCH}/ipfs-${IPFS_PKG_VERSION}/debian/control
@echo " exchanging git objects. IPFS provides an interface as" >> build/deb/${DEB_ARCH}/ipfs-${IPFS_PKG_VERSION}/debian/control
@echo " simple as the HTTP web, but with permanence built in." >> build/deb/${DEB_ARCH}/ipfs-${IPFS_PKG_VERSION}/debian/control
@echo " You can also mount the world at /ipfs." >> build/deb/${DEB_ARCH}/ipfs-${IPFS_PKG_VERSION}/debian/control
@echo " This package is maintained and distributed by Siderus." >> build/deb/${DEB_ARCH}/ipfs-${IPFS_PKG_VERSION}/debian/control
# Building the changelog
@echo "ipfs (${NUMBER_IPFS_VERSION}) internal; urgency=low" >> build/deb/${DEB_ARCH}/ipfs-${NUMBER_IPFS_VERSION}/debian/changelog
@echo " " >> build/deb/${DEB_ARCH}/ipfs-${NUMBER_IPFS_VERSION}/debian/changelog
@echo " This package has been built by Siderus using an automation pipeline. Please" >> build/deb/${DEB_ARCH}/ipfs-${NUMBER_IPFS_VERSION}/debian/changelog
@echo " refer to the official go-ipfs changelog for more information" >> build/deb/${DEB_ARCH}/ipfs-${NUMBER_IPFS_VERSION}/debian/changelog
@echo " " >> build/deb/${DEB_ARCH}/ipfs-${NUMBER_IPFS_VERSION}/debian/changelog
@echo " -- ${DEBFULLNAME} <${EMAIL}> $(shell date -R)" >> build/deb/${DEB_ARCH}/ipfs-${NUMBER_IPFS_VERSION}/debian/changelog
chmod +x build/deb/${DEB_ARCH}/ipfs-${NUMBER_IPFS_VERSION}/debian/rules
@echo "ipfs (${IPFS_PKG_VERSION}) internal; urgency=low" >> build/deb/${DEB_ARCH}/ipfs-${IPFS_PKG_VERSION}/debian/changelog
@echo " " >> build/deb/${DEB_ARCH}/ipfs-${IPFS_PKG_VERSION}/debian/changelog
@echo " This package has been built by Siderus using an automation pipeline. Please" >> build/deb/${DEB_ARCH}/ipfs-${IPFS_PKG_VERSION}/debian/changelog
@echo " refer to the official go-ipfs changelog for more information" >> build/deb/${DEB_ARCH}/ipfs-${IPFS_PKG_VERSION}/debian/changelog
@echo " " >> build/deb/${DEB_ARCH}/ipfs-${IPFS_PKG_VERSION}/debian/changelog
@echo " -- ${DEBFULLNAME} <${EMAIL}> $(shell date -R)" >> build/deb/${DEB_ARCH}/ipfs-${IPFS_PKG_VERSION}/debian/changelog
chmod +x build/deb/${DEB_ARCH}/ipfs-${IPFS_PKG_VERSION}/debian/rules
# Move the source here
cp -aR build/source/go-ipfs/${ARCH}/go-ipfs build/deb/${DEB_ARCH}/ipfs-${NUMBER_IPFS_VERSION}/
cp -aR build/source/go-ipfs/${ARCH}/go-ipfs build/deb/${DEB_ARCH}/ipfs-${IPFS_PKG_VERSION}/
.PHONY: _prepare_ipfs_deb
_build_ipfs_deb_package: _prepare_ipfs_deb
cd build/deb/${DEB_ARCH}/ipfs-${NUMBER_IPFS_VERSION} ;\
cd build/deb/${DEB_ARCH}/ipfs-${IPFS_PKG_VERSION} ;\
dpkg-buildpackage -us -uc -d --host-arch ${DEB_ARCH}
.PHONY: ipfs_deb_package
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment