mirror of
https://github.com/phpv8/v8js.git
synced 2024-12-21 16:31:53 +00:00
remove remains of old travis/jenkins/vagrant testenv stuff
This commit is contained in:
parent
01b5948a94
commit
9f854c5343
@ -40,7 +40,6 @@ tests/*.php
|
||||
tests/*.sh
|
||||
tests/*.mem
|
||||
|
||||
.vagrant
|
||||
tmp-php.ini
|
||||
|
||||
coverage_report/**
|
||||
|
1
.gitignore
vendored
1
.gitignore
vendored
@ -41,7 +41,6 @@ tests/*.php
|
||||
tests/*.sh
|
||||
tests/*.mem
|
||||
|
||||
.vagrant
|
||||
tmp-php.ini
|
||||
|
||||
coverage_report/**
|
||||
|
15
.travis.yml
15
.travis.yml
@ -1,15 +0,0 @@
|
||||
language: php
|
||||
sudo: required
|
||||
|
||||
services:
|
||||
- docker
|
||||
|
||||
env:
|
||||
- V8VER=7.5
|
||||
PHPVER=7.1
|
||||
- V8VER=7.5
|
||||
PHPVER=7.2
|
||||
- V8VER=7.5
|
||||
PHPVER=7.3
|
||||
|
||||
script: make -f Makefile.travis test
|
72
Commandfile
72
Commandfile
@ -1,72 +0,0 @@
|
||||
#
|
||||
# Vagrant Commandfile
|
||||
# (use with vagrant-devcommands plugin)
|
||||
#
|
||||
|
||||
command 'phpize',
|
||||
description: 'executes "phpize" to configure source tree for installed PHP version',
|
||||
script: 'cd /data/v8js && phpize'
|
||||
|
||||
command 'configure',
|
||||
description: 'executes "configure" to prepare build',
|
||||
parameters: {
|
||||
cxxflags: { default: "-ggdb -Wall -Wno-write-strings" },
|
||||
ldflags: { default: "-ggdb -lstdc++" },
|
||||
},
|
||||
script: <<-eof
|
||||
bash -c 'cd /data/build; ../v8js/configure `bash -c "if test -d /opt/libv8-*; then echo -n --with-v8js=; echo /opt/libv8-*; fi"` `test -d "/usr/lib64" && echo --with-libdir=lib64` CXXFLAGS="%{cxxflags}" LDFLAGS="%{ldflags}"'
|
||||
eof
|
||||
|
||||
command 'clean',
|
||||
description: 'executes "make clean"',
|
||||
script: <<-eof
|
||||
cd /data/build; `which gmake || which make` clean; rm -rf /data/v8js/coverage_report /data/build/gcov.info
|
||||
eof
|
||||
|
||||
command 'build',
|
||||
description: 'executes "make"',
|
||||
script: <<-eof
|
||||
cd /data/build; `which gmake || which make` -j4
|
||||
eof
|
||||
|
||||
command 'test',
|
||||
description: 'executes "make test"',
|
||||
parameters: {
|
||||
tests: { wrap: "TESTS=tests/%s", optional: true },
|
||||
},
|
||||
script: <<-eof
|
||||
cd /data/build; `which gmake || which make` test %{tests} NO_INTERACTION=1 REPORT_EXIT_STATUS=1
|
||||
eof
|
||||
|
||||
command 'shell',
|
||||
description: 'execute a PHP CLI interactive shell with V8Js loaded',
|
||||
script: <<-eof
|
||||
cd /data/build; php -a -d extension=modules/v8js.so
|
||||
eof
|
||||
|
||||
chain 'all',
|
||||
commands: [
|
||||
{ command: 'phpize' },
|
||||
{ command: 'configure' },
|
||||
{ command: 'clean' },
|
||||
{ command: 'build' },
|
||||
{ command: 'test' }
|
||||
]
|
||||
|
||||
command 'coverage_report',
|
||||
description: 'capture *.gcda files and generate code coverage report',
|
||||
script: <<-eof
|
||||
cd /data/build
|
||||
lcov --base-directory=.libs --directory=.libs --directory ../v8js/ --no-external --capture --output-file gcov.info
|
||||
genhtml --legend --output-directory ../v8js/coverage_report/ --title "V8Js Code Coverage" gcov.info
|
||||
eof
|
||||
|
||||
chain 'coverage',
|
||||
commands: [
|
||||
{ command: 'phpize' },
|
||||
{ command: 'configure', argv: ['--cxxflags=-O0 --coverage', '--ldflags=--coverage'] },
|
||||
{ command: 'clean' },
|
||||
{ command: 'build' },
|
||||
{ command: 'test' },
|
||||
{ command: 'coverage_report' },
|
||||
]
|
@ -1,22 +0,0 @@
|
||||
ARG V8VER
|
||||
FROM stesie/libv8-${V8VER}:latest
|
||||
|
||||
ARG PHPVER
|
||||
|
||||
ENV DEBIAN_FRONTEND=noninteractive
|
||||
ENV LC_ALL=C.UTF-8
|
||||
ENV NO_INTERACTION=1
|
||||
ENV REPORT_EXIT_STATUS=1
|
||||
|
||||
RUN apt-get update -q
|
||||
RUN apt-get install -y wget autoconf build-essential libreadline-dev pkg-config
|
||||
|
||||
RUN wget https://www.php.net/distributions/php-${PHPVER}.tar.gz && \
|
||||
tar xzf php-${PHPVER}.tar.gz
|
||||
ADD . /php-${PHPVER}/ext/v8js
|
||||
WORKDIR /php-${PHPVER}
|
||||
|
||||
RUN ./buildconf --force
|
||||
RUN ./configure --disable-all --with-readline --enable-cli --enable-json --enable-maintainer-zts --with-v8js=/opt/libv8-$V8VER/ CFLAGS="-fsanitize=address -g -O0" CXXFLAGS="-fsanitize=address -g -O0" CPPFLAGS="$([ $( echo "$V8VER" | cut -c 1-1 ) -ge 8 ] && echo "-DV8_COMPRESS_POINTERS" || echo "")"
|
||||
RUN sed -e "s/^EXTRA_LIBS.*/& -lv8_libplatform -ldl/" -i Makefile
|
||||
RUN make -j5
|
@ -1,22 +0,0 @@
|
||||
FROM ubuntu:xenial
|
||||
|
||||
ENV DEBIAN_FRONTEND=noninteractive
|
||||
ENV LC_ALL=C.UTF-8
|
||||
ENV NO_INTERACTION=1
|
||||
ENV REPORT_EXIT_STATUS=1
|
||||
|
||||
RUN apt-get update -q
|
||||
RUN apt-get install -y software-properties-common
|
||||
|
||||
RUN add-apt-repository ppa:ondrej/php
|
||||
RUN add-apt-repository ppa:stesie/libv8 -y
|
||||
RUN apt-get update -q
|
||||
|
||||
RUN apt-get install -y php$PHPVER-dev libv8-$V8VER-dev
|
||||
|
||||
ADD . /app
|
||||
WORKDIR /app
|
||||
|
||||
RUN phpize
|
||||
RUN ./configure CXXFLAGS="-Wall -Wno-write-strings" LDFLAGS="-lstdc++" --with-v8js=/opt/libv8-$V8VER/
|
||||
RUN make -j4
|
34
Jenkinsfile
vendored
34
Jenkinsfile
vendored
@ -1,34 +0,0 @@
|
||||
pipeline {
|
||||
agent none
|
||||
stages {
|
||||
stage('BuildAndTest') {
|
||||
matrix {
|
||||
agent any
|
||||
axes {
|
||||
axis {
|
||||
name 'PHPVER'
|
||||
values '7.3.21', '7.4.9'
|
||||
}
|
||||
axis {
|
||||
name 'V8VER'
|
||||
values '7.9', '8.4', '8.6'
|
||||
}
|
||||
}
|
||||
stages {
|
||||
stage('Build') {
|
||||
steps {
|
||||
echo "Building w/ V8 ${V8VER}, PHP ${PHPVER} as Docker image ${BUILD_TAG}-${V8VER}-${PHPVER}"
|
||||
sh "docker build -f Dockerfile.jenkins --build-arg V8VER=${V8VER} --build-arg PHPVER=${PHPVER} -t ${BUILD_TAG}-${V8VER}-${PHPVER} ."
|
||||
}
|
||||
}
|
||||
stage('Test') {
|
||||
steps {
|
||||
echo "Running test on ${BUILD_TAG}-${V8VER}-${PHPVER}"
|
||||
sh "docker run --rm -t ${BUILD_TAG}-${V8VER}-${PHPVER} make test TESTS='ext/v8js/tests/*.phpt'"
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
@ -1,16 +0,0 @@
|
||||
# Configure and build scripts for travis CI system
|
||||
V8VER ?= 7.5
|
||||
|
||||
IMAGENAME ?= v8js-test
|
||||
|
||||
export NO_INTERACTION=1
|
||||
export REPORT_EXIT_STATUS=1
|
||||
|
||||
build:
|
||||
envsubst < Dockerfile.travis > Dockerfile.tmp
|
||||
docker build -t $(IMAGENAME) -f Dockerfile.tmp .
|
||||
|
||||
test: build
|
||||
docker run --rm -t $(IMAGENAME) make test
|
||||
|
||||
.PHONY: build test
|
@ -1,8 +1,7 @@
|
||||
V8Js
|
||||
====
|
||||
|
||||
[![Build Status](https://travis-ci.org/phpv8/v8js.svg?branch=php7)](https://travis-ci.org/phpv8/v8js)
|
||||
[![Test building extension](https://github.com/JoshuaBehrens/v8js/actions/workflows/build-test.yml/badge.svg)](https://github.com/JoshuaBehrens/v8js/actions/workflows/build-test.yml)
|
||||
[![Test building extension](https://github.com/phpv8/v8js/actions/workflows/build-test.yml/badge.svg)](https://github.com/phpv8/v8js/actions/workflows/build-test.yml)
|
||||
[![GitHub license](https://img.shields.io/badge/license-MIT-blue.svg)](https://raw.githubusercontent.com/phpv8/v8js/master/LICENSE)
|
||||
[![Join the chat at https://gitter.im/phpv8/v8js](https://badges.gitter.im/Join%20Chat.svg)](https://gitter.im/phpv8/v8js?utm_source=badge&utm_medium=badge&utm_campaign=pr-badge&utm_content=badge)
|
||||
|
||||
|
107
Vagrantfile
vendored
107
Vagrantfile
vendored
@ -1,107 +0,0 @@
|
||||
# -*- mode: ruby -*-
|
||||
# vi: set ft=ruby ts=2 sts=2 sw=2 et :
|
||||
|
||||
# All Vagrant configuration is done below. The "2" in Vagrant.configure
|
||||
# configures the configuration version (we support older styles for
|
||||
# backwards compatibility). Please don't change it unless you know what
|
||||
# you're doing.
|
||||
Vagrant.configure("2") do |config|
|
||||
# Every Vagrant development environment requires a box. You can search for
|
||||
# boxes at https://atlas.hashicorp.com/search.
|
||||
config.vm.box = "ubuntu/bionic64"
|
||||
|
||||
|
||||
#
|
||||
# mass-define "generic" Ubuntu boxes
|
||||
#
|
||||
%w{7.5}.each { |version|
|
||||
config.vm.define "v8-#{version}" do |i|
|
||||
i.vm.synced_folder ".", "/data/v8js"
|
||||
|
||||
i.vm.provision "shell", inline: <<-SHELL
|
||||
gpg --keyserver keys.gnupg.net --recv 7F438280EF8D349F
|
||||
gpg --armor --export 7F438280EF8D349F | apt-key add -
|
||||
|
||||
apt-get update
|
||||
apt-get install -y software-properties-common gdb tmux git tig curl apache2-utils lcov
|
||||
|
||||
add-apt-repository ppa:ondrej/php
|
||||
add-apt-repository ppa:stesie/libv8
|
||||
apt-get update
|
||||
apt-get install -y php7.1-dev libv8-#{version}-dbg libv8-#{version}-dev
|
||||
SHELL
|
||||
end
|
||||
}
|
||||
|
||||
%w{}.each { |version|
|
||||
config.vm.define "v8-#{version}" do |i|
|
||||
i.vm.synced_folder ".", "/data/v8js"
|
||||
|
||||
i.vm.provision "shell", inline: <<-SHELL
|
||||
gpg --keyserver keys.gnupg.net --recv 7F438280EF8D349F
|
||||
gpg --armor --export 7F438280EF8D349F | apt-key add -
|
||||
|
||||
apt-get update
|
||||
apt-get install -y software-properties-common gdb tmux git tig curl apache2-utils lcov build-essential python libglib2.0-dev
|
||||
|
||||
add-apt-repository ppa:ondrej/php
|
||||
apt-get update
|
||||
apt-get install -y php7.1-dev
|
||||
|
||||
mkdir -p /data
|
||||
cd /data
|
||||
|
||||
# Install depot_tools first (needed for source checkout)
|
||||
git clone https://chromium.googlesource.com/chromium/tools/depot_tools.git
|
||||
export PATH=`pwd`/depot_tools:"$PATH"
|
||||
|
||||
# Download v8
|
||||
fetch v8
|
||||
cd v8
|
||||
|
||||
# checkout version
|
||||
git checkout #{version}
|
||||
gclient sync
|
||||
|
||||
# Setup GN
|
||||
tools/dev/v8gen.py -vv x64.release -- is_component_build=true
|
||||
|
||||
# Build
|
||||
ninja -C out.gn/x64.release/
|
||||
|
||||
# Install to /opt/libv8-#{version}/
|
||||
sudo mkdir -p /opt/libv8-#{version}/{lib,include}
|
||||
sudo cp out.gn/x64.release/lib*.so out.gn/x64.release/*_blob.bin out.gn/x64.release/icudtl.dat /opt/libv8-#{version}/lib/
|
||||
sudo cp -R include/* /opt/libv8-#{version}/include/
|
||||
SHELL
|
||||
end
|
||||
}
|
||||
|
||||
config.vm.define "php-7.4" do |i|
|
||||
i.vm.synced_folder ".", "/data/v8js"
|
||||
|
||||
i.vm.provision "shell", inline: <<-SHELL
|
||||
gpg --keyserver keys.gnupg.net --recv 7F438280EF8D349F
|
||||
gpg --armor --export 7F438280EF8D349F | apt-key add -
|
||||
|
||||
apt-get update
|
||||
apt-get install -y software-properties-common gdb tmux git tig curl apache2-utils lcov
|
||||
|
||||
add-apt-repository ppa:stesie/libv8
|
||||
apt-get update
|
||||
apt-get install -y libv8-7.5-dbg libv8-7.5-dev
|
||||
|
||||
test -x /tmp/php-src || git clone https://github.com/php/php-src.git /tmp/php-src -b PHP-7.4 --depth 1
|
||||
cd /tmp/php-src
|
||||
apt-get install -y build-essential bison re2c libreadline-dev
|
||||
./buildconf
|
||||
./configure --disable-all --with-readline
|
||||
make -j4
|
||||
make install
|
||||
SHELL
|
||||
end
|
||||
|
||||
config.vm.provision "shell", privileged: false, inline: <<-SHELL
|
||||
sudo mkdir -p /data/build && sudo chown $USER:$USER /data/build
|
||||
SHELL
|
||||
end
|
Loading…
Reference in New Issue
Block a user