Skip to content

Commit

Permalink
Version 1.0.10
Browse files Browse the repository at this point in the history
  • Loading branch information
rgleason authored and mauroc committed Oct 4, 2019
1 parent 74b7ffc commit 6ad47a3
Show file tree
Hide file tree
Showing 26 changed files with 661 additions and 6 deletions.
82 changes: 82 additions & 0 deletions .circleci/config.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,82 @@
---
version: 2
jobs:
build-debian:
docker:
- image: circleci/buildpack-deps:xenial-scm
environment:
- OCPN_TARGET: xenial
steps:
- checkout
- run: >
echo "deb-src http://us.archive.ubuntu.com/ubuntu/ xenial main"
| sudo tee -a /etc/apt/sources.list
- run: >
echo "deb-src http://us.archive.ubuntu.com/ubuntu/ xenial-updates main"
| sudo tee -a /etc/apt/sources.list
- run: cat /etc/apt/sources.list
- run: ci/circleci-build-debian.sh
- run: ci/circleci-upload.sh
build-flatpak:
machine:
image: circleci/classic:201808-01
environment:
- OCPN_TARGET: flatpak
steps:
- checkout
- run: ci/circleci-build-flatpak.sh
- run: ci/circleci-upload.sh
build-fedora:
docker:
- image: fedora:29
environment:
- OCPN_TARGET: fedora
steps:
- run: su -c "dnf install -q -y git openssh-clients openssh-server"
- checkout
- run: ci/circleci-build-fedora.sh
- run: ci/circleci-upload.sh
build-mingw:
docker:
- image: fedora:29
environment:
- OCPN_TARGET: mingw
steps:
- run: su -c "dnf install -q -y git openssh-clients openssh-server"
- checkout
- run: ci/circleci-build-mingw.sh
- run: ci/circleci-upload.sh
# build-macos:
# macos:
# xcode: "10.0.0"
# environment:
# - OCPN_TARGET: macos
# steps:
# - checkout
# - run: ci/circleci-build-macos.sh
# - run: ci/circleci-upload.sh

workflows:
version: 2
build_all:
jobs:
- build-debian:
filters:
branches:
only: master
- build-flatpak:
filters:
branches:
only: master
- build-fedora:
filters:
branches:
only: master
# - build-macos:
# filters:
# branches:
# only: master
- build-mingw:
filters:
branches:
only: master
4 changes: 2 additions & 2 deletions .travis.yml
Original file line number Diff line number Diff line change
Expand Up @@ -47,12 +47,12 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J9TEsgZ6MIqC2X9bwKtQcW/cmSeJmmpUVhaIZ7KjYS3cIxlQ+jU0aIZupsf0P73rovTfNWuC919H9Ggu/Mc3rELwBUZ1FctxDFZ13cM1gnpbAZXA0xZGGK0AV3Y9M1BQ/RBcnez2OT7DAwYofYe2VAnvMJbYkJUKVVMsKZqPF+9fXGYhtVTpKw3j89nE98xRkIKiWQBmUE6x5XPSgxsI1CaDBIuZiXDO/IMh2v3HGiFlOC8qAuV6Z1vdHbaIFtzPkVEZ1miMBbD3XPki3Crl4kVXtGrCPAl6uH3YVrats9CL6shfgwzsS52zBacQxQu7RCrT6U="
file_glob: true
file: "$TRAVIS_BUILD_DIR/build/*.{deb,rpm,dmg,txz,pkg,pkg.tar.xz}"
skip_cleanup: true
on:
repo: rgleason/squiddio_pi
repo: mauroc/squiddio_pi
tags: true
all_branches: true

4 changes: 2 additions & 2 deletions CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -33,8 +33,8 @@ SET(CPACK_PACKAGE_CONTACT "Mauro Calvi")

SET(VERSION_MAJOR "1")
SET(VERSION_MINOR "0")
SET(VERSION_PATCH "9")
SET(PLUGIN_VERSION_DATE "2019/09/23")
SET(VERSION_PATCH "10")
SET(PLUGIN_VERSION_DATE "2019/09/26")
SET(OCPN_MIN_VERSION "ov50")

#SET(CMAKE_BUILD_TYPE Debug)
Expand Down
4 changes: 2 additions & 2 deletions appveyor.yml
Original file line number Diff line number Diff line change
Expand Up @@ -53,11 +53,11 @@ deploy:

provider: GitHub
auth_token:
secure: VYYxNSdoxzJai29K/HmfO+VHsJ2QDvkYk2oa2pb4WrIRad+8/HANZ0lCn3GbgfHd
secure: 4l9NTrQyvKVqzBPAT3ejCSZhllJXWaI/QcFWTBHueU3YEqLRAZM3+LinoOBnMcf2
artifact: installer,portable
draft: true
prerelease: true
tag: $(APPVEYOR_REPO_TAG_NAME) # insert version name
# tag: $(APPVEYOR_REPO_TAG_NAME) # insert version name
on:
configuration: Release # Debug contains non-redist MS DLLs
APPVEYOR_REPO_TAG: true # deploy on tag push only
Expand Down
28 changes: 28 additions & 0 deletions ci/appveyor-upload.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,28 @@
#!/usr/bin/env bash

#
# Upload the .tar.gz and .xml artifacts to cloudsmith
#

set -xe

REPO='alec-leamas/opencpn-plugins-unstable'

if [ -z "$CLOUDSMITH_API_KEY" ]; then
echo 'Cannot deploy to cloudsmith, missing $CLOUDSMITH_API_KEY'
exit 0
fi

python -m ensurepip
python -m pip install -q setuptools
python -m pip install -q cloudsmith-cli

commit=$(git rev-parse --short=7 HEAD) || commit="unknown"
now=$(date --rfc-3339=seconds) || now=$(date)

tarball=$(ls *.tar.gz)
xml=$(ls *.xml)
echo '<!--'" Date: $now Commit: $commit Build nr: $BUILD_ID -->" >> $xml

cloudsmith push raw --republish --no-wait-for-sync $REPO $tarball
cloudsmith push raw --republish --no-wait-for-sync $REPO $xml
58 changes: 58 additions & 0 deletions ci/bintray.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,58 @@
{
"package": {
"name": "plugins",
"repo": "OpenCPN",
"subject": "leamas",
"desc": "oesenc plugin automatic push",
"website_url": "www.jfrog.com",
"issue_tracker_url": "https://github.com/leamas/oesenc_pi/issues",
"vcs_url": "https://github.com/leamas/oesenc_pi.git",
"github_use_tag_release_notes": false,
"licenses": ["GPL2"],
"labels": [],
"public_download_numbers": false,
"public_stats": false,
"attributes": [{
"name": "att5",
"values" : ["2014-12-28T19:43:37+0100"],
"type": "date"
}]
},

"version": {
"name": "1.15-0.beta2",
"desc": "Pre-release based on 5.0.0 beta2",
"released": "2019-03-14",
"vcs_tag": "1.15",
"attributes": [
{"name": "VerAtt1", "values" : ["VerVal1"], "type": "string"},
{"name": "VerAtt2", "values" : [1, 3.3, 5], "type": "number"},
{
"name": "VerAtt3",
"values" : ["2015-01-01T19:43:37+0100"],
"type": "date"
}
],
"gpgSign": false
},

"files":
[
{
"includePattern": "build/(oesenc.*\\.tar.gz)",
"uploadPattern": "$1",
"matrixParams": {"override": 1}
},
{
"includePattern": "build/(oesenc-plugin\\.xml)",
"uploadPattern": "$1",
"matrixParams": {"override": 1}
},
{
"includePattern": "build/(oesenc-plugin-.*\\.xml)",
"uploadPattern": "$1",
"matrixParams": {"override": 1}
}
],
"publish": true
}
21 changes: 21 additions & 0 deletions ci/circleci-build-debian.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,21 @@
#!/usr/bin/env bash

#
# Build the Debian artifacts
#
set -xe
sudo apt-get -qq update
sudo apt-get install devscripts equivs

pwd
ls -R

mkdir build
cd build
mk-build-deps ../ci/control
sudo apt-get install ./*all.deb || :
sudo apt-get --allow-unauthenticated install -f

cmake -DCMAKE_BUILD_TYPE=Debug ..
make -sj2
make package
13 changes: 13 additions & 0 deletions ci/circleci-build-fedora.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
#!/bin/sh -xe

#
# Build the mingw artifacts inside the Fedora container
#
set -xe

su -c "dnf install -y sudo dnf-plugins-core"
sudo dnf builddep -y ci/opencpn-fedora.spec
rm -rf build; mkdir build; cd build
cmake ..
make -j2
make package
46 changes: 46 additions & 0 deletions ci/circleci-build-flatpak.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,46 @@
#!/usr/bin/env bash

#
# Build the flatpak artifacts. Uses docker to run Fedora on
# in fuill-fledged VM; the actual build is done in the Fedora
# container.
#
# flatpak-builder can be run in a docker image. However, this
# must then be run in privileged mode, which means it we need
# a full-fledged VM to run it.
#

# bailout on errors and echo commands.
set -xe
##sudo apt-get -qq update

PLUGIN=bsb4

DOCKER_SOCK="unix:///var/run/docker.sock"
if [ -n "$TRAVIS" ]; then
TOPDIR=/opencpn-ci
fi

if [ -n "$CIRCLECI" ]; then
TOPDIR=/root/project
fi

echo "DOCKER_OPTS=\"-H tcp://127.0.0.1:2375 -H $DOCKER_SOCK -s devicemapper\"" \
| sudo tee /etc/default/docker > /dev/null
sudo service docker restart
sleep 5
sudo docker pull fedora:28;
sleep 2
docker run --privileged -d -ti -e "container=docker" \
-e "TOPDIR=$TOPDIR" \
-v /sys/fs/cgroup:/sys/fs/cgroup \
-v $(pwd):$TOPDIR:rw \
fedora:28 /usr/sbin/init
DOCKER_CONTAINER_ID=$(docker ps | grep fedora | awk '{print $1}')
docker logs $DOCKER_CONTAINER_ID
docker exec -ti $DOCKER_CONTAINER_ID /bin/bash -xec \
"bash -xe $TOPDIR/ci/docker-build-flatpak.sh 28;
echo -ne \"------\nEND OPENCPN-CI BUILD\n\";"
docker ps -a
docker stop $DOCKER_CONTAINER_ID
docker rm -v $DOCKER_CONTAINER_ID
28 changes: 28 additions & 0 deletions ci/circleci-build-macos.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,28 @@
#!/usr/bin/env bash

#
# Build the Travis OSX artifacts
#

# bailout on errors and echo commands
set -xe

for pkg in cairo libexif xz libarchive python3 wget cmake; do
brew list $pkg 2>&1 >/dev/null || brew install $pkg
done

wget http://opencpn.navnux.org/build_deps/wx312_opencpn50_macos109.tar.xz
tar xJf wx312_opencpn50_macos109.tar.xz -C /tmp
export PATH="/usr/local/opt/gettext/bin:$PATH"
echo 'export PATH="/usr/local/opt/gettext/bin:$PATH"' >> ~/.bash_profile

rm -rf build && mkdir build && cd build
test -z "$TRAVIS_TAG" && CI_BUILD=OFF || CI_BUILD=ON
cmake -DOCPN_CI_BUILD=$CI_BUILD \
-DOCPN_USE_LIBCPP=ON \
-DwxWidgets_CONFIG_EXECUTABLE=/tmp/wx312_opencpn50_macos109/bin/wx-config \
-DwxWidgets_CONFIG_OPTIONS="--prefix=/tmp/wx312_opencpn50_macos109" \
-DCMAKE_INSTALL_PREFIX=/tmp/opencpn -DCMAKE_OSX_DEPLOYMENT_TARGET=10.9 \
..
make -sj2
make package
17 changes: 17 additions & 0 deletions ci/circleci-build-mingw.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,17 @@
#!/bin/sh -xe

#
# Build the mingw artifacts inside the Fedora container
#
set -xe

su -c "dnf install -q -y sudo dnf-plugins-core"
sudo dnf -q builddep -y mingw/fedora/opencpn-deps.spec
rm -rf build; mkdir build; cd build
cmake -DCMAKE_TOOLCHAIN_FILE=../mingw/fedora/toolchain.cmake ..
make -j2
make package

if [ -z "$CLOUDSMITH_API_KEY" ]; then
exit 0
fi
46 changes: 46 additions & 0 deletions ci/circleci-upload.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,46 @@
#!/usr/bin/env bash

#
# Upload the .tar.gz and .xml artifacts.
#

set -xe

REPO='mauro-calvi/squiddio_pi'

if [ -z "$CIRCLECI" ]; then
exit 0;
fi

if [ -z "$CLOUDSMITH_API_KEY" ]; then
echo 'Cannot deploy to cloudsmith, missing $CLOUDSMITH_API_KEY'
exit 0
fi

if pyenv versions 2>&1 >/dev/null; then
pyenv global 3.7.0
python -m pip install cloudsmith-cli
pyenv rehash
elif dnf --version 2>&1 >/dev/null; then
sudo dnf install python3-pip python3-setuptools
sudo python3 -m pip install -q cloudsmith-cli
elif apt-get --version 2>&1 >/dev/null; then
sudo apt-get install python3-pip python3-setuptools
sudo python3 -m pip install -q cloudsmith-cli
else
sudo -H python3 -m ensurepip
sudo -H python3 -m pip install -q setuptools
sudo -H python3 -m pip install -q cloudsmith-cli
fi

BUILD_ID=${CIRCLE_BUILD_NUM:-1}
commit=$(git rev-parse --short=7 HEAD) || commit="unknown"
now=$(date --rfc-3339=seconds) || now=$(date)

tarball=$(ls $HOME/project/build/*.tar.gz)
xml=$(ls $HOME/project/build/*.xml)
sudo chmod 666 $xml
echo '<!--'" Date: $now Commit: $commit Build nr: $BUILD_ID -->" >> $xml

cloudsmith push raw --republish --no-wait-for-sync $REPO $tarball
cloudsmith push raw --republish --no-wait-for-sync $REPO $xml
Empty file modified ci/control.trusty
100644 → 100755
Empty file.
Empty file modified ci/control.xenial
100644 → 100755
Empty file.
Loading

0 comments on commit 6ad47a3

Please sign in to comment.