slpkg & tar2xzm > txz2xzm

Non release banter
User avatar
Ed_P
Contributor
Contributor
Posts: 8341
Joined: 06 Feb 2013, 22:12
Distribution: Cinnamon 5.01 ISO
Location: Western NY, USA

slpkg & tar2xzm > txz2xzm

Post#1 by Ed_P » 02 Apr 2019, 03:44

So I've downloaded slpkg-3.4.2.tar.gz, extracted slpkg-3.4.2.tar and as both guest and root tried to convert it to a xzm module using tar2xzm. Surprise, Porteus doesn't have a tar2xzm function. I thought it did.

So, how do I create a slpkg xzm module?? :unknown:
Last edited by Ed_P on 04 Apr 2019, 03:34, edited 1 time in total.
Ed

donald
Full of knowledge
Full of knowledge
Posts: 2063
Joined: 17 Jun 2013, 13:17
Distribution: Porteus 3.2.2 XFCE 32bit
Location: Germany

tar2xzm

Post#2 by donald » 02 Apr 2019, 05:13

So, how do I create a slpkg xzm module?
Hi Ed

Activate 05-devel.xzm

Download the SlackBuild archive and extract it.
https://slackbuilds.org/repository/14.2/system/slpkg/

After extracting the slpkg.tar.gz archive, you should have the following directory tree:

./slpkg
|-- README
|-- slpkg.info
|-- slpkg.SlackBuild
|-- slack-desc
|-- doinst.sh

Next, download the source of the application slpkg-3.4.2.tar.gz
and place it in the slpkg directory listed above.

Make the script executable with chmod if necessary:

chmod +x slpkg.SlackBuild

Then run the script (as root):

./slpkg.SlackBuild

slackware package (*.tgz) will be in /tmp -- run tgz2xzm txz2xzm

Or, much easier,
Activate 05-devel.xzm and run:

Code: Select all

root@porteus:/home/guest# usm sbo -s slpkg
Last edited by Ed_P on 02 Apr 2019, 20:18, edited 1 time in total.
Reason: Correct a typo.

beny
Full of knowledge
Full of knowledge
Posts: 2086
Joined: 02 Jan 2011, 11:33
Location: italy

tar2xzm

Post#3 by beny » 02 Apr 2019, 10:21


Kulle
Warlord
Warlord
Posts: 594
Joined: 28 Jan 2017, 10:39
Distribution: v4.0 64bit Xfce
Location: Berlin

tar2xzm

Post#4 by Kulle » 02 Apr 2019, 10:36

Hi Donald,
I did the following
1.) activate 05-devel.xzm
2.) usm sbo -s slpkg
result:
Slackware package /tmp/slpkg-3.4.2-x86_64-1_SBo.tgz created.
3.) txz2xzm
result:
slpkg-3.4.2-x86_64-1_SBo.xzm
4.) activate and run in terminal

Code: Select all

guest@porteus:~$ slpkg
Traceback (most recent call last):
  File "/usr/bin/slpkg", line 35, in <module>
    from slpkg.main import main
  File "/usr/lib64/python2.7/site-packages/slpkg/main.py", line 60, in <module>
    from slpkg.sbo.network import SBoNetwork
  File "/usr/lib64/python2.7/site-packages/slpkg/sbo/network.py", line 27, in <module>
    import pydoc
ImportError: No module named pydoc
A python2.7 error like here:
gespeaker: python-error

User avatar
Ed_P
Contributor
Contributor
Posts: 8341
Joined: 06 Feb 2013, 22:12
Distribution: Cinnamon 5.01 ISO
Location: Western NY, USA

tar2xzm

Post#5 by Ed_P » 02 Apr 2019, 14:52

Code: Select all

guest@porteus:~$ su
Password: 
root@porteus:/home/guest# usm -g slpkg

 Nothing found for:  slpkg 
:o
donald wrote:
02 Apr 2019, 05:13
Or, much easier,
Activate 05-devel.xzm and run:

Code: Select all

root@porteus:/home/guest# usm sbo -s slpkg
Wow, thank you donald. :friends: Did as you suggested. :)

Code: Select all

root@porteus:/home/guest# usm sbo -s slpkg


NAME :  slpkg 
CATEG: system
DESC : 
VERS : 3.4.2

 Would you like to attempt to build this from source? [y/n]
Downloading: slpkg.tar.gz  DONE
/tmp/usmsbo /home/guest

Downloading: slpkg-3.4.2.tar.gz  DONE
slpkg-3.4.2/
slpkg-3.4.2/.gitignore
slpkg-3.4.2/.travis.yml
 :
 :
 Many, many, many more lines
 :
 :
usr/lib64/python2.7/site-packages/slpkg/binary/greps.py
usr/lib64/python2.7/site-packages/slpkg/binary/dependency.py
usr/lib64/python2.7/site-packages/slpkg/binary/check.py
usr/lib64/python2.7/site-packages/slpkg/binary/__init__.py

Slackware package /tmp/slpkg-3.4.2-x86_64-1_SBo.tgz created.


root@porteus:/home/guest#

:Yahoo!:

Code: Select all

root@porteus:/home/guest# cd /tmp
root@porteus:/tmp# tgz2xzm *.tgz
bash: tgz2xzm: command not found
root@porteus:/tmp# 
:wall:
Ed

donald
Full of knowledge
Full of knowledge
Posts: 2063
Joined: 17 Jun 2013, 13:17
Distribution: Porteus 3.2.2 XFCE 32bit
Location: Germany

tar2xzm

Post#6 by donald » 02 Apr 2019, 17:02

@ Ed
Command is txz2xzm (Work with txz/tgz packages). Sorry Ed.

@ Kulle
Python 2.7 is missing.

@ beny
Thanks!

User avatar
Ed_P
Contributor
Contributor
Posts: 8341
Joined: 06 Feb 2013, 22:12
Distribution: Cinnamon 5.01 ISO
Location: Western NY, USA

tar2xzm

Post#7 by Ed_P » 02 Apr 2019, 17:12

donald wrote:
02 Apr 2019, 17:02
Command is txz2xzm (Work with txz/tgz packages). Sorry Ed.
No problem, I mistype things all the time. :happy62:

Code: Select all

root@porteus:/tmp# txz2xzm *.tgz
Verifying package slpkg-3.4.2-x86_64-1_SBo.tgz.
Installing package slpkg-3.4.2-x86_64-1_SBo.tgz:
PACKAGE DESCRIPTION:
# slpkg (Slackware Packaging Tool)
#
# Slpkg is a powerful software package manager that installs, updates
# and removes packages on Slackware based systems. It automatically
# computes dependencies and figures out what things should occur
# to install packages. Slpkg makes it easier to maintain groups of
# of machines without having to manually update.
#
# Homepage: https://dslackw.gitlab.io/slpkg
#
Executing install script for slpkg-3.4.2-x86_64-1_SBo.tgz.
Package slpkg-3.4.2-x86_64-1_SBo.tgz installed.

Creating /tmp/slpkg-3.4.2-x86_64-1_SBo.xzm

root@porteus:/tmp# 
:Yahoo!:
Thank you :worthy: donald. :beer:
Ed

User avatar
Rava
Contributor
Contributor
Posts: 5401
Joined: 11 Jan 2011, 02:46
Distribution: XFCE 5.01 x86_64 + 4.0 i586
Location: Forests of Germany

tar2xzm

Post#8 by Rava » 02 Apr 2019, 20:10

Ed_P, mind uploading slpkg-3.4.2-x86_64-1_SBo.xzm for others to use?
Cheers!
Yours Rava

User avatar
Ed_P
Contributor
Contributor
Posts: 8341
Joined: 06 Feb 2013, 22:12
Distribution: Cinnamon 5.01 ISO
Location: Western NY, USA

tar2xzm

Post#9 by Ed_P » 02 Apr 2019, 20:13

Since it's easy to create it I don't see much need for that. :)

Besides...

Code: Select all

guest@porteus:~$ slpkg
Traceback (most recent call last):
  File "/usr/bin/slpkg", line 35, in <module>
    from slpkg.main import main
  File "/usr/lib64/python2.7/site-packages/slpkg/main.py", line 60, in <module>
    from slpkg.sbo.network import SBoNetwork
  File "/usr/lib64/python2.7/site-packages/slpkg/sbo/network.py", line 27, in <module>
    import pydoc
ImportError: No module named pydoc

guest@porteus:~$ su
Password: 
root@porteus:/home/guest# slpkg
Traceback (most recent call last):
  File "/usr/bin/slpkg", line 35, in <module>
    from slpkg.main import main
  File "/usr/lib64/python2.7/site-packages/slpkg/main.py", line 60, in <module>
    from slpkg.sbo.network import SBoNetwork
  File "/usr/lib64/python2.7/site-packages/slpkg/sbo/network.py", line 27, in <module>
    import pydoc
ImportError: No module named pydoc

root@porteus:/home/guest# ls -d /mnt/live/memory/images/05*
/mnt/live/memory/images/05-devel.xzm/

root@porteus:/home/guest# python
Python 2.7.14 (default, Sep 22 2017, 11:31:09) 
[GCC 7.2.0] on linux2
Type "help", "copyright", "credits" or "license" for more information.
>>> 
[1]+  Stopped                 python
root@porteus:/home/guest# 

root@porteus:/home/guest# ls /usr/lib64/python2.7/site-packages/slpkg/sbo/n*
/usr/lib64/python2.7/site-packages/slpkg/sbo/network.py
/usr/lib64/python2.7/site-packages/slpkg/sbo/network.pyc

root@porteus:/home/guest# cat /usr/lib64/python2.7/site-packages/slpkg/sbo/network.py
 :
 :
25. import os
26. import sys
27. import pydoc
 :
 :
:hammer:
Ed

User avatar
ncmprhnsbl
DEV Team
DEV Team
Posts: 3924
Joined: 20 Mar 2012, 03:42
Distribution: v5.0-64bit
Location: australia
Contact:

tar2xzm

Post#10 by ncmprhnsbl » 03 Apr 2019, 00:10

pydoc is part of python2.7 that gets removed in the stripping process(because it's not used by much)
here's an xzm module(for x86_64): pydoc.xzm
there's a good chance slkpkg might need some other python modules.. run and see..
Forum Rules : https://forum.porteus.org/viewtopic.php?f=35&t=44

User avatar
Ed_P
Contributor
Contributor
Posts: 8341
Joined: 06 Feb 2013, 22:12
Distribution: Cinnamon 5.01 ISO
Location: Western NY, USA

tar2xzm

Post#11 by Ed_P » 03 Apr 2019, 00:40

Code: Select all

guest@porteus:~$ slpkg

slpkg: Error: Must have root privileges

guest@porteus:~$ su
Password: 
root@porteus:/home/guest# slpkg
Usage: slpkg [COMMANDS|OPTIONS] {repository|package...}

             Commands:
             [update, --repositories=[...]]
             [upgrade, --repositories=[...]]
             [repo-add [repository name] [URL]]
             [repo-remove [repository]]
  :
  :
  :
             [-d [package...]]
             
For more information try 'slpkg -h, --help' or view manpage

root@porteus:/home/guest# slpkg -h

slpkg - version 3.4.2 | Slackware release: stable - 14.2

Slpkg is a user-friendly package manager for Slackware installations

Usage: slpkg [COMMANDS|OPTIONS] {repository|package...}

                                                   _       _
                                               ___| |_ __ | | ____ _
                                              / __| | '_ \| |/ / _` |
                                              \__ \ | |_) |   < (_| |
                                              |___/_| .__/|_|\_\__, |
                                                    |_|        |___/
                                             _Slackware package manager_______

Commands:
 :
 :
 :
 
:thumbsup:

Thank you ncmp. :beer:
Ed

User avatar
Ed_P
Contributor
Contributor
Posts: 8341
Joined: 06 Feb 2013, 22:12
Distribution: Cinnamon 5.01 ISO
Location: Western NY, USA

tar2xzm

Post#12 by Ed_P » 03 Apr 2019, 15:11

ncmp your pydoc module contains 3 pydoc files; pydoc.py, pydoc.pyc and pydoc.pyo. Are all 3 needed?

(BTW I did a Rava and renamed your module to 005-pydoc.xzm since it is related to Porteus's python which is in 005-devel.xzm. :punk: )
Ed

Kulle
Warlord
Warlord
Posts: 594
Joined: 28 Jan 2017, 10:39
Distribution: v4.0 64bit Xfce
Location: Berlin

tar2xzm

Post#13 by Kulle » 03 Apr 2019, 15:27

Thank you ncmprhnsbl.
slpkg-3.4.2-x86_64-1_SBo.xzm + pydoc.xzm works.
But pydoc.xzm does not work here:
gespeaker: python-error
Why? what can I do?

User avatar
ncmprhnsbl
DEV Team
DEV Team
Posts: 3924
Joined: 20 Mar 2012, 03:42
Distribution: v5.0-64bit
Location: australia
Contact:

slpkg & tar2xzm > txz2xzm

Post#14 by ncmprhnsbl » 04 Apr 2019, 06:03

Ed_P wrote:
03 Apr 2019, 15:11
ncmp your pydoc module contains 3 pydoc files; pydoc.py, pydoc.pyc and pydoc.pyo. Are all 3 needed?
good question... don't know ... a process of elimination might tell you...
Forum Rules : https://forum.porteus.org/viewtopic.php?f=35&t=44

User avatar
Ed_P
Contributor
Contributor
Posts: 8341
Joined: 06 Feb 2013, 22:12
Distribution: Cinnamon 5.01 ISO
Location: Western NY, USA

slpkg & tar2xzm > txz2xzm

Post#15 by Ed_P » 04 Apr 2019, 23:24

I renamed /usr/lib64/python2.7/pydoc.pyc and pydoc.pyo to pydocX.pyc and pydocX.pyo and slpkg still works. :)
Ed

Post Reply