Skip to content

Convert python3 to package #585

Merged
merged 3 commits into from
Jan 27, 2018
Merged

Convert python3 to package #585

merged 3 commits into from
Jan 27, 2018

Conversation

donald
Copy link
Collaborator

@donald donald commented Jan 19, 2018

edit: change /usr/local/packageby distmaster to var/pkg by pkgadmin, see mariux64/mxtools@0d57d97

We start with python3, because it has much less dependencies then python2 and requires not so much prework. We can test the general approach with it.

How it is supposed to work (where FOOBAR is e.g. python-3.6.4-0)

  • /package/pkg/FOOBAR (on nfs) is copied to /var/pkg/FOOBAR (excluding FOOBAR/build) by /usr/sbin/pkgadmin update.

  • The script /usr/sbin/make-automaps, which builds the automounter map for /pkg, has been updated to look for local copies in /var/pkg. If FOOBAR is available from there, the map entry for /pkg/FOOBAR will mount this local directory instead of the remote directory. In any case, the mount will be read-only. /usr/sbin/make-automaps is run during boot, whenever an amd map changes, or manually.

  • After /usr/local/package/admin/makebin is run on the distmaster and /usr/local/package has been pushed around, any command from FOOBAR is automatically available as prun FOOBAR cmd. Additionally, selected commands and command aliases may be made available in /usr/local/package/bin by /usr/local/package/config. Also package aliases can be configured, so that prun can be used with a short name (prun python3 python instead of prun python-3.6.4-0 python).

  • bee installations of FOOBAR, which were put into /usr/bin, /usr/lib etc. because we wanted the software to be available locally, can be removed, if we know that FOOBAR is available locally in /var/pkg. If we want certain commands to be in available in /usr/bin , e.g. to support often used shebang paths or to make the command available for root, we create a bee package which installs small wrapper scripts into /usr/bin.

/var/pkg/python-3.6.4-1 has already been pulled and the maps have been rebuild. So prun python3 or /usr/local/package/bin/python3 already run the local copy of the so-called scientific python3 on most systems (those which don't have processes locing the nfs-mount and preventing a remount). /usr/bin/python3, on the other hand, runs the (rather obsolete) bee installed python3 from the system. This pull request would change that.

@donald donald merged commit 5a39507 into master Jan 27, 2018
@donald donald deleted the convert-python3-to-package branch February 1, 2018 13:01
donald added a commit that referenced this pull request Feb 14, 2018
The Python3 installed into /usr/lib and the modules installed into
/usr/lib/python3.3 have been removed by #585. The scipy module
has unintentionally been left over. Remove it.
@donald donald mentioned this pull request Feb 14, 2018
Sign in to join this conversation on GitHub.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

1 participant