memgraph/release/arch-pkg/PKGBUILD.proto
Marko Budiselić 291158160d Put all logrotate config to a file per offering (#23)
Not having one logrotate file produced an error during rpmlint.  It makes sense
to have one logrotate file after Memgraph is installed because it's easier to
manage config files. There are two logrotate files in the codebase, one for
Community and one for Enterprise edition. Having rotate files per offering also
makes sense because offerings are affected less often compared to the features.
It's easier to maintain.
2020-10-17 20:10:55 +02:00

48 lines
1.3 KiB
Protocol Buffer

# Maintainer: tech@memgraph.com (Memgraph Ltd.)
pkgname=memgraph
pkgrel=1
epoch=
# TODO: Maybe take pkgdesc from CMake?
pkgdesc="High performance, in-memory, transactional graph database"
# TODO: Autogenerate architecture? Though, we only support x86_64...
arch=('x86_64')
url="https://memgraph.com"
license=('custom')
groups=()
depends=('gcc-libs')
makedepends=()
checkdepends=()
optdepends=()
provides=()
conflicts=()
replaces=()
backup=("etc/memgraph/memgraph.conf" "etc/logrotate.d/memgraph")
options=()
install=memgraph.install
changelog=
source=("$pkgname-$pkgver.tar.gz")
noextract=()
validpgpkeys=()
package() {
cd $(find . -maxdepth 1 -type d -name 'memgraph*')
# By default, we install the systemd service in /lib (as expected on Debian),
# so move anything like that in /usr/lib.
if [[ -d "lib" ]]; then
mkdir -p usr/lib
cp -a lib/* usr/lib
rm -rf lib
fi
# In case the binary package is built with /usr/local prefix instead of /usr.
if [[ -d "usr/local" ]]; then
mkdir -p usr
cp -a usr/local/* usr
rm -rf usr/local
fi
# Move the license to Arch specific location.
install -Dm644 usr/share/doc/memgraph/copyright usr/share/licenses/memgraph/LICENSE
# We currently don't have anything in usr/share/doc/memgraph
rm -rf usr/share/doc/memgraph
cp -a . $pkgdir
}