mirror of
https://github.com/24eme/signaturepdf
synced 2026-03-14 13:55:44 +01:00
deb: on créé le .deb en makefile
This commit is contained in:
parent
7952c925fd
commit
f8317492df
7 changed files with 82 additions and 0 deletions
7
.debian/changelog
Normal file
7
.debian/changelog
Normal file
|
|
@ -0,0 +1,7 @@
|
|||
~#PKGNAME#~ (~#VERSION#~-~#RELEASE#~) UNRELEASED; urgency=low
|
||||
|
||||
* Please check the
|
||||
https://github.com/~#VENDOR#~/~#PROJECT#~
|
||||
commit history
|
||||
|
||||
-- Nicola Asuni <info@tecnick.com> ~#DATE#~
|
||||
1
.debian/compat
Normal file
1
.debian/compat
Normal file
|
|
@ -0,0 +1 @@
|
|||
9
|
||||
15
.debian/control
Normal file
15
.debian/control
Normal file
|
|
@ -0,0 +1,15 @@
|
|||
Source: ~#PKGNAME#~
|
||||
Maintainer: Nicola Asuni <info@tecnick.com>
|
||||
Section: php
|
||||
Priority: optional
|
||||
Build-Depends: debhelper (>= 9)
|
||||
Standards-Version: 3.9.7
|
||||
Homepage: https://github.com/~#VENDOR#~/~#PROJECT#~
|
||||
Vcs-Git: https://github.com/~#VENDOR#~/~#PROJECT#~.git
|
||||
|
||||
Package: ~#PKGNAME#~
|
||||
Provides: php-~#PROJECT#~
|
||||
Architecture: all
|
||||
Depends: php (>= 8.0.0), php-date, php-tecnickcom-tc-lib-barcode (<< 3.0.0), php-tecnickcom-tc-lib-barcode (>= 2.2.3), php-tecnickcom-tc-lib-color (<< 3.0.0), php-tecnickcom-tc-lib-color (>= 2.2.2), php-tecnickcom-tc-lib-pdf-image (<< 3.0.0), php-tecnickcom-tc-lib-pdf-image (>= 2.1.1), php-tecnickcom-tc-lib-pdf-font (<< 3.0.0), php-tecnickcom-tc-lib-pdf-font (>= 2.5.0), php-tecnickcom-tc-lib-file (<< 3.0.0), php-tecnickcom-tc-lib-file (>= 2.0.13), php-tecnickcom-tc-lib-pdf-encrypt (<< 3.0.0), php-tecnickcom-tc-lib-pdf-encrypt (>= 2.1.4), php-tecnickcom-tc-lib-unicode-data (<< 3.0.0), php-tecnickcom-tc-lib-unicode-data (>= 2.0.13), php-tecnickcom-tc-lib-unicode (<< 3.0.0), php-tecnickcom-tc-lib-unicode (>= 2.0.13), php-tecnickcom-tc-lib-pdf-page (<< 5.0.0), php-tecnickcom-tc-lib-pdf-page (>= 4.2.0), php-tecnickcom-tc-lib-pdf-graph (<< 3.0.0), php-tecnickcom-tc-lib-pdf-graph (>= 2.1.1), ${misc:Depends}
|
||||
Description: PHP Barcode library
|
||||
This library includes PHP classes to generate PDF documents.
|
||||
20
.debian/copyright
Normal file
20
.debian/copyright
Normal file
|
|
@ -0,0 +1,20 @@
|
|||
Format: http://www.debian.org/doc/packaging-manuals/copyright-format/1.0/
|
||||
Upstream-Name: ~#PROJECT#~
|
||||
Source: https://github.com/~#VENDOR#~/~#PROJECT#~
|
||||
|
||||
Files: *
|
||||
Copyright: Copyright 2001-2024 Nicola Asuni <info@tecnick.com>
|
||||
License: LGPL-3
|
||||
|
||||
License: LGPL-3
|
||||
This program is free software: you can redistribute it and/or modify
|
||||
it under the terms of the GNU Lesser General Public License as
|
||||
published by the Free Software Foundation, either version 3 of the
|
||||
License, or (at your option) any later version.
|
||||
This program is distributed in the hope that it will be useful,
|
||||
but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
GNU General Public License for more details.
|
||||
You should have received a copy of the GNU General Public License
|
||||
along with this program. If not, see <http://www.gnu.org/licenses/> or
|
||||
/usr/share/common-licenses/LGPL-3
|
||||
3
.debian/rules
Normal file
3
.debian/rules
Normal file
|
|
@ -0,0 +1,3 @@
|
|||
#!/usr/bin/make -f
|
||||
%:
|
||||
dh $@
|
||||
1
.debian/source/format
Normal file
1
.debian/source/format
Normal file
|
|
@ -0,0 +1 @@
|
|||
3.0 (quilt)
|
||||
35
Makefile
35
Makefile
|
|
@ -2,6 +2,19 @@
|
|||
|
||||
.DEFAULT_GOAL := all
|
||||
|
||||
VENDOR=24eme
|
||||
PROJECT=signaturepdf
|
||||
VERSION=$(shell cat VERSION)
|
||||
RELEASE=$(shell cat RELEASE)
|
||||
PKGNAME=php-${PROJECT}
|
||||
DATADIR=usr/share
|
||||
LIBPATH=$(DATADIR)/$(PKGNAME)/
|
||||
CONFIGPATH=etc/$(PKGNAME)/
|
||||
|
||||
CURRENTDIR=$(dir $(realpath $(firstword $(MAKEFILE_LIST))))
|
||||
TARGETDIR=$(CURRENTDIR)target
|
||||
PATHDEBPKG=$(TARGETDIR)/DEB
|
||||
|
||||
all: update_trad
|
||||
|
||||
node_modules/jest/bin/jest.js:
|
||||
|
|
@ -44,3 +57,25 @@ update_trad:
|
|||
git add "$$lang/LC_MESSAGES/application_$$checksum.mo"; \
|
||||
git add "locale/application_$$checksum.pot"; \
|
||||
done
|
||||
|
||||
# Build a DEB package for Debian-like Linux distributions
|
||||
.PHONY: deb
|
||||
deb:
|
||||
rm -rf $(PATHDEBPKG)
|
||||
git clone . $(PATHDEBPKG)/$(PKGNAME)-$(VERSION)/$(LIBPATH)
|
||||
rm -rf $(PATHDEBPKG)/$(PKGNAME)-$(VERSION)/$(LIBPATH)/.git
|
||||
tar -zcvf $(PATHDEBPKG)/$(PKGNAME)_$(VERSION).orig.tar.gz -C $(PATHDEBPKG)/ $(PKGNAME)-$(VERSION)
|
||||
cp -rf ./.debian $(PATHDEBPKG)/$(PKGNAME)-$(VERSION)/debian
|
||||
find $(PATHDEBPKG)/$(PKGNAME)-$(VERSION)/debian/ -type f -exec sed -i "s/~#DATE#~/`date -R`/" {} \;
|
||||
find $(PATHDEBPKG)/$(PKGNAME)-$(VERSION)/debian/ -type f -exec sed -i "s/~#VENDOR#~/$(VENDOR)/" {} \;
|
||||
find $(PATHDEBPKG)/$(PKGNAME)-$(VERSION)/debian/ -type f -exec sed -i "s/~#PROJECT#~/$(PROJECT)/" {} \;
|
||||
find $(PATHDEBPKG)/$(PKGNAME)-$(VERSION)/debian/ -type f -exec sed -i "s/~#PKGNAME#~/$(PKGNAME)/" {} \;
|
||||
find $(PATHDEBPKG)/$(PKGNAME)-$(VERSION)/debian/ -type f -exec sed -i "s/~#VERSION#~/$(VERSION)/" {} \;
|
||||
find $(PATHDEBPKG)/$(PKGNAME)-$(VERSION)/debian/ -type f -exec sed -i "s/~#RELEASE#~/$(RELEASE)/" {} \;
|
||||
echo $(LIBPATH) > $(PATHDEBPKG)/$(PKGNAME)-$(VERSION)/debian/$(PKGNAME).dirs
|
||||
echo "$(LIBPATH)* $(LIBPATH)" > $(PATHDEBPKG)/$(PKGNAME)-$(VERSION)/debian/install
|
||||
ifneq ($(strip $(CONFIGPATH)),)
|
||||
echo $(CONFIGPATH) >> $(PATHDEBPKG)/$(PKGNAME)-$(VERSION)/debian/$(PKGNAME).dirs
|
||||
echo "$(CONFIGPATH)* $(CONFIGPATH)" >> $(PATHDEBPKG)/$(PKGNAME)-$(VERSION)/debian/install
|
||||
endif
|
||||
cd $(PATHDEBPKG)/$(PKGNAME)-$(VERSION) && debuild -us -uc
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue