Skip to content

Commit 97f5604

Browse files
committed
add php8.4 supporty
1 parent e1f54c2 commit 97f5604

18 files changed

+1282
-0
lines changed

php84al2-arm/Makefile

+16
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,16 @@
1+
SHELL := /bin/bash
2+
3+
compiler: compiler.Dockerfile
4+
docker build -f ${PWD}/compiler.Dockerfile -t vapor/runtime/compiler:latest .
5+
6+
build: compiler
7+
docker build -f ${PWD}/php.Dockerfile -t vapor/runtime/php-84al2-arm:latest $(shell helpers/buildArguments.php php84) .
8+
9+
distribution: build
10+
docker run --rm \
11+
--env PHP_SHORT_VERSION=84al2-arm \
12+
--volume ${PWD}/runtime:/runtime:ro \
13+
--volume ${PWD}/../export:/export \
14+
--volume ${PWD}/export.sh:/export.sh:ro \
15+
vapor/runtime/php-84al2-arm:latest \
16+
/export.sh

php84al2-arm/compiler.Dockerfile

+26
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,26 @@
1+
FROM --platform=linux/arm64 amazonlinux:2
2+
3+
WORKDIR /tmp
4+
5+
# Lock To Proper Release
6+
7+
RUN sed -i 's/releasever=latest/releaserver=amzn2/' /etc/yum.conf
8+
9+
# Install Development Tools
10+
11+
RUN set -xe \
12+
&& yum makecache \
13+
&& yum groupinstall -y "Development Tools" --setopt=group_package_types=mandatory,default
14+
15+
# Install CMake
16+
17+
RUN yum -y install openssl-devel perl-IPC-Cmd
18+
19+
RUN set -xe \
20+
&& mkdir -p /tmp/cmake \
21+
&& cd /tmp/cmake \
22+
&& curl -Ls https://github.com/Kitware/CMake/releases/download/v3.30.1/cmake-3.30.1.tar.gz \
23+
| tar xzC /tmp/cmake --strip-components=1 \
24+
&& ./bootstrap --prefix=/usr/local \
25+
&& make -j $(nproc) \
26+
&& make install

php84al2-arm/export.sh

+26
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,26 @@
1+
#!/bin/bash
2+
3+
set -e
4+
set -u
5+
set -x
6+
7+
cd /opt
8+
9+
cp /runtime/bootstrap bootstrap
10+
cp /runtime/bootstrap.php bootstrap.php
11+
12+
chmod 755 bootstrap
13+
chmod 755 bootstrap.php
14+
15+
rm -rf vapor/
16+
17+
mkdir -p vapor/etc/php/conf.d
18+
cp /runtime/php.ini vapor/etc/php/conf.d/vapor.ini
19+
20+
# cp /runtime/imagick/bin/* bin
21+
# cp /runtime/imagick/lib/* lib
22+
23+
ls -la
24+
25+
zip --quiet --recurse-paths /export/php-${PHP_SHORT_VERSION}.zip . --exclude "*php-cgi"
26+
# zip --delete /export/php-${PHP_SHORT_VERSION}.zip vapor/sbin/php-fpm bin/php-fpm
+12
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,12 @@
1+
#!/usr/bin/env php
2+
<?php
3+
4+
$versions = parse_ini_file(realpath(__DIR__."/../versions.ini"), true);
5+
6+
$buildArguments = '';
7+
8+
foreach ($versions[$argv[1]] as $key => $value){
9+
$buildArguments .= "--build-arg $key=$value ";
10+
}
11+
12+
print $buildArguments;

0 commit comments

Comments
 (0)