This repository was archived by the owner on Jan 23, 2026. It is now read-only.
-
-
Notifications
You must be signed in to change notification settings - Fork 5
Expand file tree
/
Copy pathconfig.mk
More file actions
135 lines (111 loc) · 3.5 KB
/
config.mk
File metadata and controls
135 lines (111 loc) · 3.5 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
# This file is part of the Phalcon.
#
# (c) Phalcon Team <[email protected]>
#
# For the full copyright and license information, please view
# the LICENSE.txt file that was distributed with this source code.
#
# If you did not receive a copy of the license it is available
# through the world-wide-web at the following url:
# https://license.phalcon.io
CHANGELOG_NAME=Phalcon Team
CHANGELOG_EMAIL[email protected]
CHANGELOG_TEXT=Automated build. See details at release page https://github.com/phalcon/cphalcon/releases
PACK_REPO=https://github.com/packpack/packpack.git
PACK_COMMIT=30ff7b51654c19b8919d01ca8d4aa480e87e8241
DOCKER_REPO=phalconphp/build
# Use -vv to display debugging information
RPMBUILD_FLAGS=-vv
PHP_VERSION?=
PHP_MAJOR=$(shell echo "$(PHP_VERSION)" | cut -d '.' -f 1,2)
ZEND_BACKEND?=
REPO_VENDOR?=
RELEASE=
PRODUCT?=php-phalcon
STABLE_BUILD_VERSION?=1
MAINLINE_BUILD_VERSION?=1
NIGHTLY_BUILD_VERSION?=1
# List of supported OS
FEDORA:=fedora-rawhide fedora24 fedora23
CENTOS:=centos7 centos6
DEBIAN:=debian-sid debian-buster debian-stretch debian-wheezy
UBUNTU:=ubuntu-bionic ubuntu-xenial ubuntu-trusty ubuntu-focal ubuntu-groovy
DEBS:=$(DEBIAN) $(UBUNTU)
RPMS:=$(FEDORA) $(CENTOS)
SUPPORTED_PACKAGES=rpm deb
SUPPORTED_VENDORS=ius
ifeq (el,$(OS))
BUILD_OS=centos
else
BUILD_OS=$(OS)
endif
ifneq ($(shell echo "$(DIST)" | grep '^[0-9]\+$$'),)
# Non-numeric dist, e.g. debian-sid, ubuntu-precise, etc.
OSDIST=$(BUILD_OS)$(DIST)
else
# Numeric dist, e.g. centos7 or fedora23
OSDIST=$(BUILD_OS)-$(DIST)
endif
ifeq ($(filter $(OSDIST),$(DEBS) $(RPMS)),)
$(error $(OSDIST) does not exist in supported OS)
endif
ifeq ($(filter $(PACKAGE), $(SUPPORTED_PACKAGES)),)
$(error $(PACKAGE) does not exist in supported package types)
endif
ifeq ($(CLONE_BRANCH), $(STABLE_BRANCH))
PACKAGECLOUD_REPO=$(PACKAGECLOUD_STABLE_REPO)
RELEASE:=$(STABLE_BUILD_VERSION)
else ifeq ($(CLONE_BRANCH), $(MAINLINE_BRANCH))
PACKAGECLOUD_REPO=$(PACKAGECLOUD_MAINLINE_REPO)
RELEASE:=$(MAINLINE_BUILD_VERSION)
else
PACKAGECLOUD_REPO=$(PACKAGECLOUD_NIGHTLY_REPO)
RELEASE:=$(NIGHTLY_BUILD_VERSION)
endif
DOCKER_SUFFIX=
VENDOR_MK=$(filter $(REPO_VENDOR),$(SUPPORTED_VENDORS))
ifneq ($(filter $(VENDOR_MK),$(SUPPORTED_VENDORS)),)
include $(SCRIPTDIR)/builder/$(VENDOR_MK).mk
endif
ifneq ($(PHP_VERSION),)
ifneq ($(filter $(OSDIST),$(DEBS)),)
temp=$(RELEASE)
RELEASE:=$(temp)+php$(PHP_VERSION)
endif
endif
ifeq ($(PHP_VERSION),7.0)
ifneq (,$(filter $(DIST),trusty))
DOCKER_SUFFIX=-7.0
endif
endif
ifeq ($(PHP_VERSION),7.1)
ifneq (,$(filter $(DIST),stretch trusty xenial))
DOCKER_SUFFIX=-7.1
endif
endif
ifeq ($(PHP_VERSION),7.2)
ifneq (,$(filter $(DIST),stretch trusty xenial focal groovy))
DOCKER_SUFFIX=-7.2
endif
endif
ifeq ($(PHP_VERSION),7.3)
ifneq (,$(filter $(DIST),buster stretch trusty xenial bionic focal groovy))
DOCKER_SUFFIX=-7.3
endif
endif
ifeq ($(PHP_VERSION),7.4)
ifneq (,$(filter $(DIST),buster stretch trusty xenial bionic focal groovy))
DOCKER_SUFFIX=-7.4
endif
endif
REVISION=$(shell cd $(SOURCEDIR); git rev-parse --short=8 HEAD)
ifeq (el,$(OS))
VERSION?=$(shell cat "$(SOURCEDIR)/config.json" | grep version | head -1 | sed -E 's|[\", ]||g' | cut -d ':' -f 2 | tr -s '-' | tr '-' '_')
else
VERSION?=$(shell cat "$(SOURCEDIR)/config.json" | grep version | head -1 | sed -E 's|[\", ]||g' | cut -d ':' -f 2)
endif
VERSION_FULL=$(VERSION)-$(RELEASE)-$(REVISION)
DOCKER_IMAGE=$(OSDIST)$(DOCKER_SUFFIX)
DOCKER_TAG=$(DOCKER_REPO):$(OSDIST)$(DOCKER_SUFFIX)
BUILDDIR=$(SCRIPTDIR)/build
TARBALL_EXTRA_ARGS=--exclude=.github --exclude=.editorconfig --exclude=.gitattributes