updated build, install

This commit is contained in:
Dimitris Zlatanidis 2014-08-30 02:19:22 +03:00
parent 9c8c4fda1d
commit d86f91eab9
4 changed files with 174 additions and 79 deletions

View file

@ -1,3 +1,9 @@
Version 1.7.9
29-08-2014
[Feature] - Added extra and pasture packages from official Slackware
tree.
Version 1.7.8 Version 1.7.8
28-08-2014 28-08-2014

227
PKG-INFO
View file

@ -14,19 +14,65 @@ Description: .. image:: https://badge.fury.io/py/slpkg.png
:target: https://pypi.python.org/pypi/slpkg :target: https://pypi.python.org/pypi/slpkg
.. image:: https://pypip.in/license/slpkg/badge.png .. image:: https://pypip.in/license/slpkg/badge.png
:target: https://pypi.python.org/pypi/slpkg :target: https://pypi.python.org/pypi/slpkg
.. image:: https://raw.githubusercontent.com/dslackw/images/master/slpkg/logo.png .. image::
https://raw.githubusercontent.com/dslackw/images/master/slpkg/logo.png
:target: https://github.com/dslackw/slpkg :target: https://github.com/dslackw/slpkg
Slpkg is a terminal multitool in order to easy use `Slackware `Slpkg <https://github.com/dslackw/slpkg>`_ is a terminal multitool in order
<http://www.slackware.com/>`_ to easy use `Slackware <http://www.slackware.com/>`_ packages.
packages.
The tool focuses on slpkg easy and understandable use.
Species are adapted to two repositories:
- SBo - `slackbuilds.org <http://slackbuilds.org/>`_
- Slack - `slackware.com <http://www.slackware.com/>`_
The slpkg cooperate in accordance with the standards of the organization
slackbuilds.org
to build a package,
are also used as the Slackware instructions for installing, upgrading or
removing a
package.
What makes slpkg apart from other tools is the friendliness and the use of
color for the
enhancement packages
that are not installed on the system or is.
Of course one of the big advantages is resolving dependencies packages from
repository
slackbuilds.org and
monitored for upgraded packages.
Of course you wonder how the slpkg is up to date at all times;
It's simple, every time there is a change in ChangeLog.txt before proceeding
to any
execution program looksat whether there is a change in file size and
downloads and updates
the SLACKBUILDS.TXT file.
Also you can install official packages of your favorite distribution directly
from the
official repositories
of Slackware. Even you can check for the official updates and install them.
I should be grateful if you experience the slpkg and share your opinion with
me.
And as we say Slackers, Keep it Simple Stupid!
.. image::
https://raw.githubusercontent.com/dslackw/images/master/slpkg/slpkg_package.png
:target: https://github.com/dslackw/slpkg
Features Features
======== ========
- Build third party packages from source with all dependencies - Build third party packages from source with all dependencies
- Install packages through from official `Slackware <http://www.slackware.com/>`_ mirrors - Install packages through from official `Slackware
- Find and Download packages from `slackbuilds.org <http://slackbuilds.org/>`_ <http://www.slackware.com/>`_ mirrors
- Find and Download packages from `slackbuilds.org
<http://slackbuilds.org/>`_
- Grabs packages from slackbuilds.org in real time - Grabs packages from slackbuilds.org in real time
- Automatic tool build and install packages - Automatic tool build and install packages
- Check if your distribution is up to date - Check if your distribution is up to date
@ -47,16 +93,11 @@ Description: .. image:: https://badge.fury.io/py/slpkg.png
`[CHANGELOG] <https://github.com/dslackw/slpkg/blob/master/CHANGELOG>`_ `[CHANGELOG] <https://github.com/dslackw/slpkg/blob/master/CHANGELOG>`_
Video Tutorial
==============
.. image:: https://raw.githubusercontent.com/dslackw/images/master/slpkg/screenshot-1.png
:target: https://asciinema.org/a/11457
Installation Installation
------------ ------------
Using `pip <https://pip.pypa.io/en/latest/>`_ (best way to have last updates): Using `pip <https://pip.pypa.io/en/latest/>`_ (best way to have last
updates):
.. code-block:: bash .. code-block:: bash
@ -66,23 +107,25 @@ Description: .. image:: https://badge.fury.io/py/slpkg.png
$ pip uninstall slpkg $ pip uninstall slpkg
Using Slackware command: Using Slackware command:
Download `SBo package
<http://slackbuilds.org/repository/14.1/system/slpkg/>`_
Download `SBo package <http://slackbuilds.org/repository/14.1/system/slpkg/>`_ Download binary package from `SourceForge
<https://sourceforge.net/projects/slpkg/>`_
Download binary package from `SourceForge <https://sourceforge.net/projects/slpkg/>`_
Command Line Tool Usage Command Line Tool Usage
----------------------- -----------------------
.. code-block:: bash .. code-block:: bash
usage: slpkg [-h] [-v] [-a script [source ...]] [-l all, sbo, slack, noarch] usage: slpkg [-h] [-v] [-a script [source ...]]
[-c sbo, slack [sbo, slack ...]] [-l all, sbo, slack, noarch] [-c sbo, slack [<upgrade>
[-s sbo, slack [sbo, slack ...]] [-t] [-n] [-i [...]] ...]]
[-u [...]] [-o [...]] [-r [...]] [-f [...]] [-d [...]] [-s sbo, slack [<package> ...]] [-t] [-n] [-i [...]]
[-u [...]] [-o [...]] [-r [...]] [-f [...]] [-d
[...]]
Utility for easy management packages in Slackware Utility for easy management packages in Slackware
@ -93,9 +136,9 @@ Description: .. image:: https://badge.fury.io/py/slpkg.png
auto build package auto build package
-l all, sbo, slack, noarch -l all, sbo, slack, noarch
list of installed packages list of installed packages
-c sbo, slack [sbo, slack ...] -c sbo, slack [<upgrade> ...]
check if your packages is up to date check if your packages is up to date
-s sbo, slack [sbo, slack ...] -s sbo, slack [<package> ...]
download, build & install packages download, build & install packages
-t packages tracking dependencies from SBo -t packages tracking dependencies from SBo
-n view packages from SBo repository -n view packages from SBo repository
@ -118,11 +161,15 @@ Description: .. image:: https://badge.fury.io/py/slpkg.png
$ slpkg -s sbo brasero $ slpkg -s sbo brasero
Building dependency tree...... Done Building dependency tree...... Done
The following packages will be automatically installed or upgraded with new version: The following packages will be automatically installed or upgraded with
new version:
+==============================================================================
| Package Version Arch Repository
+============================================================================== +==============================================================================
| Package Version Arch
Repository
+==============================================================================
Installing: Installing:
brasero 3.11.3 x86_64 SBo brasero 3.11.3 x86_64 SBo
Installing for dependencies: Installing for dependencies:
@ -133,7 +180,8 @@ Description: .. image:: https://badge.fury.io/py/slpkg.png
libunique 1.1.6 x86_64 SBo libunique 1.1.6 x86_64 SBo
Installing summary Installing summary
===============================================================================
===============================================================================
Total 6 packages. Total 6 packages.
6 packages will be installed, 0 allready installed. 6 packages will be installed, 0 allready installed.
@ -141,9 +189,11 @@ Description: .. image:: https://badge.fury.io/py/slpkg.png
. .
. .
. .
+==============================================================================
+==============================================================================
| Installing new package /tmp/brasero-3.11.3-x86_64-1_SBo.tgz | Installing new package /tmp/brasero-3.11.3-x86_64-1_SBo.tgz
+==============================================================================
+==============================================================================
Verifying package brasero-3.11.3-x86_64-1_SBo.tgz. Verifying package brasero-3.11.3-x86_64-1_SBo.tgz.
Installing package brasero-3.11.3-x86_64-1_SBo.tgz: Installing package brasero-3.11.3-x86_64-1_SBo.tgz:
@ -159,7 +209,8 @@ Description: .. image:: https://badge.fury.io/py/slpkg.png
Executing install script for brasero-3.11.3-x86_64-1_SBo.tgz. Executing install script for brasero-3.11.3-x86_64-1_SBo.tgz.
Package brasero-3.11.3-x86_64-1_SBo.tgz installed. Package brasero-3.11.3-x86_64-1_SBo.tgz installed.
Find packages from `Slackware official mirrors <http://mirrors.slackware.com/>`_ Find packages from `Slackware official mirrors
<http://mirrors.slackware.com/>`_
download and install: download and install:
.. code-block:: bash .. code-block:: bash
@ -170,16 +221,22 @@ Description: .. image:: https://badge.fury.io/py/slpkg.png
Reading package lists.............................. Done Reading package lists.............................. Done
+==============================================================================
+==============================================================================
| Package Arch Build Repos Size | Package Arch Build Repos Size
+==============================================================================
+==============================================================================
Installing: Installing:
mozilla-firefox-24.1.0esr x86_64 1 Slack 23524 K mozilla-firefox-24.1.0esr x86_64 1 Slack
mozilla-nss-3.15.2 x86_64 2 Slack 1592 K 23524 K
mozilla-thunderbird-24.1.0 x86_64 1 Slack 24208 K mozilla-nss-3.15.2 x86_64 2 Slack 1592
K
mozilla-thunderbird-24.1.0 x86_64 1 Slack
24208 K
Installing summary Installing summary
===============================================================================
===============================================================================
Total 3 packages. Total 3 packages.
3 packages will be installed, 0 allready installed. 3 packages will be installed, 0 allready installed.
@ -221,9 +278,12 @@ Description: .. image:: https://badge.fury.io/py/slpkg.png
These packages need upgrading: These packages need upgrading:
+==============================================================================
| Package New version Arch Repository +==============================================================================
+============================================================================== | Package New version Arch
Repository
+==============================================================================
Upgrading: Upgrading:
six-1.7.1 1.7.3 x86_64 SBo six-1.7.1 1.7.3 x86_64 SBo
pysetuptools-3.4 3.6 x86_64 SBo pysetuptools-3.4 3.6 x86_64 SBo
@ -235,7 +295,8 @@ Description: .. image:: https://badge.fury.io/py/slpkg.png
colored-1.1.1 1.1.4 x86_64 SBo colored-1.1.1 1.1.4 x86_64 SBo
Installing summary Installing summary
===============================================================================
===============================================================================
Total 8 packages will be upgraded. Total 8 packages will be upgraded.
Would you like to upgrade [Y/n]? Would you like to upgrade [Y/n]?
@ -250,21 +311,27 @@ Description: .. image:: https://badge.fury.io/py/slpkg.png
These packages need upgrading: These packages need upgrading:
+==============================================================================
+==============================================================================
| Package Arch Build Repos Size | Package Arch Build Repos Size
+==============================================================================
+==============================================================================
Upgrading: Upgrading:
dhcpcd-6.0.5 x86_64 3 Slack 92 K dhcpcd-6.0.5 x86_64 3 Slack 92
samba-4.1.11 x86_64 1 Slack 9928 K K
xscreensaver-5.29 x86_64 1 Slack 3896 K samba-4.1.11 x86_64 1 Slack 9928
K
xscreensaver-5.29 x86_64 1 Slack 3896
K
Installing summary Installing summary
===============================================================================
===============================================================================
Total 3 package will be upgrading. Total 3 package will be upgrading.
Need to get 1.70 Mb of archives. Need to get 1.70 Mb of archives.
After this process, 9.51 Mb of additional disk space will be used. After this process, 9.51 Mb of additional disk space will be used.
Would you like to upgrade [Y/y]? Would you like to upgrade [Y/n]?
Find packages from slackbuilds.org: Find packages from slackbuilds.org:
@ -273,14 +340,17 @@ Description: .. image:: https://badge.fury.io/py/slpkg.png
$ slpkg -n bitfighter $ slpkg -n bitfighter
Reading package lists. Done Reading package lists. Done
+===============================================================================
| Package bitfighter --> http://slackbuilds.org/repository/14.1/games/bitfighter/ +===============================================================================
+=============================================================================== | Package bitfighter -->
http://slackbuilds.org/repository/14.1/games/bitfighter/
+===============================================================================
| SlackBuild : bitfighter.tar.gz | SlackBuild : bitfighter.tar.gz
| Source : bitfighter-019c.tar.gz | Sources : bitfighter-019c.tar.gz
| Extra : classic_level_pack.zip
| Requirements : OpenAL, SDL2, speex, libmodplug | Requirements : OpenAL, SDL2, speex, libmodplug
+===============================================================================
+===============================================================================
README View the README file README View the README file
SlackBuild View the SlackBuild file SlackBuild View the SlackBuild file
Info View the Info file Info View the Info file
@ -376,9 +446,11 @@ Description: .. image:: https://badge.fury.io/py/slpkg.png
$ slpkg -u /tmp/termcolor-1.1.0-x86_64-1_SBo.tgz $ slpkg -u /tmp/termcolor-1.1.0-x86_64-1_SBo.tgz
+==============================================================================
+==============================================================================
| Installing new package ./termcolor-1.1.0-x86_64-1_SBo.tgz | Installing new package ./termcolor-1.1.0-x86_64-1_SBo.tgz
+==============================================================================
+==============================================================================
Verifying package termcolor-1.1.0-x86_64-1_SBo.tgz. Verifying package termcolor-1.1.0-x86_64-1_SBo.tgz.
Installing package termcolor-1.1.0-x86_64-1_SBo.tgz: Installing package termcolor-1.1.0-x86_64-1_SBo.tgz:
@ -486,20 +558,27 @@ Description: .. image:: https://badge.fury.io/py/slpkg.png
--> Deleting /usr/doc/termcolor-1.1.0/PKG-INFO --> Deleting /usr/doc/termcolor-1.1.0/PKG-INFO
--> Deleting /usr/doc/termcolor-1.1.0/README.rst --> Deleting /usr/doc/termcolor-1.1.0/README.rst
--> Deleting /usr/doc/termcolor-1.1.0/termcolor.SlackBuild --> Deleting /usr/doc/termcolor-1.1.0/termcolor.SlackBuild
--> Deleting /usr/lib64/python2.7/site-packages/termcolor-1.1.0-py2.7.egg-info --> Deleting
/usr/lib64/python2.7/site-packages/termcolor-1.1.0-py2.7.egg-info
--> Deleting /usr/lib64/python2.7/site-packages/termcolor.py --> Deleting /usr/lib64/python2.7/site-packages/termcolor.py
--> Deleting /usr/lib64/python2.7/site-packages/termcolor.pyc --> Deleting /usr/lib64/python2.7/site-packages/termcolor.pyc
--> Deleting /usr/lib64/python3.3/site-packages/__pycache__/termcolor.cpython-33.pyc --> Deleting
--> Deleting /usr/lib64/python3.3/site-packages/termcolor-1.1.0-py3.3.egg-info /usr/lib64/python3.3/site-packages/__pycache__/termcolor.cpython-33.pyc
--> Deleting
/usr/lib64/python3.3/site-packages/termcolor-1.1.0-py3.3.egg-info
--> Deleting /usr/lib64/python3.3/site-packages/termcolor.py --> Deleting /usr/lib64/python3.3/site-packages/termcolor.py
--> Deleting empty directory /usr/lib64/python3.3/site-packages/__pycache__/ --> Deleting empty directory
WARNING: Unique directory /usr/lib64/python3.3/site-packages/ contains new files /usr/lib64/python3.3/site-packages/__pycache__/
WARNING: Unique directory /usr/lib64/python3.3/site-packages/ contains
new files
WARNING: Unique directory /usr/lib64/python3.3/ contains new files WARNING: Unique directory /usr/lib64/python3.3/ contains new files
--> Deleting empty directory /usr/doc/termcolor-1.1.0/ --> Deleting empty directory /usr/doc/termcolor-1.1.0/
+==============================================================================
+==============================================================================
| Package: termcolor removed | Package: termcolor removed
+==============================================================================
+==============================================================================
$ slpkg -f termcolor lua rar $ slpkg -f termcolor lua rar
@ -522,35 +601,41 @@ Description: .. image:: https://badge.fury.io/py/slpkg.png
Are you sure to remove 1 package [Y/n]? y Are you sure to remove 1 package [Y/n]? y
+==============================================================================
+==============================================================================
| Found dependencies for package Flask: | Found dependencies for package Flask:
+==============================================================================
+==============================================================================
| pysetuptools | pysetuptools
| MarkupSafe | MarkupSafe
| itsdangerous | itsdangerous
| Jinja2 | Jinja2
| werkzeug | werkzeug
+==============================================================================
+==============================================================================
Remove dependencies (maybe used by other packages) [Y/n]? y Remove dependencies (maybe used by other packages) [Y/n]? y
. .
. .
. .
+==============================================================================
+==============================================================================
| Package Flask removed | Package Flask removed
| Package pysetuptools removed | Package pysetuptools removed
| Package MarkupSafe removed | Package MarkupSafe removed
| Package itsdangerous removed | Package itsdangerous removed
| Package Jinja2 removed | Package Jinja2 removed
| Package werkzeug removed | Package werkzeug removed
+==============================================================================
+==============================================================================
Man page it is available for full support: Man page it is available for full support:
.. code-block:: bash .. code-block:: bash
$ man slpkg $ man slpkg
Keywords: slackware, slpkg, slackpkg, sbopkg, package, build, install, yum, apt-get, linux, unix Keywords: slackware, slpkg, slackpkg, sbopkg, package, build, install, yum, apt-get,
linux, unix
Classifier: Development Status :: 5 - Production/Stable Classifier: Development Status :: 5 - Production/Stable
Classifier: Environment :: Console Classifier: Environment :: Console
Classifier: License :: OSI Approved :: GNU General Public License v3 (GPLv3) Classifier: License :: OSI Approved :: GNU General Public License v3 (GPLv3)

View file

@ -27,7 +27,7 @@ import shutil
import tarfile import tarfile
import subprocess import subprocess
from slpkg.messages import pkg_not_found from messages import pkg_not_found
def build_package(script, sources, path): def build_package(script, sources, path):
''' '''
@ -40,6 +40,7 @@ def build_package(script, sources, path):
tar.close() tar.close()
for src in sources: for src in sources:
shutil.copy2(src, prgnam) shutil.copy2(src, prgnam)
os.remove(path + src)
os.chdir(path + prgnam) os.chdir(path + prgnam)
subprocess.call("chmod +x {0}.SlackBuild".format(prgnam), shell=True) subprocess.call("chmod +x {0}.SlackBuild".format(prgnam), shell=True)
subprocess.call("./{0}.SlackBuild".format(prgnam), shell=True) subprocess.call("./{0}.SlackBuild".format(prgnam), shell=True)

View file

@ -26,12 +26,12 @@ import sys
import time import time
import subprocess import subprocess
from slpkg.colors import colors from colors import colors
from slpkg.url_read import url_read from url_read import url_read
from slpkg.messages import pkg_not_found, template from messages import pkg_not_found, template
from slpkg.__metadata__ import slpkg_tmp, pkg_path, slack_archs from __metadata__ import slpkg_tmp, pkg_path, slack_archs
from slpkg.pkg.manager import pkg_upgrade, pkg_reinstall from pkg.manager import pkg_upgrade, pkg_reinstall
from mirrors import mirrors from mirrors import mirrors
@ -53,9 +53,12 @@ def install(slack_pkg):
colors.CYAN, slack_pkg, colors.ENDC)) colors.CYAN, slack_pkg, colors.ENDC))
sys.stdout.write ("Reading package lists ...") sys.stdout.write ("Reading package lists ...")
sys.stdout.flush() sys.stdout.flush()
PACKAGE_TXT = url_read(mirrors(name="PACKAGES.TXT", location="")) PACKAGES = url_read(mirrors(name="PACKAGES.TXT", location=""))
EXTRA = url_read(mirrors(name="PACKAGES.TXT", location="extra/"))
PASTURE = url_read(mirrors(name="PACKAGES.TXT", location="pasture/"))
PACKAGES_TXT = PACKAGES + EXTRA + PASTURE
index, toolbar_width = 0, 800 index, toolbar_width = 0, 800
for line in PACKAGE_TXT.splitlines(): for line in PACKAGES_TXT.splitlines():
index += 1 index += 1
if index == toolbar_width: if index == toolbar_width:
sys.stdout.write(".") sys.stdout.write(".")