This is an automated email from the git hooks/post-receive script.
git pushed a commit to branch master
in repository python-efl.
View the commit online.
commit a1172744feac179ec5e360d6d3d4698ea618800d
Author: Dave Andreoli <[email protected]>
AuthorDate: Tue Aug 19 15:53:56 2025 +0200
Modernize build: doc gen without using setup.py
---
INSTALL | 25 +++++++++----------------
Makefile | 2 +-
doc/conf.py | 32 +++++++++-----------------------
doc/themes/efldoc/static/efl.css | 2 +-
pyproject.toml | 4 ++++
setup.py | 25 -------------------------
6 files changed, 24 insertions(+), 66 deletions(-)
diff --git a/INSTALL b/INSTALL
index dd098f2..53522cd 100644
--- a/INSTALL
+++ b/INSTALL
@@ -2,11 +2,9 @@
1. REQUIREMENTS
===============
- * Python 2.6 or higher, 3.2 or higher (http://www.python.org/)
- - Tested with Python 3.8
+ * Python 3.2 or higher (http://www.python.org/)
- * Cython 0.21 or higher (http://cython.org/)
- - Tested with Cython 0.29.16
+ * Cython 3.0 or higher (http://cython.org/)
* EFL must be the same minor version of the bindings,
es. python-efl 1.24 need efl 1.24
@@ -75,10 +73,6 @@
python setup.py install --user
- * To install for python3:
-
- (sudo) python3 setup.py install (also cython need to be installed with py3)
-
* Install with a custom prefix:
(sudo) python setup.py install --prefix=/MY_PREFIX
@@ -96,15 +90,16 @@
videos you need the YouTube module from sphinx contrib repository.
packages: python-sphinx, graphviz, python-pygraphviz, libgv-python
- To build the docs just run:
-
- python setup.py build_doc
+ To build the docs run:
+ python -m sphinx . ../build/docs/ (from the doc/ directory!)
+ or simply:
+ make doc (from base source directory)
You will find the generated html docs under the folder:
- build/sphinx/html
+ build/docs/
- Note: you must build the bindings before building the docs, or you will end
- up with empty documentation.
+ Note: you must have python-efl installed for building the docs, or you
+ will end up with empty documentation.
6. TESTS and EXAMPLES
@@ -114,8 +109,6 @@
tests or use the 00_run_all_tests.py in each folder or even in the tests/ base
dir to run all the tests at once.
- Python 2.7 / 3.2 or greater is required for running the tests.
-
The scripts in examples/ folder must be run by the user as they require
user interaction.
diff --git a/Makefile b/Makefile
index 9d0a7d9..f41795c 100644
--- a/Makefile
+++ b/Makefile
@@ -36,7 +36,7 @@ uninstall:
.PHONY: doc
doc:
- $(PY) setup.py build build_doc
+ cd doc; $(PY) -m sphinx . ../build/docs/; cd ..
.PHONY: test
diff --git a/doc/conf.py b/doc/conf.py
index fb480d0..c2a4974 100644
--- a/doc/conf.py
+++ b/doc/conf.py
@@ -8,34 +8,20 @@
# pylint: disable=invalid-name
-import os
-import sys
-import platform
-
-
-# -- Path setup --------------------------------------------------------------
-
-# If extensions (or modules to document with autodoc) are in another directory,
-# add these directories to sys.path here.
-d = 'lib.%s-%s-%d.%d' % (
- platform.system().lower(),
- platform.machine(),
- sys.version_info[0],
- sys.version_info[1]
-)
-sys.path.insert(0, os.path.abspath('../build/' + d))
-# sys.path.insert(0, os.path.abspath('../build/lib.linux-i686-3.2'))
-
-# Delete any previously imported efl package
-if 'efl' in sys.modules:
- del sys.modules['efl']
-
# -- Project information -----------------------------------------------------
+try:
+ from efl import __version__ as efl_version
+except Exception as e:
+ print('ERROR: Python EFL not found')
+ print('ERROR:', e)
+ exit(1)
project = 'Python EFL'
+version = efl_version
+release = efl_version
author = 'The Python-EFL community (see AUTHORS)'
-copyright = '2008-2022, ' + author # pylint: disable=redefined-builtin
+copyright = '2008-2025, ' + author # pylint: disable=redefined-builtin
# -- General configuration ----------------------------------------------------
diff --git a/doc/themes/efldoc/static/efl.css b/doc/themes/efldoc/static/efl.css
index f695997..4199410 100644
--- a/doc/themes/efldoc/static/efl.css
+++ b/doc/themes/efldoc/static/efl.css
@@ -283,7 +283,7 @@ p {
margin: 0.8em 0 0.5em 0;
}
-a {
+a, a:visited {
color: rgb(170,170,180);
text-decoration: none;
}
diff --git a/pyproject.toml b/pyproject.toml
index 8950193..09754ac 100644
--- a/pyproject.toml
+++ b/pyproject.toml
@@ -42,6 +42,10 @@ Repository = 'https://git.enlightenment.org/enlightenment/python-efl'
Changelog = 'https://git.enlightenment.org/enlightenment/python-efl/raw/branch/master/ChangeLog'
+[project.optional-dependencies]
+doc = ['sphinx', 'graphviz']
+
+
[tool.setuptools.dynamic]
version = {attr = 'efl.__version__'}
diff --git a/setup.py b/setup.py
index 9bed6bb..c091856 100755
--- a/setup.py
+++ b/setup.py
@@ -346,26 +346,6 @@ class Test(Command):
runner.run(suite)
-# === setup.py build_doc command ===
-try:
- from sphinx.setup_command import BuildDoc
-except ImportError:
- class BuildDoc(Command):
- description = 'build docs using sphinx, that must be installed.'
- version = ''
- release = ''
- user_options = []
-
- def initialize_options(self):
- pass
-
- def finalize_options(self):
- pass
-
- def run(self):
- print('Error: sphinx not found')
-
-
# === setup.py clean_generated_files command ===
class CleanGenerated(Command):
description = 'Clean C and html files generated by Cython'
@@ -437,15 +417,10 @@ class Uninstall(Command):
setup(
cmdclass={
'test': Test,
- 'build_doc': BuildDoc,
'clean_generated_files': CleanGenerated,
'uninstall': Uninstall,
},
command_options={
- 'build_doc': {
- 'version': ('setup.py', RELEASE),
- 'release': ('setup.py', RELEASE),
- },
'install': {
'record': ('setup.py', RECORD_FILE),
},
--
To stop receiving notification emails like this one, please contact
the administrator of this repository.