mirror of
ssh://git.janware.com/srv/git/janware/proj/jw-pkg
synced 2026-01-15 12:03:31 +01:00
projects.py pkg-requires: Add --dont-strip-revision
Add --dont-strip-revision option to projects.py pkg-requires Sadly, Debian dpkg doesn't install a package with dependency somepkg = 1.2.3, if somepkg-1.2.3-10 is installed. To work around this, VERSION in project.conf files is now always interpreted as VERSION-REVISION Signed-off-by: Jan Lindemann <jan@janware.com>
This commit is contained in:
parent
2d6da0e694
commit
b79d89f37d
2 changed files with 10 additions and 3 deletions
|
|
@ -350,6 +350,8 @@ def cmd_pkg_requires(args_):
|
|||
parser.add_argument('--vendor', '-V', nargs='?', default='jw', help='Package Vendor')
|
||||
parser.add_argument('flavour', help='Flavour')
|
||||
parser.add_argument('module', nargs='*', help='Modules')
|
||||
parser.add_argument('--dont-strip-revision', action='store_true',
|
||||
default=False, help='Always treat VERSION macro as VERSION-REVISION')
|
||||
args=parser.parse_args(args_)
|
||||
#debug('flavour = ', args.flavour, ', vendor = ', args.vendor)
|
||||
r = []
|
||||
|
|
@ -367,7 +369,10 @@ def cmd_pkg_requires(args_):
|
|||
version = get_value(dep_project, 'version', '')
|
||||
version_pattern=re.compile("[0-9-.]*")
|
||||
if dep[2] == 'VERSION':
|
||||
dep[2] = version.split('-')[0]
|
||||
if args.dont_strip_revision:
|
||||
dep[2] = version
|
||||
else:
|
||||
dep[2] = version.split('-')[0]
|
||||
elif dep[2] == 'VERSION-REVISION':
|
||||
dep[2] = version
|
||||
elif version_pattern.match(dep[2]):
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue