forked from pool/python-sqlglot
- Add missing-duckdb.patch until we package duckdb as well.
OBS-URL: https://build.opensuse.org/package/show/devel:languages:python/python-sqlglot?expand=0&rev=3
This commit is contained in:
@@ -16,6 +16,7 @@
|
||||
#
|
||||
|
||||
|
||||
%define modname sqlglot
|
||||
%{?!python_module:%define python_module() python-%{**} python3-%{**}}
|
||||
Name: python-sqlglot
|
||||
Version: 7.0.0
|
||||
@@ -23,10 +24,17 @@ Release: 0
|
||||
Summary: An easily customizable SQL parser and transpiler
|
||||
License: MIT
|
||||
URL: https://github.com/tobymao/sqlglot
|
||||
Source: https://files.pythonhosted.org/packages/source/s/sqlglot/sqlglot-%{version}.tar.gz
|
||||
BuildRequires: %{python_module setuptools}
|
||||
Source: https://github.com/tobymao/%{modname}/archive/refs/tags/v%{version}.tar.gz#/%{modname}-%{version}.tar.gz
|
||||
# PATCH-FIX-OPENSUSE missing-duckdb.patch mcepl@suse.com
|
||||
# Skip over duckdb requiring tests until it is packaged
|
||||
Patch0: missing-duckdb.patch
|
||||
BuildRequires: %{python_module pip}
|
||||
BuildRequires: %{python_module wheel}
|
||||
BuildRequires: fdupes
|
||||
BuildRequires: python-rpm-macros
|
||||
# FOR TESTS
|
||||
BuildRequires: %{python_module pandas}
|
||||
# END FOR TESTS
|
||||
BuildArch: noarch
|
||||
%python_subpackages
|
||||
|
||||
@@ -43,15 +51,18 @@ Syntax errors are highlighted and dialect incompatibilities can warn or raise
|
||||
depending on configurations.
|
||||
|
||||
%prep
|
||||
%setup -q -n sqlglot-%{version}
|
||||
%autosetup -p1 -n sqlglot-%{version}
|
||||
|
||||
%build
|
||||
%python_build
|
||||
%pyproject_wheel
|
||||
|
||||
%install
|
||||
%python_install
|
||||
%pyproject_install
|
||||
%python_expand %fdupes %{buildroot}%{$python_sitelib}
|
||||
|
||||
%check
|
||||
%pyunittest discover -v
|
||||
|
||||
%files %{python_files}
|
||||
%doc README.md
|
||||
%license LICENSE
|
||||
|
Reference in New Issue
Block a user