Menu

#225 Python3: Removal of Python2 Build Dependencies

v1.0 (example)
closed
None
5
2026-03-23
2026-03-17
Al von Ruff
No

Python2 is not available on new Linux distros. We make the following changes to the build system while the hood is open:

1] There are 4 specific make targets:

  • make - creates the local directory, converts .py to .cgi, includes appropriate libraries and localdefs.py. This allows developers to execute cgi script in local from the command line, without updating the site binaries.
  • make install - installs the local/.cgi scripts into /var/www/cgibin (or whatever INSTALLCGI says). If you want to one-stop shop, make install will do a make and an install.**
  • make clean - Cleans out any .cgi and .pyc in the parent of parent/local directories
  • make clobber - Also removes files compied from /common, and whacks the parent/local directory

2] The top-level Makefile calls the directory makefiles with the 'all' target, which now honors dependencies. So if you touch a .py file, a make will cause only that file to be rebuilt into a .cgi

3] All local.mk files invoke install.py with $(PYVER)

4] Organized each local.mk to have 5 distinct sections: local libraries, common libraries, creation of .cgi, installation of .cgi, and cleanup.

5] The css directory was a mess. Updated the Makefile, and ported index_install.py to python3.

Discussion

  • Al von Ruff

    Al von Ruff - 2026-03-23

    Ticket moved from /p/isfdb/feature-requests/1707/

     
  • Al von Ruff

    Al von Ruff - 2026-03-23
    • status: open --> closed
    • Group: Approved --> v1.0 (example)
     

Anonymous
Anonymous

Add attachments
Cancel





MongoDB Logo MongoDB