[packages/usql] new
atler
atler at pld-linux.org
Thu Mar 4 17:33:56 CET 2021
commit 6c67d6c8bedff145e6bb5a80c699e030a27ff48c
Author: Jan Palus <atler at pld-linux.org>
Date: Thu Mar 4 17:32:30 2021 +0100
new
usql.spec | 51 +++++++++++++++++++++++++++++++++++++++++++++++++++
1 file changed, 51 insertions(+)
---
diff --git a/usql.spec b/usql.spec
new file mode 100644
index 0000000..55da81b
--- /dev/null
+++ b/usql.spec
@@ -0,0 +1,51 @@
+Summary: Universal command-line interface for SQL databases
+Name: usql
+Version: 0.8.1
+Release: 1
+License: MIT
+Group: Applications/Databases
+#Source0Download: https://github.com/xo/usql/releases
+Source0: https://github.com/xo/usql/archive/v%{version}/%{name}-%{version}.tar.gz
+# Source0-md5: 74b9b417310d4ef66d8097a36e18204f
+# cd usql-%{version}
+# go mod vendor
+# cd ..
+# tar cJf usql-vendor-%{version}.tar.xz usql-%{version}/vendor
+Source1: %{name}-vendor-%{version}.tar.xz
+# Source1-md5: 6b0529e711cd2095e2fecea9f6d214d0
+URL: https://github.com/xo/usql
+BuildRequires: golang >= 1.14
+BuildRequires: tar >= 1:1.22
+BuildRequires: xz
+ExclusiveArch: %{ix86} %{x8664} %{arm} aarch64 mips64 mips64le ppc64 ppc64le s390x
+BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
+
+%define tags most oracle sqlite_app_armor sqlite_fts5 sqlite_introspect sqlite_json1 sqlite_stat4 sqlite_userauth sqlite_vtable sqlite_icu no_adodb no_h2
+
+%description
+A universal command-line interface for PostgreSQL, MySQL, Oracle
+Database, SQLite3, Microsoft SQL Server, and many other databases
+including NoSQL and non-relational databases!
+
+%prep
+%setup -q -b1
+
+%{__mkdir_p} .go-cache
+
+%build
+GOCACHE="$(pwd)/.go-cache" go build -v -mod=vendor -tags="%{tags}" -ldflags="-s -w -X github.com/xo/usql/text.CommandName=%{name} -X github.com/xo/usql/text.CommandVersion=%{version}" -o bin/%{name}
+
+%install
+rm -rf $RPM_BUILD_ROOT
+
+install -d $RPM_BUILD_ROOT%{_bindir}
+
+cp -p bin/%{name} $RPM_BUILD_ROOT%{_bindir}
+
+%clean
+rm -rf $RPM_BUILD_ROOT
+
+%files
+%defattr(644,root,root,755)
+%doc README.md
+%attr(755,root,root) %{_bindir}/%{name}
================================================================
---- gitweb:
http://git.pld-linux.org/gitweb.cgi/packages/usql.git/commitdiff/6c67d6c8bedff145e6bb5a80c699e030a27ff48c
More information about the pld-cvs-commit
mailing list