jhbuild r2521 - in trunk: . doc/C jhbuild jhbuild/commands
- From: fpeters svn gnome org
- To: svn-commits-list gnome org
- Subject: jhbuild r2521 - in trunk: . doc/C jhbuild jhbuild/commands
- Date: Sat, 15 Nov 2008 19:06:38 +0000 (UTC)
Author: fpeters
Date: Sat Nov 15 19:06:38 2008
New Revision: 2521
URL: http://svn.gnome.org/viewvc/jhbuild?rev=2521&view=rev
Log:
* jhbuild/commands/base.py, jhbuild/config.py, jhbuild/moduleset.py,
jhbuild/defaults.jhbuildrc, doc/C/jhbuild.xml: added a new
ignore-suggests option to build, update and list commands; as well as a
new ignore_suggests configuration variable.
Modified:
trunk/ChangeLog
trunk/doc/C/jhbuild.xml
trunk/jhbuild/commands/base.py
trunk/jhbuild/config.py
trunk/jhbuild/defaults.jhbuildrc
trunk/jhbuild/moduleset.py
Modified: trunk/doc/C/jhbuild.xml
==============================================================================
--- trunk/doc/C/jhbuild.xml (original)
+++ trunk/doc/C/jhbuild.xml Sat Nov 15 19:06:38 2008
@@ -528,6 +528,7 @@
<arg>--clean</arg>
<arg>--dist</arg>
<arg>--distcheck</arg>
+ <arg>--ignore-suggests</arg>
<arg>--no-network</arg>
<arg rep="repeat">--skip=<replaceable>module</replaceable></arg>
<arg>--start-at=<replaceable>module</replaceable></arg>
@@ -583,6 +584,13 @@
</varlistentry>
<varlistentry>
+ <term><option>--ignore-suggests</option></term>
+ <listitem>
+ <simpara>Do not build soft dependencies.</simpara>
+ </listitem>
+ </varlistentry>
+
+ <varlistentry>
<term><option>-n</option>, <option>--no-network</option></term>
<listitem>
<simpara>Do not access the network when building modules.
@@ -860,6 +868,7 @@
<arg>-r</arg>
<arg>-s</arg>
<arg>--tags=<replaceable>tags</replaceable></arg>
+ <arg>--ignore-suggests</arg>
<arg>--list-optional-modules</arg>
<arg rep="repeat">module</arg>
</cmdsynopsis>
@@ -910,11 +919,18 @@
<term><option>--list-optional-modules</option></term>
<listitem>
<simpara>Some modules, listed as optional dependencies, may not be
- required to get to the target module, this option inncludes them
+ required to get to the target module, this option includes them
nevertheless.</simpara>
</listitem>
</varlistentry>
+ <varlistentry>
+ <term><option>--ignore-suggests</option></term>
+ <listitem>
+ <simpara>Do not list soft dependencies.</simpara>
+ </listitem>
+ </varlistentry>
+
</variablelist>
</section>
@@ -1085,13 +1101,15 @@
<arg rep="repeat">--skip=<replaceable>module</replaceable></arg>
<arg>--start-at=<replaceable>module</replaceable></arg>
<arg>--tags=<replaceable>tags</replaceable></arg>
+ <arg>--ignore-suggests</arg>
<arg>-D <replaceable>date</replaceable></arg>
<arg rep="repeat">module</arg>
</cmdsynopsis>
<para>The <option>--skip</option>, <option>--start-at</option>,
- <option>--tags</option> and <option>-D</option> options are processed the
- same as for <command>build</command>.</para>
+ <option>--tags</option>, <option>--ignore-suggests</option> and
+ <option>-D</option> options are processed the same as for
+ <command>build</command>.</para>
</section>
@@ -1268,6 +1286,15 @@
</listitem>
</varlistentry>
<varlistentry>
+ <term><varname>ignore_suggests</varname></term>
+ <listitem>
+ <simpara>A boolean value specifying whether to ignore
+ soft dependencies when calculating the dependency tree.
+ Defaults to <constant>False</constant>.
+ </listitem>
+ </varlistentry>
+ <varlistentry>
+ <varlistentry>
<term><varname>interact</varname></term>
<listitem>
<simpara>A boolean value specifying whether to interact
Modified: trunk/jhbuild/commands/base.py
==============================================================================
--- trunk/jhbuild/commands/base.py (original)
+++ trunk/jhbuild/commands/base.py Sat Nov 15 19:06:38 2008
@@ -59,6 +59,9 @@
make_option('-D', metavar='DATE-SPEC',
action='store', dest='sticky_date', default=None,
help=_('set a sticky date when checking out modules')),
+ make_option('--ignore-suggests',
+ action='store_true', dest='ignore_suggests', default=False,
+ help=_('ignore all soft-dependencies')),
])
def run(self, config, options, args):
@@ -68,10 +71,13 @@
config.tags += item.split(',')
if options.sticky_date is not None:
config.sticky_date = options.sticky_date
+ if options.ignore_suggests:
+ config.ignore_suggests = True
module_set = jhbuild.moduleset.load(config)
module_list = module_set.get_module_list(args or config.modules,
- config.skip, tags = config.tags)
+ config.skip, tags=config.tags,
+ ignore_suggests=config.ignore_suggests)
# remove modules up to startat
if options.startat:
while module_list and module_list[0].name != options.startat:
@@ -176,6 +182,9 @@
make_option('--distcheck',
action='store_true', dest='distcheck', default=False,
help=_('run make distcheck after building')),
+ make_option('--ignore-suggests',
+ action='store_true', dest='ignore_suggests', default=False,
+ help=_('ignore all soft-dependencies')),
make_option('-n', '--no-network',
action='store_true', dest='nonetwork', default=False,
help=_('skip version control update')),
@@ -221,6 +230,8 @@
config.makeclean = True
if options.dist:
config.makedist = True
+ if options.ignore_suggests:
+ config.ignore_suggests = True
if options.distcheck:
config.makedistcheck = True
if options.nonetwork:
@@ -250,7 +261,8 @@
module_set = jhbuild.moduleset.load(config)
module_list = module_set.get_module_list(args or config.modules,
config.skip, tags = config.tags,
- include_optional_modules = options.build_optional_modules)
+ include_optional_modules=options.build_optional_modules,
+ ignore_suggests=config.ignore_suggests)
# remove modules up to startat
if options.startat:
while module_list and module_list[0].name != options.startat:
@@ -429,6 +441,9 @@
make_option('--tags',
action='append', dest='tags', default=[],
help=_('build only modules with the given tags')),
+ make_option('--ignore-suggests',
+ action='store_true', dest='ignore_suggests', default=False,
+ help=_('ignore all soft-dependencies')),
make_option('--list-optional-modules',
action='store_true', dest='list_optional_modules', default=False,
help=_('also list soft-dependencies that could be skipped')),
@@ -442,13 +457,16 @@
config.skip += item.split(',')
for item in options.tags:
config.tags += item.split(',')
+ if options.ignore_suggests:
+ config.ignore_suggests = True
module_set = jhbuild.moduleset.load(config)
if options.list_all_modules:
module_list = module_set.modules.values()
else:
module_list = module_set.get_module_list(args or config.modules,
config.skip, tags = config.tags,
- include_optional_modules = options.list_optional_modules)
+ include_optional_modules = options.list_optional_modules,
+ ignore_suggests=config.ignore_suggests)
for mod in module_list:
if options.show_rev:
Modified: trunk/jhbuild/config.py
==============================================================================
--- trunk/jhbuild/config.py (original)
+++ trunk/jhbuild/config.py Sat Nov 15 19:06:38 2008
@@ -46,7 +46,7 @@
'quiet_mode', 'progress_bar', 'module_extra_env',
'jhbuildbot_master', 'jhbuildbot_slavename', 'jhbuildbot_password',
'jhbuildbot_svn_commits_box',
- 'use_local_modulesets',
+ 'use_local_modulesets', 'ignore_suggests',
'mirror_policy', 'module_mirror_policy',
]
Modified: trunk/jhbuild/defaults.jhbuildrc
==============================================================================
--- trunk/jhbuild/defaults.jhbuildrc (original)
+++ trunk/jhbuild/defaults.jhbuildrc Sat Nov 15 19:06:38 2008
@@ -138,3 +138,6 @@
# whether to use a local copy of modulesets (instead of fetching them from svn)
use_local_modulesets = False
+
+# whether to ignore soft dependencies
+ignore_suggests = False
Modified: trunk/jhbuild/moduleset.py
==============================================================================
--- trunk/jhbuild/moduleset.py (original)
+++ trunk/jhbuild/moduleset.py Sat Nov 15 19:06:38 2008
@@ -59,7 +59,8 @@
raise KeyError(module_name)
def get_module_list(self, seed, skip=[], tags=[], ignore_cycles=False,
- include_optional_modules=False, ignore_missing=False):
+ ignore_suggests=False, include_optional_modules=False,
+ ignore_missing=False):
'''gets a list of module objects (in correct dependency order)
needed to build the modules in the seed list'''
@@ -89,13 +90,14 @@
if not depmod in all_modules:
all_modules.append(depmod)
- # suggests can be ignored if not in moduleset
- for modname in all_modules[i].suggests:
- depmod = self.modules.get(modname)
- if not depmod:
- continue
- if not depmod in all_modules:
- all_modules.append(depmod)
+ if not ignore_suggests:
+ # suggests can be ignored if not in moduleset
+ for modname in all_modules[i].suggests:
+ depmod = self.modules.get(modname)
+ if not depmod:
+ continue
+ if not depmod in all_modules:
+ all_modules.append(depmod)
i += 1
# 2nd: order them, raise an exception on hard dependency cycle, ignore
@@ -131,11 +133,12 @@
for modname in module.dependencies:
depmod = self.modules[modname]
order([self.modules[x] for x in depmod.dependencies], depmod, mode)
- for modname in module.suggests:
- depmod = self.modules.get(modname)
- if not depmod:
- continue
- order([self.modules[x] for x in depmod.dependencies], depmod, 'suggests')
+ if not ignore_suggests:
+ for modname in module.suggests:
+ depmod = self.modules.get(modname)
+ if not depmod:
+ continue
+ order([self.modules[x] for x in depmod.dependencies], depmod, 'suggests')
extra_afters = []
for modname in module.after:
depmod = self.modules.get(modname)
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]