Page 15 of 15

[Porteus 5.0's USM replacement] getmod: A wrapper for slapt-get to build modules

Posted: 15 Jan 2023, 17:20
by benjibasson
Hi,
I cannot download any package with the getmod althought

Code: Select all

getmod -u
has been launched?

for many applications it doesn't build any module. in fact it confuse -m, -M with -d and download only

Code: Select all

root@porteus:/home/guest#getmod -M kdenlive-21.12.1-x86_64-1
Reading Package Lists...Done
The following NEW packages will be installed:
  gstreamer hunspell jasper graphene gtk4 libwacom libinput judy mariadb 
  openal-soft speech-dispatcher xcb-util-image xcb-util-keysyms 
  xcb-util-renderutil xcb-util-wm qt5 attica karchive python2 kcoreaddons 
  polkit-qt-1 kauth kcodecs kconfig kguiaddons ki18n kwidgetsaddons 
  kconfigwidgets kwindowsystem kcrash kdbusaddons kglobalaccel kitemviews 
  kiconthemes kxmlgui kbookmarks kcompletion kdoctools kjobwidgets 
  libdbusmenu-qt knotifications kservice aspell sonnet ktextwidgets kwallet 
  solid kio kpackage kdeclarative ebook-tools kfilemetadata syndication 
  knewstuff knotifyconfig libid3tag sox vid.stab mlt purpose kdenlive 
0 upgraded, 0 reinstalled, 61 newly installed, 0 to remove, 0 not upgraded.
Need to get 155.0kB/187.9MB of archives.
Do you want to continue? [y/N] y

Done
root@porteus:/home/guest# getmod -m kdenlive-21.12.1-x86_64-1
Reading Package Lists...Done
The following NEW packages will be installed:
  gstreamer hunspell jasper graphene gtk4 libwacom libinput judy mariadb 
  openal-soft speech-dispatcher xcb-util-image xcb-util-keysyms 
  xcb-util-renderutil xcb-util-wm qt5 attica karchive python2 kcoreaddons 
  polkit-qt-1 kauth kcodecs kconfig kguiaddons ki18n kwidgetsaddons 
  kconfigwidgets kwindowsystem kcrash kdbusaddons kglobalaccel kitemviews 
  kiconthemes kxmlgui kbookmarks kcompletion kdoctools kjobwidgets 
  libdbusmenu-qt knotifications kservice aspell sonnet ktextwidgets kwallet 
  solid kio kpackage kdeclarative ebook-tools kfilemetadata syndication 
  knewstuff knotifyconfig libid3tag sox vid.stab mlt purpose kdenlive 
0 upgraded, 0 reinstalled, 61 newly installed, 0 to remove, 0 not upgraded.
Need to get 155.0kB/187.9MB of archives.
Do you want to continue? [y/N] y

Done

Code: Select all

root@porteus:/home/guest# getmod -m Blender-3.0.1-x86_64-2salix15.0
Reading Package Lists...Done
Installed v4l-utils conflicts with v4l-utils-nogui
The following NEW packages will be installed:
  jasper LibRaw OpenSubdiv gstreamer hunspell graphene gtk4 libwacom libinput 
  judy mariadb openal-soft speech-dispatcher xcb-util-image xcb-util-keysyms 
  xcb-util-renderutil xcb-util-wm qt5 cmake dcmtk expat jemalloc opencollada 
  pybind11 opencolorio python2 openexr libwmf imagemagick xine-lib opencv 
  robin-map tbb fmt gcc-go gcc gcc-gfortran libaec hdf5 openimageio potrace 
  pugixml v4l-utils-nogui vid.stab Blender 
The following packages will be REMOVED:
  v4l-utils 
0 upgraded, 0 reinstalled, 45 newly installed, 1 to remove, 0 not upgraded.
Need to get 85.0kB/332.3MB of archives.
Do you want to continue? [y/N] y

Done
root@porteus:/home/guest# getmod -M Blender-3.0.1-x86_64-2salix15.0
Reading Package Lists...Done
Installed v4l-utils conflicts with v4l-utils-nogui
The following NEW packages will be installed:
  jasper LibRaw OpenSubdiv gstreamer hunspell graphene gtk4 libwacom libinput 
  judy mariadb openal-soft speech-dispatcher xcb-util-image xcb-util-keysyms 
  xcb-util-renderutil xcb-util-wm qt5 cmake dcmtk expat jemalloc opencollada 
  pybind11 opencolorio python2 openexr libwmf imagemagick xine-lib opencv 
  robin-map tbb fmt gcc-go gcc gcc-gfortran libaec hdf5 openimageio potrace 
  pugixml v4l-utils-nogui vid.stab Blender 
The following packages will be REMOVED:
  v4l-utils 
0 upgraded, 0 reinstalled, 45 newly installed, 1 to remove, 0 not upgraded.
Need to get 85.0kB/332.3MB of archives.
Do you want to continue? [y/N] y

Done
for modules converted to xzm there are plenty missing dependences

Code: Select all

guest@porteus:~$ pitivi 
Could not import 'GstTranscoder'. Make sure you have it available.

Code: Select all

guest@porteus:~$ openshot-qt 
Traceback (most recent call last):
  File "/usr/bin/openshot-qt", line 33, in <module>
    sys.exit(load_entry_point('openshot-qt==2.6.1', 'gui_scripts', 'openshot-qt')())
  File "/usr/bin/openshot-qt", line 25, in importlib_load_entry_point
    return next(matches).load()
  File "/usr/lib64/python3.9/importlib/metadata.py", line 86, in load
    module = import_module(match.group('module'))
  File "/usr/lib64/python3.9/importlib/__init__.py", line 127, in import_module
    return _bootstrap._gcd_import(name[level:], package, level)
  File "<frozen importlib._bootstrap>", line 1030, in _gcd_import
  File "<frozen importlib._bootstrap>", line 1007, in _find_and_load
  File "<frozen importlib._bootstrap>", line 986, in _find_and_load_unlocked
  File "<frozen importlib._bootstrap>", line 680, in _load_unlocked
  File "<frozen importlib._bootstrap_external>", line 850, in exec_module
  File "<frozen importlib._bootstrap>", line 228, in _call_with_frames_removed
  File "/usr/lib64/python3.9/site-packages/openshot_qt/launch.py", line 47, in <module>
    from PyQt5.QtCore import Qt
ModuleNotFoundError: No module named 'PyQt5'

Code: Select all

guest@porteus:~$ openshot-qt 
Traceback (most recent call last):
  File "/usr/bin/openshot-qt", line 33, in <module>
    sys.exit(load_entry_point('openshot-qt==2.6.1', 'gui_scripts', 'openshot-qt')())
  File "/usr/bin/openshot-qt", line 25, in importlib_load_entry_point
    return next(matches).load()
  File "/usr/lib64/python3.9/importlib/metadata.py", line 86, in load
    module = import_module(match.group('module'))
  File "/usr/lib64/python3.9/importlib/__init__.py", line 127, in import_module
    return _bootstrap._gcd_import(name[level:], package, level)
  File "<frozen importlib._bootstrap>", line 1030, in _gcd_import
  File "<frozen importlib._bootstrap>", line 1007, in _find_and_load
  File "<frozen importlib._bootstrap>", line 986, in _find_and_load_unlocked
  File "<frozen importlib._bootstrap>", line 680, in _load_unlocked
  File "<frozen importlib._bootstrap_external>", line 850, in exec_module
  File "<frozen importlib._bootstrap>", line 228, in _call_with_frames_removed
  File "/usr/lib64/python3.9/site-packages/openshot_qt/launch.py", line 47, in <module>
    from PyQt5.QtCore import Qt
ModuleNotFoundError: No module named 'PyQt5'
what am I suppose to do to have getmod working properly?

[Porteus 5.0's USM replacement] getmod: A wrapper for slapt-get to build modules

Posted: 16 Jan 2023, 01:22
by Rapha_

Code: Select all

ModuleNotFoundError: No module named 'PyQt5'
For openshot-qt it seem you need more PyQt5 ( PyQt5-5.15.2-x86_64-5.txz )
beny wrote:
12 Jan 2023, 21:21
hi use this link to search packages for porteus check 15 and x86_64:
https://slackware.nl/slakfinder/
well but isn't a light task to search all the deps

[Porteus 5.0's USM replacement] getmod: A wrapper for slapt-get to build modules

Posted: 16 Jan 2023, 19:58
by babam
benjibasson wrote:
15 Jan 2023, 17:20
Hi,
I cannot download any package with the getmod althought

Code: Select all

getmod -u
has been launched?

for many applications it doesn't build any module. in fact it confuse -m, -M with -d and download only
Try to comment out line 228

[Porteus 5.0's USM replacement] getmod: A wrapper for slapt-get to build modules

Posted: 16 Jan 2023, 23:20
by Ed_P
babam wrote:
16 Jan 2023, 19:58
Try to comment out line 228
/usr/bin/getmod

Code: Select all

#   [ $? != 0 ] && exit
Like so :)

benjibasson wrote:
15 Jan 2023, 17:20

Code: Select all

root@porteus:/home/guest# getmod -m Blender-3.0.1-x86_64-2salix15.0
This doesn't work for you? blender module build script


Added in 8 hours 30 minutes 34 seconds:
babam, this 9 line narrative:

Code: Select all

guest@porteus:~$ getmod -u

We trust you have received the usual lecture from the local System
Administrator. It usually boils down to these three things:

    #1) Respect the privacy of others.
    #2) Think before you type.
    #3) With great power comes great responsibility.

Enter root's password: 
can be reduced to 2 lines with a root test like this:

Code: Select all

if [ `whoami` != "root" ]; then
   echo -e "Enter root's password\033[1;31m"
   su -c "sh $0 $1 $2"; exit
fi
echo -e "\033[0m"; echo -en "\033]0;GetMod\a"

[Porteus 5.0's USM replacement] getmod: A wrapper for slapt-get to build modules

Posted: 17 Jan 2023, 10:58
by babam
Ed_P wrote:
17 Jan 2023, 07:56
babam, this 9 line narrative:

Code: Select all

guest@porteus:~$ getmod -u

We trust you have received the usual lecture from the local System
Administrator. It usually boils down to these three things:

    #1) Respect the privacy of others.
    #2) Think before you type.
    #3) With great power comes great responsibility.

Enter root's password: 
can be reduced to 2 lines with a root test like this:

Code: Select all

if [ `whoami` != "root" ]; then
   echo -e "Enter root's password\033[1;31m"
   su -c "sh $0 $1 $2"; exit
fi
echo -e "\033[0m"; echo -en "\033]0;GetMod\a"
You are free to modify it.

[Porteus 5.0's USM replacement] getmod: A wrapper for slapt-get to build modules

Posted: 17 Jan 2023, 15:59
by Ed_P
babam wrote:
17 Jan 2023, 10:58
You are free to modify it.
:) Thank you. :) Other 011-* module users might appreciate the change also, especially newbies. :)

[Porteus 5.0's USM replacement] getmod: A wrapper for slapt-get to build modules

Posted: 20 Jan 2023, 22:13
by Ed_P
For users interested in making the discussed getmod changes:

Code: Select all

guest@porteus:~$ diff  /usr/bin/getmod  /mnt/live/memory/images/011-slapt-get-0.11.6-x86_64-2gv.xzm/usr/bin/getmod 
15,16c15,16
<    echo -e "Enter root's password\033[1;31m"   # sudo -E -p "Enter root's password: " "$0" "$@"
<    su -c "sh $0 $*"; exit                      # exit
---
>     sudo -E -p "Enter root's password: " "$0" "$@"
>     exit
18c18
< echo -e "\033[0m"; echo -en "\033]0;GetMod\a"  #  
---
> 
228c228
< #    [ $? != 0 ] && exit
---
>     [ $? != 0 ] && exit
guest@porteus:~$ 
< = my lines 15,16,18 & 228 changes
> = the current lines

And my current slapt-getrc file.

Code: Select all

guest@porteus:~$ diff /etc/slapt-get/slapt-getrc /mnt/live/memory/images/011-slapt-get-0.11.6-x86_64-2gv.xzm/etc/slapt-get/slapt-getrc 
18,28d17
< # The Slakfinder repository
< #SOURCE=https://slakfinder.org/sbomt64-15.0/:DEFAULT
< # commented out since slakfinder.org not working at this point.
< # Eric's US mirror
< SOURCE=http://taper.alienbase.nl/slackpkgplus/
< 
< SOURCE=https://slackware.uk/csb/15.0/x86_64/
< SOURCE=http://ponce.cc/slackware/slackware64-15.0/packages/
< 
< SOURCE=https://slackware.nl/people/alien/sbrepos/15.0/x86_64
< 
< = my 11 lines added after line 17.

[Porteus 5.0's USM replacement] getmod: A wrapper for slapt-get to build modules

Posted: 10 Oct 2023, 19:58
by Ed_P
getmod has been replaced by slapt-mod in Porteus 5.01. :good:

[Porteus 5.0's USM replacement] getmod: A wrapper for slapt-get to build modules

Posted: 10 Oct 2023, 20:00
by Rava
Ed_P wrote:
10 Oct 2023, 19:58
getmod has been replaced by slapt-mod in Porteus 5.01. :good:
Wasn't getmod used as base to create slapt-mod?

Added in 2 minutes 30 seconds:
When you start both without any argument you see the similarity:

slapt-mod

Code: Select all

  slapt-mod: A simple wrapper for slapt-get to build Porteus module.

   slapt-mod [-c] [-u] [-d|-m|-M|-n|-N PACKAGE_NAME] [-l PATTERN] [-s PATTERN]

Options:
  -c: Purge cached packages
  -d: Download only
  -m: Download and build module (ZSTD compression)
  -M: Download and build module (XZ compression)
  -n: Download and build module without dependencies (ZSTD compression)
  -N: Download and build module without dependencies (XZ compression)
  -l: List installed packages
  -s: Search package
  -u: Update database
  -h: This usage

   To change the temporary directory (default is /tmp), pass the TMP variable.
   $ TMP=/path/to/directory slapt-mod -m packagename

   Temporary directory is for storing downloaded packages, installing and converting to modules.
getmod

Code: Select all

   getmod: A simple wrapper for slapt-get to build Porteus module.

   getmod [-c] [-u] [-d|-m|-M|-n|-N PACKAGE_NAME] [-l PATTERN] [-s PATTERN]

Options:
  -c: Purge cached packages
  -d: Download only
  -m: Download and build module (ZSTD compression)
  -M: Download and build module (XZ compression)
  -n: Download and build module without dependencies (ZSTD compression)
  -N: Download and build module without dependencies (XZ compression)
  -l: List installed packages
  -s: Search package
  -u: Update database
  -h: This usage

   To change the temporary directory (default is /tmp), pass the TMP variable.
   $ TMP=/path/to/directory getmod -m packagename

   Temporary directory is for storing downloaded packages, installing and converting to modules.
See?

Added in 2 minutes 56 seconds:
Also, babam is mentioned as creator alongside ncmprhnsbl in the starting comments of /usr/local/bin/slapt-mod

[Porteus 5.0's USM replacement] getmod: A wrapper for slapt-get to build modules

Posted: 10 Oct 2023, 20:09
by Ed_P
Rava wrote:
10 Oct 2023, 20:06
Wasn't getmod used as base to create slapt-mod?

Added in 2 minutes 30 seconds:
When you start both without any argument you see the similarity:
Yup. I did the same thing to reach the same conclusion. :happy62:

[Porteus 5.0's USM replacement] getmod: A wrapper for slapt-get to build modules

Posted: 18 Oct 2023, 22:51
by francois
Is it possible to ask getmod to build multiple modules in one batch?