Skip to content
This repository has been archived by the owner on Jan 30, 2023. It is now read-only.

Commit

Permalink
build/pkgs/sagelib/src/setup.py: Make 'setup.py sdist' work without C…
Browse files Browse the repository at this point in the history
…ython
  • Loading branch information
Matthias Koeppe committed Oct 17, 2020
1 parent 698a6ea commit bb32e80
Showing 1 changed file with 12 additions and 10 deletions.
22 changes: 12 additions & 10 deletions build/pkgs/sagelib/src/setup.py
Original file line number Diff line number Diff line change
Expand Up @@ -57,18 +57,20 @@
print("Discovering Python/Cython source code....")
t = time.time()

distributions = ['']

from sage_setup.optional_extension import is_package_installed_and_updated

optional_packages_with_extensions = ['mcqd', 'bliss', 'tdlib', 'primecount',
'coxeter3', 'fes', 'sirocco', 'meataxe']

distributions += ['sage-{}'.format(pkg)
for pkg in optional_packages_with_extensions
if is_package_installed_and_updated(pkg)]

log.warn('distributions = {0}'.format(distributions))
if sdist:
# No need to compute distributions. This avoids a dependency on Cython
# just to make an sdist.
distributions = None
else:
distributions = ['']
optional_packages_with_extensions = ['mcqd', 'bliss', 'tdlib', 'primecount',
'coxeter3', 'fes', 'sirocco', 'meataxe']
distributions += ['sage-{}'.format(pkg)
for pkg in optional_packages_with_extensions
if is_package_installed_and_updated(pkg)]
log.warn('distributions = {0}'.format(distributions))

from sage_setup.find import find_python_sources
python_packages, python_modules, cython_modules = find_python_sources(
Expand Down

0 comments on commit bb32e80

Please sign in to comment.