But although the python pyproject.toml specifies an entry point, the entrypoitn is nowhere to be seen:
[root@7b13937f1d89 dupa-cli]# rpm -i dupa_cli-1.0.rpm
[root@7b13937f1d89 dupa-cli]# rpm -qa | grep dupa
dupa_cli-1.0-1.aarch64
[root@7b13937f1d89 dupa-cli]# dupa-cli
bash: /usr/bin/dupa-cli: No such file or directory
[root@7b13937f1d89 dupa-cli]# dupa_cli
bash: dupa_cli: command not found
The files are present in /usr/share/python/root/dupa-cli/:
[root@7b13937f1d89 dupa-cli]# ls -la
total 28
drwxr-xr-x 5 root root 4096 Oct 17 14:18 .
drwxr-xr-x 3 root root 4096 Oct 17 11:51 ..
-rw-r--r-- 1 root root 40 Oct 17 14:18 .gitignore
drwxr-xr-x 2 root root 4096 Oct 17 14:18 bin
drwxr-xr-x 3 root root 4096 Oct 17 11:51 lib
drwxr-xr-x 3 root root 4096 Oct 17 11:51 lib64
-rw-r--r-- 1 root root 207 Oct 17 14:18 pyvenv.cfg
[root@7b13937f1d89 dupa-cli]# cat pyvenv.cfg
home = /usr/bin
implementation = CPython
version_info = 3.11.6.final.0
virtualenv = 20.24.5
include-system-site-packages = false
base-prefix = /usr
base-exec-prefix = /usr
base-executable = /usr/bin/python3
[root@7b13937f1d89 dupa-cli]# cd bin/
[root@7b13937f1d89 bin]# ls -la
total 72
drwxr-xr-x 2 root root 4096 Oct 17 14:18 .
drwxr-xr-x 5 root root 4096 Oct 17 14:18 ..
-rw-r--r-- 1 root root 2236 Oct 17 14:18 activate
-rw-r--r-- 1 root root 1503 Oct 17 14:18 activate.csh
-rw-r--r-- 1 root root 3066 Oct 17 14:18 activate.fish
-rw-r--r-- 1 root root 2840 Oct 17 14:18 activate.nu
-rw-r--r-- 1 root root 1650 Oct 17 14:18 activate.ps1
-rw-r--r-- 1 root root 1371 Oct 17 14:18 activate_this.py
-rwxr-xr-x 1 root root 271 Oct 17 14:18 dupa-cli
-rwxr-xr-x 1 root root 279 Oct 17 14:18 markdown-it
-rwxr-xr-x 1 root root 280 Oct 17 14:18 pip
-rwxr-xr-x 1 root root 280 Oct 17 14:18 pip3
-rwxr-xr-x 1 root root 280 Oct 17 14:18 pip3.11
-rwxr-xr-x 1 root root 274 Oct 17 14:18 pygmentize
lrwxrwxrwx 1 root root 16 Oct 17 14:18 python -> /usr/bin/python3
lrwxrwxrwx 1 root root 6 Oct 17 14:18 python3 -> python
lrwxrwxrwx 1 root root 6 Oct 17 14:18 python3.11 -> python
-rwxr-xr-x 1 root root 267 Oct 17 14:18 wheel
-rwxr-xr-x 1 root root 267 Oct 17 14:18 wheel-3.11
-rwxr-xr-x 1 root root 267 Oct 17 14:18 wheel3
-rwxr-xr-x 1 root root 267 Oct 17 14:18 wheel3.11
Executed with an absolute path it works:
[root@7b13937f1d89 bin]# /usr/share/python/root/dupa-cli/bin/dupa-cli --help
Usage: dupa-cli [OPTIONS] COMMAND [ARGS]...
╭─ Options ──────────────────────────────────────────────────────────────────────────────────────────────────────────────╮
│ --install-completion Install completion for the current shell. │
│ --show-completion Show completion for the current shell, to copy it or customize the installation. │
│ --help Show this message and exit. │
╰────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────╯
╭─ Commands ─────────────────────────────────────────────────────────────────────────────────────────────────────────────╮
│ bye │
│ hello │
╰────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────╯
How can I/should I make it a normal executable from the perspective of the system?
I created an RPM package using fpm like this:
The package is created without a problem, the pyproject:
The package builds:
After installation the package is visible and also present in
/usr/share...
:But although the python
pyproject.toml
specifies an entry point, the entrypoitn is nowhere to be seen:The files are present in
/usr/share/python/root/dupa-cli/
:Executed with an absolute path it works:
How can I/should I make it a normal executable from the perspective of the system?