1
0
mirror of https://github.com/SmartHoneybee/ubiquitous-memory synced 2025-10-24 23:33:48 +02:00

Compare commits

...

29 Commits

Author SHA1 Message Date
Bee
205431da5a Update .travis.yml (#34) 2018-09-19 09:51:35 +00:00
Bee
62ff5c6c21 Update .travis.yml (#33) 2018-09-14 15:47:08 +00:00
Bee
c602d86ba3 Update .travis.yml (#32) 2018-08-17 19:18:58 +02:00
Bee
f95c324df8 Update .travis.yml (#31) 2018-07-14 17:34:07 +02:00
Bee
27211d5341 Update .travis.yml (#30) 2018-07-11 09:19:47 +02:00
Bee
04a80b8c61 Update .travis.yml (#29) 2018-06-15 19:41:25 +02:00
Bee
cce9a5e9f6 Update .travis.yml (#28) 2018-06-02 17:36:34 +02:00
Bee
4338daa488 Update .travis.yml (#27) 2018-05-16 07:41:25 +02:00
Bee
adfadb5db1 Update .travis.yml (#26) 2018-05-03 23:51:58 +02:00
Bee
9ec2d52a6f Update .travis.yml (#25) 2018-04-27 08:30:19 +02:00
Bee
73a0247466 Update .travis.yml (#24) 2018-04-15 11:28:06 +02:00
Bee
8e48ad9fd6 Update .travis.yml (#23) 2018-03-16 07:59:56 +01:00
Bee
9fbbcc9efa Update .travis.yml (#22) 2018-02-23 11:03:29 +01:00
Bee
a841d22ea1 Update .travis.yml (#21) 2018-02-19 17:50:02 +01:00
Bee
53a8823dd3 Update .travis.yml (#20) 2018-02-16 10:59:36 +01:00
Bee
2b81bf9c79 Update .travis.yml (#19) 2018-02-15 17:43:40 +01:00
Bee
656fcc3022 Update .travis.yml (#18) 2018-01-31 17:31:40 +01:00
Bee
64b4df143a Update .travis.yml (#17) 2018-01-16 08:24:29 +01:00
Bee
6245638306 Update .travis.yml (#16) 2018-01-13 18:30:06 +01:00
Bee
f00ec524e3 Update .travis.yml (#15) 2017-12-16 10:35:14 +01:00
Bee
5a5da5e379 Update .travis.yml (#13) 2017-12-08 11:03:52 +01:00
Bee
f041990920 Update .travis.yml (#14) 2017-12-08 10:49:08 +01:00
Bee
c5d346a10a Update .travis.yml (#11) 2017-12-06 11:23:06 +01:00
Bee
a46b0240e4 Update .travis.yml (#12) 2017-12-06 11:11:25 +01:00
Bee
767566cb74 Update .travis.yml (#10) 2017-12-05 12:52:42 +01:00
Bee
cdb30c1b6a Update .travis.yml (#9) 2017-11-23 15:07:10 +01:00
Bee
762155e2bd Update make.patch (#8) 2017-11-17 12:48:04 +01:00
Bee
2f54ffd998 Update .travis.yml (#7) 2017-11-16 09:01:56 +01:00
Bee
ea4cbc8cc7 Update .travis.yml (#6) 2017-11-11 20:29:29 +01:00
4 changed files with 85 additions and 97 deletions

View File

@@ -1,55 +1,64 @@
language: c
dist: trusty
sudo: required
addons:
apt:
sources:
- sourceline: 'deb https://dl.yarnpkg.com/debian/ stable main'
key_url: 'https://dl.yarnpkg.com/debian/pubkey.gpg'
- sourceline: 'deb https://deb.nodesource.com/node_8.x trusty main'
- sourceline: 'deb https://deb.nodesource.com/node_10.x trusty main'
key_url: 'https://deb.nodesource.com/gpgkey/nodesource.gpg.key'
# libpng16-16
- sourceline: 'deb-src http://archive.ubuntu.com/ubuntu xenial universe'
- sourceline: 'deb-src http://archive.ubuntu.com/ubuntu xenial-updates universe'
- sourceline: 'deb-src http://security.ubuntu.com/ubuntu xenial-security universe'
packages:
- nodejs
- yarn
- build-essential
- fakeroot
env:
global:
- GOV=1.9
- GOPATH=$HOME/go
- GOROOT=$HOME/$GOV/go
- PATH=$GOROOT/bin:$PATH:$GOPATH/bin
- GOV=1.11
- GOSHA="b3fcf280ff86558e0559e185b601c9eade0fd24c900b4c63cd14d1d38613e499 go${GOV}.linux-amd64.tar.gz"
- GOPATH="${HOME}/go"
- GOROOT="${HOME}/${GOV}/go"
- PATH="${GOROOT}/bin:${PATH}:${GOPATH}/bin"
- SRCROOT="${GOPATH}/src/github.com/mattermost"
- GOARM=7
matrix:
- V=4.3.0
- V=4.3.1
- V=5.3.1
before_install:
- install -d $GOPATH $GOROOT
- wget https://storage.googleapis.com/golang/go$GOV.linux-amd64.tar.gz
- tar -C $HOME/$GOV -xzf go$GOV.linux-amd64.tar.gz
- node --version
- yarn versions
- go version
- ulimit -n 8096
- install -d ~/go/src/github.com/mattermost
- cd ~/go/src/github.com/mattermost
- wget "https://github.com/mattermost/mattermost-server/archive/v${V}.tar.gz"
- tar xf "v${V}.tar.gz"
- mv "mattermost-server-${V}" mattermost-server
- rm "v${V}.tar.gz"
- wget "https://github.com/mattermost/mattermost-webapp/archive/v${V}.tar.gz"
- tar xf "v${V}.tar.gz"
- mv "mattermost-webapp-${V}" mattermost-webapp
- rm "v${V}.tar.gz"
- install -d "${GOPATH}/bin" "${GOROOT}" "${SRCROOT}/mattermost-"{server,webapp}
# download & extract golang
- wget -q "https://storage.googleapis.com/golang/go${GOV}.linux-amd64.tar.gz"
- sha256sum --check <<< "${GOSHA}"
- tar -C "${HOME}/${GOV}" -xzf "go${GOV}.linux-amd64.tar.gz"
# download & extract mattermost-server
- wget -q "https://github.com/mattermost/mattermost-server/archive/v${V}.tar.gz" -O mattermost-server.tar.gz
- tar -C "${SRCROOT}/mattermost-server" --strip-components=1 -xf mattermost-server.tar.gz
# download & extract mattermost-webapp
- wget -q "https://github.com/mattermost/mattermost-webapp/archive/v${V}.tar.gz" -O mattermost-webapp.tar.gz
- tar -C "${SRCROOT}/mattermost-webapp" --strip-components=1 -xf mattermost-webapp.tar.gz
# (trusty is old:) backport and install libpng16-16
- sudo -E apt-get build-dep -yq libpng16-16
- apt-get --build source libpng16-16
- sudo -E dpkg -i ./libpng16-16_*.deb
script:
- make build -C ~/go/src/github.com/mattermost/mattermost-webapp
- cd ~/go/src/github.com/mattermost/mattermost-server
- patch -p1 < $TRAVIS_BUILD_DIR/make.patch
- go get -d ./...
- make build-linux package BUILD_NUMBER="dev-arm-tag${V}"
- mv -v ~/go/src/github.com/mattermost/mattermost-server/dist/mattermost-*-linux-arm.tar.gz $TRAVIS_BUILD_DIR/mattermost-$V-arm.tar.gz
- sha512sum $TRAVIS_BUILD_DIR/mattermost-$V-arm.tar.gz | tee $TRAVIS_BUILD_DIR/mattermost-$V-arm.tar.gz.sha512sum
- make build -C "${SRCROOT}/mattermost-webapp"
# workaround (instead of patch): platform binary is in GOOS_GOARCH, Makefile expects it in linux_amd64
- ln -s "${GOPATH}/bin/linux_arm" "${GOPATH}/bin/linux_amd64"
# adapt and revert reverted commit, https://github.com/mattermost/mattermost-server/pull/8537
- patch -d "${SRCROOT}/mattermost-server" -p1 < "${TRAVIS_BUILD_DIR}/build-release.patch"
# workaround (instead of patch): overwrite GO variable to enforce desired GOARCH
- make config-reset build-linux package-linux -C "${SRCROOT}/mattermost-server" PLUGIN_PACKAGES="" GO="GOARCH=arm $(which go)" BUILD_NUMBER="dev-arm-tag${V}"
# workaround (instead of patch): Makefile creates *-amd64.tar.gz
- mv "${SRCROOT}/mattermost-server/dist/mattermost-team-linux-amd64.tar.gz" "${TRAVIS_BUILD_DIR}/mattermost-${V}-arm.tar.gz"
- sha512sum "${TRAVIS_BUILD_DIR}/mattermost-${V}-arm.tar.gz" | tee "${TRAVIS_BUILD_DIR}/mattermost-${V}-arm.tar.gz.sha512sum"
deploy:
provider: releases
api_key: "${GITHUB_OAUTH_TOKEN}"
file:
- "$TRAVIS_BUILD_DIR/mattermost-$V-arm.tar.gz"
- "$TRAVIS_BUILD_DIR/mattermost-$V-arm.tar.gz.sha512sum"
- "${TRAVIS_BUILD_DIR}/mattermost-${V}-arm.tar.gz"
- "${TRAVIS_BUILD_DIR}/mattermost-${V}-arm.tar.gz.sha512sum"
skip_cleanup: true

View File

@@ -1 +1,10 @@
# ubiquitous-memory
# ubiquitous-memory: [Here be dragons][3]
[![Build Status](https://travis-ci.org/SmartHoneybee/ubiquitous-memory.svg?branch=master)](https://travis-ci.org/SmartHoneybee/ubiquitous-memory)
[Travis CI][0] recipe that builds [Mattermost][1] for Linux on [ARMv7][2]-compatible devices.
[0]: https://travis-ci.org/SmartHoneybee/ubiquitous-memory
[1]: https://mattermost.com/
[2]: https://github.com/golang/go/wiki/GoArm#supported-architectures
[3]: https://en.wikipedia.org/wiki/Here_be_dragons

33
build-release.patch Normal file
View File

@@ -0,0 +1,33 @@
From 556e16211ed1b4c146ca2a094688618458182ae7 Mon Sep 17 00:00:00 2001
From: Your Name <you@example.com>
Date: Wed, 6 Jun 2018 12:34:56 +0100
Subject: [PATCH] Split make goal
---
build/release.mk | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/build/release.mk b/build/release.mk
index 238343e..1b7859f 100644
--- a/build/release.mk
+++ b/build/release.mk
@@ -61,7 +61,7 @@ endif
cp README.md $(DIST_PATH)
@# ----- PLATFORM SPECIFIC -----
-
+_:
@# Make osx package
@# Copy binary
ifeq ($(BUILDER_GOOS_GOARCH),"darwin_amd64")
@@ -106,7 +106,7 @@ endif
rm -f $(DIST_PATH)/bin/mattermost.exe
rm -f $(DIST_PATH)/bin/platform.exe
rm -f $(DIST_PATH)/prepackaged_plugins/*
-
+package-linux: package
@# Make linux package
@# Copy binary
ifeq ($(BUILDER_GOOS_GOARCH),"linux_amd64")
--
2.11.0

View File

@@ -1,63 +0,0 @@
diff --git a/build/release.mk b/build/release.mk
index 5eaee80..e0e13bf 100644
--- a/build/release.mk
+++ b/build/release.mk
@@ -3,7 +3,7 @@ dist: | check-style test package
build-linux:
@echo Build Linux amd64
- env GOOS=linux GOARCH=amd64 $(GO) install $(GOFLAGS) $(GO_LINKER_FLAGS) ./cmd/platform
+ env GOOS=linux GOARCH=arm $(GO) install $(GOFLAGS) $(GO_LINKER_FLAGS) ./cmd/platform
build-osx:
@echo Build OSX amd64
@@ -32,6 +32,7 @@ package:
@# Resource directories
cp -RL config $(DIST_PATH)
+ mv $(DIST_PATH)/config/default.json $(DIST_PATH)/config/config.json
cp -RL fonts $(DIST_PATH)
cp -RL templates $(DIST_PATH)
cp -RL i18n $(DIST_PATH)
@@ -61,38 +62,14 @@ endif
@# ----- PLATFORM SPECIFIC -----
- @# Make osx package
- @# Copy binary
-ifeq ($(BUILDER_GOOS_GOARCH),"darwin_amd64")
- cp $(GOPATH)/bin/platform $(DIST_PATH)/bin # from native bin dir, not cross-compiled
-else
- cp $(GOPATH)/bin/darwin_amd64/platform $(DIST_PATH)/bin # from cross-compiled bin dir
-endif
- @# Package
- tar -C dist -czf $(DIST_PATH)-$(BUILD_TYPE_NAME)-osx-amd64.tar.gz mattermost
- @# Cleanup
- rm -f $(DIST_PATH)/bin/platform
-
- @# Make windows package
- @# Copy binary
-ifeq ($(BUILDER_GOOS_GOARCH),"windows_amd64")
- cp $(GOPATH)/bin/platform.exe $(DIST_PATH)/bin # from native bin dir, not cross-compiled
-else
- cp $(GOPATH)/bin/windows_amd64/platform.exe $(DIST_PATH)/bin # from cross-compiled bin dir
-endif
- @# Package
- cd $(DIST_ROOT) && zip -9 -r -q -l mattermost-$(BUILD_TYPE_NAME)-windows-amd64.zip mattermost && cd ..
- @# Cleanup
- rm -f $(DIST_PATH)/bin/platform.exe
-
@# Make linux package
@# Copy binary
-ifeq ($(BUILDER_GOOS_GOARCH),"linux_amd64")
+ifeq ($(BUILDER_GOOS_GOARCH),"linux_arm")
cp $(GOPATH)/bin/platform $(DIST_PATH)/bin # from native bin dir, not cross-compiled
else
- cp $(GOPATH)/bin/linux_amd64/platform $(DIST_PATH)/bin # from cross-compiled bin dir
+ cp $(GOPATH)/bin/linux_arm/platform $(DIST_PATH)/bin # from cross-compiled bin dir
endif
@# Package
- tar -C dist -czf $(DIST_PATH)-$(BUILD_TYPE_NAME)-linux-amd64.tar.gz mattermost
+ tar -C dist -czf $(DIST_PATH)-$(BUILD_TYPE_NAME)-linux-arm.tar.gz mattermost
@# Don't clean up native package so dev machines will have an unzipped package available
@#rm -f $(DIST_PATH)/bin/platform