File camlistore.spec of Package camlistore

#
# spec file for package camlistore
#
# Copyright (c) 2016 SUSE LINUX GmbH, Nuernberg, Germany.
#
# All modifications and additions to the file contributed by third parties
# remain the property of their copyright owners, unless otherwise agreed
# upon. The license for this file, and modifications and additions to the
# file, is the same license as for the pristine package itself (unless the
# license for the pristine package is not an Open Source License, in which
# case the license is the MIT License). An "Open Source License" is a
# license that conforms to the Open Source Definition (Version 1.9)
# published by the Open Source Initiative.

# Please submit bugfixes or comments via http://bugs.opensuse.org/
#
# nodebuginfo

Name:           camlistore
Version:        0.9
Release:        0
Summary:        Personal storage system for life
License:        Apache-2.0
Group:          Productivity/Archiving/Backup
Url:            https://camlistore.org/
Source:         https://github.com/camlistore/camlistore/archive/%{version}.tar.gz#/%{name}-%{version}.tar.gz
BuildRequires:  go >= 1.5
ExclusiveArch:  %{ix86} x86_64 aarch64 ppc64 ppc64le

%description
Camlistore is a set of open source formats, protocols, and software for
modeling, storing, searching, sharing and synchronizing data in the post-PC
era. Data may be files or objects, tweets or 5TB videos, and you can access it
via a phone, browser or FUSE filesystem.

%package daemon
Summary:        Camlistore daemon

%description daemon
The Camlistore daemon which actually orchestrates the storage, access and
indexing of your blobs.

%package utils
Summary:        Camlistore utilities

%description utils
The set of example utilities provided by Camlistore to allow a client to push,
pull and otherwise interact with their blobs stored in a remote Camlistore
server.

%prep
%setup -q

%build
# Create builddir.
export GOPATH=$PWD/vendor
ln -sfv . $PWD/vendor/src
mkdir -pv $GOPATH/src/camlistore/
ln -svfn $PWD $GOPATH/src/camlistore/camlistore

# make.go will try to parse .git unless we hardcode the version.
echo "%{version}" > $PWD/VERSION

# Build binaries.
make %{?_smp_mflags}

%install
# Administraton utilities.
install -D -m 0755 $PWD/bin/camlistored %{buildroot}/%{_bindir}/camlistored
#install -D -m 0755 $PWD/bin/camdeploy %{buildroot}/%{_sbindir}/camdeploy

# Client tools.
install -D -m 0755 $PWD/bin/camget %{buildroot}/%{_bindir}/camget
install -D -m 0755 $PWD/bin/camput %{buildroot}/%{_bindir}/camput
install -D -m 0755 $PWD/bin/camtool %{buildroot}/%{_bindir}/camtool
install -D -m 0755 $PWD/bin/cammount %{buildroot}/%{_bindir}/cammount

%files daemon
%defattr(-,root,root)
%doc doc/
%doc README COPYING AUTHORS CONTRIBUTORS
%{_bindir}/camlistored

%files utils
%defattr(-,root,root,-)
%doc doc/
%doc README COPYING AUTHORS CONTRIBUTORS
%{_bindir}/camget
%{_bindir}/camput
%{_bindir}/camtool
%{_bindir}/cammount

%changelog
openSUSE Build Service is sponsored by