Skip to content
Snippets Groups Projects
Commit 17e01686 authored by murgatroid99's avatar murgatroid99
Browse files

Add ARM Linux Node artifacts

parent b2eceb16
No related branches found
No related tags found
No related merge requests found
...@@ -101,6 +101,14 @@ RUN /bin/bash -l -c "gem install bundler --no-ri --no-rdoc" ...@@ -101,6 +101,14 @@ RUN /bin/bash -l -c "gem install bundler --no-ri --no-rdoc"
RUN apt-get update && apt-get install -y \ RUN apt-get update && apt-get install -y \
php5 php5-dev php-pear phpunit php5 php5-dev php-pear phpunit
##################
# Install cross compiler for ARM
RUN echo 'deb http://emdebian.org/tools/debian/ jessie main' | tee -a /etc/apt/sources.list.d/crosstools.list && \
curl http://emdebian.org/tools/debian/emdebian-toolchain-archive.key | apt-key add -
RUN dpkg --add-architecture armhf && apt-get update && apt-get install -y crossbuild-essential-armhf
RUN mkdir /var/local/jenkins RUN mkdir /var/local/jenkins
# Define the default command. # Define the default command.
......
...@@ -279,11 +279,12 @@ class NodeExtArtifact: ...@@ -279,11 +279,12 @@ class NodeExtArtifact:
return create_docker_jobspec( return create_docker_jobspec(
self.name, self.name,
'tools/dockerfile/grpc_artifact_linux_{}'.format(self.arch), 'tools/dockerfile/grpc_artifact_linux_{}'.format(self.arch),
'tools/run_tests/artifacts/build_artifact_node.sh {}'.format(self.gyp_arch)) 'tools/run_tests/artifacts/build_artifact_node.sh {} {}'.format(
self.gyp_arch, self.platform))
else: else:
return create_jobspec(self.name, return create_jobspec(self.name,
['tools/run_tests/artifacts/build_artifact_node.sh', ['tools/run_tests/artifacts/build_artifact_node.sh',
self.gyp_arch], self.gyp_arch, self.platform],
use_workspace=True) use_workspace=True)
class PHPArtifact: class PHPArtifact:
...@@ -343,7 +344,7 @@ class ProtocArtifact: ...@@ -343,7 +344,7 @@ class ProtocArtifact:
environ=environ, environ=environ,
use_workspace=True) use_workspace=True)
else: else:
generator = 'Visual Studio 12 Win64' if self.arch == 'x64' else 'Visual Studio 12' generator = 'Visual Studio 12 Win64' if self.arch == 'x64' else 'Visual Studio 12'
vcplatform = 'x64' if self.arch == 'x64' else 'Win32' vcplatform = 'x64' if self.arch == 'x64' else 'Win32'
return create_jobspec(self.name, return create_jobspec(self.name,
['tools\\run_tests\\artifacts\\build_artifact_protoc.bat'], ['tools\\run_tests\\artifacts\\build_artifact_protoc.bat'],
......
...@@ -29,6 +29,7 @@ ...@@ -29,6 +29,7 @@
# OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. # OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
NODE_TARGET_ARCH=$1 NODE_TARGET_ARCH=$1
NODE_TARGET_OS=$2
source ~/.nvm/nvm.sh source ~/.nvm/nvm.sh
nvm use 4 nvm use 4
...@@ -50,6 +51,12 @@ for version in ${node_versions[@]} ...@@ -50,6 +51,12 @@ for version in ${node_versions[@]}
do do
./node_modules/.bin/node-pre-gyp configure rebuild package --target=$version --target_arch=$NODE_TARGET_ARCH --grpc_alpine=true ./node_modules/.bin/node-pre-gyp configure rebuild package --target=$version --target_arch=$NODE_TARGET_ARCH --grpc_alpine=true
cp -r build/stage/* "${ARTIFACTS_OUT}"/ cp -r build/stage/* "${ARTIFACTS_OUT}"/
if [ "$NODE_TARGET_ARCH" == 'x64' ] && [ "$NODE_TARGET_OS" == 'linux' ]
then
# Cross compile for ARM on x64
CC=arm-linux-gnueabihf-gcc CXX=arm-linux-gnueabihf-g++ LD=arm-linux-gnueabihf-g++ ./node_modules/.bin/node-pre-gyp configure rebuild package testpackage --target=$version --target_arch=arm
cp -r build/stage/* "${ARTIFACTS_OUT}"/
fi
done done
for version in ${electron_versions[@]} for version in ${electron_versions[@]}
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment