update.sh 1.4 KB
Newer Older
Ben Boeckel's avatar
Ben Boeckel committed
1 2 3 4 5 6 7 8 9 10
#!/usr/bin/env bash

set -e
set -x
shopt -s dotglob

readonly name="protobuf"
readonly ownership="protobuf Upstream <kwrobot@kitware.com>"
readonly subtree="ThirdParty/$name/vtk$name"
readonly repo="https://gitlab.kitware.com/third-party/protobuf.git"
Utkarsh Ayachit's avatar
Utkarsh Ayachit committed
11
readonly tag="for/paraview-20190606-3.8.0"
Ben Boeckel's avatar
Ben Boeckel committed
12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49

readonly paths="
CMakeLists.txt
LICENSE
README.kitware.md
README.md
.gitattributes

cmake/protobuf-function.cmake
src/CMakeLists.txt
src/google/protobuf/
"

extract_source () {
    git_archive
    pushd "$extractdir/$name-reduced"
    rm -rvf src/google/protobuf/compiler/csharp
    rm -rvf src/google/protobuf/compiler/java
    rm -rvf src/google/protobuf/compiler/javanano
    rm -rvf src/google/protobuf/compiler/js
    rm -rvf src/google/protobuf/compiler/objectivec
    rm -rvf src/google/protobuf/compiler/php
    rm -rvf src/google/protobuf/compiler/python
    rm -rvf src/google/protobuf/compiler/ruby
    rm -rvf src/google/protobuf/testdata/
    rm -rvf src/google/protobuf/testing/
    rm -rvf src/google/protobuf/util/internal/testdata/
    rm -rvf src/google/protobuf/unittest.proto
    rm -rvf src/google/protobuf/mock_code_generator.cc
    find -name "*.sh" -exec rm -v '{}' \;
    find -name "*_test.*" -exec rm -v '{}' \;
    find -name "*_unittest.*" -exec rm -v '{}' \;
    find -name "*test_*" -exec rm -v '{}' \;
    find -name "*unittest_*" -exec rm -v '{}' \;
    popd
}

. "${BASH_SOURCE%/*}/../update-common.sh"