summaryrefslogtreecommitdiffstats
path: root/opkg.py
AgeCommit message (Collapse)Author
2017-10-06opkg.py/opkg-make-index: Add option to include all fieldsJeffrey Pautler
If the -f option is enabled, opkg-make-index will include user-defined fields in the package index rather than discarding them. This change is motivated by the fact that opkg now has support for user-defined fields in the package index. Signed-off-by: Jeffrey Pautler <jeffrey.pautler@ni.com> Signed-off-by: Alejandro del Castillo <alejandro.delcastillo@ni.com>
2017-10-06opkg.py: Remove reformatting of description fieldJeffrey Pautler
The Debian Policy Manual describes the format of the description field. This includes information about how lines might be wrapped by programs displaying this information, how to mark lines to not be wrapped, how to mark a line as blank, and how leading spaces on a multi-line description might be deleted. By reformatting the description field in opkg.py, we are breaking many of these behaviors and taking control of formatting away from the author of the control file. Instead, we should simply copy the description field with no reformatting. Signed-off-by: Jeffrey Pautler <jeffrey.pautler@ni.com> Signed-off-by: Alejandro del Castillo <alejandro.delcastillo@ni.com>
2017-10-03opkg.py: Fix run-time error in call to ArFileJeffrey Pautler
Signed-off-by: Jeffrey Pautler <jeffrey.pautler@ni.com> Signed-off-by: Alejandro del Castillo <alejandro.delcastillo@ni.com>
2017-07-10opkg.py/__init__: Compatible for ipk which outer is tar朱穆穆
Signed-off-by: Zhu Mumu <zhumumu@gmail.com> Signed-off-by: Alejandro del Castillo <alejandro.delcastillo@ni.com>
2016-12-30Added support to generate index file with multiple version per packagedesmond
Using the -a option with opkg-make-index, you can now generate an index file which will list multiple version of the same package. Added since opkg now supports specifying version of package. Signed-off-by: desmond <desmond.correia@prolucid.ca> Signed-off-by: Alejandro del Castillo <alejandro.delcastillo@ni.com>
2016-10-07opkg-make-index: print summary on it's own line0.3.4Alejandro del Castillo
The Description field on the Packages file doesn't follow the same format used on the Control file. It is incorrectly processing the summary line (it treats it as part of the longer description). Add code to print the summary line on it's own. Fixes issue 9238 Signed-off-by: Alejandro del Castillo <alejandro.delcastillo@ni.com>
2016-06-01opkg.py/write_packages_file: call __str__ instead of __repr__Alejandro del Castillo
Commit b9eec00a67f13ad9f9526caf591578b40d73a391 correctly renamed __repr__to __str__. A call site in write_packages_file was missed. Signed-off-by: Alejandro del Castillo <alejandro.delcastillo@ni.com>
2016-06-01migrate to python 3Alejandro del Castillo
General fixes * Add __future__ imports * Use print function instead of print statement * Use new style classes * Iterate over list, instead of over object.keys() * Use six.iteritems instead of iteritems() opkg.py: * Add conditional to decode string if needed in Package:read_control arfile.py * Add seekable method to FileSection class (needed by tarfile) Signed-off-by: Alejandro del Castillo <alejandro.delcastillo@ni.com>
2014-05-06opkg.py: Allow filename to be a relative pathPaul Barker
In order to support package files residing in a different directory to the 'Packages' index file, we need to allow filename entries in the index to be relative paths. In order to not break existing code, filename remains the basename of fn by default. However, if the new relpath argument is set then filename is the path of fn relative to relpath. Signed-off-by: Paul Barker <paul@paulbarker.me.uk>
2012-10-24opkg.py/opkg-build: fix creation of tar archivesSteffen Sledz
Since openSUSE 12.2 the installed tar uses posix instead of gnu encoding by default. This format is not fully supported by opkg and results in ipk packages not installable at the target. Collected errors: * get_header_tar: Unknown typeflag: 0x78: Success. * get_header_tar: Unknown typeflag: 0x78: Success. * get_header_tar: Unknown typeflag: 0x78: Success. * extract_archive: Don't know how to handle /var/lib/opkg/tmp/opkg-mg997m/chicken-bin-fGRvr4/PaxHeaders.17512/.: No such file or directory. * get_header_tar: Unknown typeflag: 0x78: No such file or directory. * get_header_tar: Unknown typeflag: 0x78: No such file or directory. ... Signed-off-by: Steffen Sledz <sledz@dresearch-fe.de> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-07-19opkg.py: Add check_output defintion so it works on python 2.6Richard Purdie
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-04-26opkg.py: get_file_list_dir: fix empty output from find if package disappersMartin Jansa
* if .ipk disappers before parsing Packages.old then it's fine and it's not used at all * but if it disappers between parsing Packages.old and generating Packages.filelist then it would fail to split() empty output Signed-off-by: Martin Jansa <Martin.Jansa@gmail.com>
2012-04-26opkg-make-index: generate complete filelistMartin Jansa
* when '-l Packages.filelist' option is used together with '-r Packages.old', then only 'new' packages are processed to create Packages.filelist packages found in Packages.old doesn't have fn set so get_file_list() was returning empty * now added get_file_list_dir() looks for filename in pkg_dir and if it finds correct .ipk file it will use that to read its filelist, but it also means that it will always unpack *all* Packages - very slow. * it would be nice to add new param for Packages.filelist.old and then filter filelist for packages used from Packages.old and merge it together with new Packages.filelist, but that's more difficult because of files structure. Signed-off-by: Martin Jansa <Martin.Jansa@gmail.com>
2012-04-26opkg.py: improve test so it prints temporary control file with long ↵Martin Jansa
description and then reads it back Signed-off-by: Martin Jansa <Martin.Jansa@gmail.com>
2012-04-26opkg.py: use textwrap for description writingMartin Jansa
* description field in oe-core sometimes has extra line-feeds and is long * extra line-feeds breaks read_control, because empty line means next Package * long descriptions should be wrapped and properly indented, so they are parsed back properly Signed-off-by: Martin Jansa <Martin.Jansa@gmail.com>
2012-04-26opkg.py: fix write_package when called from main testMartin Jansa
* there is no self.meta_dir before self._setup_scratch_area * control file needs to be closed before packing it with tar, otherwise it could be empty Signed-off-by: Martin Jansa <Martin.Jansa@gmail.com>
2012-04-26opkg.py: computeFileMD5 only when we have fn, otherwise fails to read None fileMartin Jansa
Signed-off-by: Martin Jansa <Martin.Jansa@gmail.com>
2012-04-26opkg.py: cast lines from controlfile as stringMartin Jansa
Signed-off-by: Martin Jansa <Martin.Jansa@gmail.com>
2012-04-26opkg-make-index: don't use stdout for Packages output and use __str__ ↵Martin Jansa
instead of __repr__ Signed-off-by: Martin Jansa <Martin.Jansa@gmail.com>
2012-04-26opkg.py: catch TypeError when reading control file, to show which one is failingMartin Jansa
Signed-off-by: Martin Jansa <Martin.Jansa@gmail.com>
2012-04-26opkg.py: use string funtcions directly on string variableMartin Jansa
Signed-off-by: Martin Jansa <Martin.Jansa@gmail.com>
2012-04-262to3: exception handling fixesMartin Jansa
Signed-off-by: Martin Jansa <Martin.Jansa@gmail.com>
2012-04-262to3: dictionary fixesMartin Jansa
Signed-off-by: Martin Jansa <Martin.Jansa@gmail.com>
2012-04-262to3: print fixesMartin Jansa
Signed-off-by: Martin Jansa <Martin.Jansa@gmail.com>
2012-04-262to3: use subprocess instead of commandsMartin Jansa
Signed-off-by: Martin Jansa <Martin.Jansa@gmail.com>
2012-04-26opkg.py, arfile.py: report which file has wrong format and use the same testMartin Jansa
Signed-off-by: Martin Jansa <Martin.Jansa@gmail.com>
2012-04-26opkg.py: use hashlib instead of old md5 moduleMartin Jansa
Signed-off-by: Martin Jansa <Martin.Jansa@gmail.com>
2012-04-26opkg.py: Add knowledge about License field in ipk headersKhem Raj
Signed-off-by: Khem Raj <raj.khem@gmail.com> Signed-off-by: Martin Jansa <Martin.Jansa@gmail.com>
2008-08-12[opkg-util] adding Size support when creating PackagesTick Chen
2008-08-07[opkg-utils] Print the "Tags" field. Patch from OE and authored by John LeeHolger 'Zecke' Freyther
2008-07-28make ipk as default opk as an optionTick Chen
2008-07-28opkg-util make .opk as the default file extension Tick Chen
"opkg-build -i ..." means creating .ipk file for backward support
2008-07-18[opkg-utils] Add opkg-utils to the repository courtsey Richard Purdie of ↵Holger 'Zecke' Freyther
o-hand.com I've attached a first attempt at this, its basically a small set of helper scripts which OE/Poky use when working with ipks. I've applied the various OE improvements and tweaks and removed a ton of cruft we don't need.