From 2143f175969efa48b9cea1bfddc018bc1d98dd37 Mon Sep 17 00:00:00 2001 From: Dongdong Tian Date: Tue, 28 Apr 2020 01:49:25 -0400 Subject: [PATCH 1/4] CI: Add TravisCI support --- .travis.yml | 35 +++++++++++++++++++++++++++++++++++ 1 file changed, 35 insertions(+) create mode 100644 .travis.yml diff --git a/.travis.yml b/.travis.yml new file mode 100644 index 0000000..2607504 --- /dev/null +++ b/.travis.yml @@ -0,0 +1,35 @@ +# Configuration file for TravisCI + +language: c + +os: linux +dist: bionic + +# Only build pushes to the master branch and tags. This avoids the double +# builds than happen when working on a branch instead of a fork. +branches: + only: + - master + # Regex to build tagged commits with version numbers + - /\d+\.\d+(\.\d+)?(\S*)?$/ + +env: + global: + # GMT install location + - GMT_INSTALL_DIR=${HOME}/gmt-install-dir + +before_install: + # Install GMT master branch + - curl https://raw.githubusercontent.com/GenericMappingTools/gmt/build-script/ci/build-gmt-master.sh | bash + - export PATH=${GMT_INSTALL_DIR}/bin:${PATH} + - gmt --version + - gmt-config --all + +install: + - gmt --version + +script: + - gmt --version + +notifications: + email: false From 0f59be9e97571d24dc955878244226c0d63eba63 Mon Sep 17 00:00:00 2001 From: Dongdong Tian Date: Tue, 28 Apr 2020 01:56:25 -0400 Subject: [PATCH 2/4] Trigger a build --- .travis.yml | 2 ++ 1 file changed, 2 insertions(+) diff --git a/.travis.yml b/.travis.yml index 2607504..7241cb7 100644 --- a/.travis.yml +++ b/.travis.yml @@ -21,7 +21,9 @@ env: before_install: # Install GMT master branch - curl https://raw.githubusercontent.com/GenericMappingTools/gmt/build-script/ci/build-gmt-master.sh | bash + # Add GMT to PATH - export PATH=${GMT_INSTALL_DIR}/bin:${PATH} + # Check GMT installation - gmt --version - gmt-config --all From 0b41d63e357433b65b5d992a6eb2f8c978a4526f Mon Sep 17 00:00:00 2001 From: Dongdong Tian Date: Tue, 28 Apr 2020 02:00:58 -0400 Subject: [PATCH 3/4] Install GMT dependencies --- .travis.yml | 16 ++++++++++++++-- 1 file changed, 14 insertions(+), 2 deletions(-) diff --git a/.travis.yml b/.travis.yml index 7241cb7..5ddbeda 100644 --- a/.travis.yml +++ b/.travis.yml @@ -17,12 +17,24 @@ env: global: # GMT install location - GMT_INSTALL_DIR=${HOME}/gmt-install-dir + - PATH=${GMT_INSTALL_DIR}/bin:${PATH} + +addons: + apt: + packages: + - cmake + - build-essential + - libcurl4-gnutls-dev + - libnetcdf-dev + - libgdal-dev + - libfftw3-dev + - libpcre3-dev + - liblapack-dev + - curl before_install: # Install GMT master branch - curl https://raw.githubusercontent.com/GenericMappingTools/gmt/build-script/ci/build-gmt-master.sh | bash - # Add GMT to PATH - - export PATH=${GMT_INSTALL_DIR}/bin:${PATH} # Check GMT installation - gmt --version - gmt-config --all From 15cca99ad3a14687355750757a5196680dde481e Mon Sep 17 00:00:00 2001 From: Dongdong Tian Date: Tue, 28 Apr 2020 17:59:37 -0400 Subject: [PATCH 4/4] Get build script from master branch --- .travis.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.travis.yml b/.travis.yml index 5ddbeda..b98aeac 100644 --- a/.travis.yml +++ b/.travis.yml @@ -34,7 +34,7 @@ addons: before_install: # Install GMT master branch - - curl https://raw.githubusercontent.com/GenericMappingTools/gmt/build-script/ci/build-gmt-master.sh | bash + - curl https://raw.githubusercontent.com/GenericMappingTools/gmt/master/ci/build-gmt-master.sh | bash # Check GMT installation - gmt --version - gmt-config --all