aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAvatar Ciaran McCreesh <ciaran.mccreesh@googlemail.com> 2008-12-06 20:28:13 +0000
committerAvatar Ciaran McCreesh <ciaran.mccreesh@googlemail.com> 2008-12-06 20:28:13 +0000
commitc83a35329debb115d0f44d6132833ec71a176b52 (patch)
tree5b19eb96e74cee5f4bde9fbd73565b7dc121897b
parentaf59deeafa26271274a80a4f7ea9bed48beb28e1 (diff)
downloadpaludis-c83a35329debb115d0f44d6132833ec71a176b52.tar.gz
paludis-c83a35329debb115d0f44d6132833ec71a176b52.tar.xz
more dead sr
-rw-r--r--doc/api/cplusplus/examples/example_dep_spec.cc2
-rw-r--r--paludis/dep_list.cc6
-rw-r--r--paludis/dep_spec.cc16
-rw-r--r--paludis/elike_package_dep_spec.cc8
-rw-r--r--paludis/files.m42
-rw-r--r--paludis/install_task.cc4
-rw-r--r--paludis/match_package.cc4
-rw-r--r--paludis/range_rewriter.cc8
-rw-r--r--paludis/report_task.cc7
-rw-r--r--paludis/repositories/cran/package_dep_spec.cc11
-rw-r--r--paludis/repositories/e/e_repository_sets.cc8
-rw-r--r--paludis/repositories/e/vdb_repository.cc2
-rw-r--r--paludis/repositories/virtuals/package_id.cc5
-rw-r--r--paludis/user_dep_spec.cc4
-rw-r--r--paludis/user_dep_spec_TEST.cc2
-rw-r--r--paludis/version_requirements.cc7
-rw-r--r--paludis/version_requirements.hh27
-rw-r--r--paludis/version_requirements.sr29
-rw-r--r--python/version_requirements.cc34
-rwxr-xr-xpython/version_requirements_TEST.py8
-rw-r--r--ruby/dep_spec.cc4
-rw-r--r--src/clients/reconcilio/fix_linkage.cc5
22 files changed, 114 insertions, 89 deletions
diff --git a/doc/api/cplusplus/examples/example_dep_spec.cc b/doc/api/cplusplus/examples/example_dep_spec.cc
index aaeb712..c52f72b 100644
--- a/doc/api/cplusplus/examples/example_dep_spec.cc
+++ b/doc/api/cplusplus/examples/example_dep_spec.cc
@@ -94,7 +94,7 @@ int main(int argc, char * argv[])
}
}
- cout << r->version_operator << r->version_spec;
+ cout << r->version_operator() << r->version_spec();
need_join = true;
}
cout << endl;
diff --git a/paludis/dep_list.cc b/paludis/dep_list.cc
index 4eab9a1..f3af735 100644
--- a/paludis/dep_list.cc
+++ b/paludis/dep_list.cc
@@ -54,6 +54,7 @@
#include <paludis/util/visitor-impl.hh>
#include <paludis/util/wrapped_forward_iterator-impl.hh>
#include <paludis/util/hashes.hh>
+#include <paludis/util/make_named_values.hh>
#include <algorithm>
#include <functional>
@@ -1122,7 +1123,10 @@ DepList::add_package(const std::tr1::shared_ptr<const PackageID> & p, const std:
{
std::tr1::shared_ptr<PackageDepSpec> pp(new PackageDepSpec(make_package_dep_spec()
.package(*(*i)->package_ptr())
- .version_requirement(VersionRequirement(vo_equal, p->version()))));
+ .version_requirement(make_named_values<VersionRequirement>(
+ value_for<n::version_operator>(vo_equal),
+ value_for<n::version_spec>(p->version())))
+ ));
std::pair<MergeListIndex::iterator, MergeListIndex::iterator> z;
if (pp->package_ptr())
diff --git a/paludis/dep_spec.cc b/paludis/dep_spec.cc
index 720eb31..f656226 100644
--- a/paludis/dep_spec.cc
+++ b/paludis/dep_spec.cc
@@ -886,10 +886,10 @@ namespace
}
else if (next(version_requirements_ptr()->begin()) == version_requirements_ptr()->end())
{
- if (version_requirements_ptr()->begin()->version_operator == vo_equal_star)
+ if (version_requirements_ptr()->begin()->version_operator() == vo_equal_star)
s << "=";
else
- s << version_requirements_ptr()->begin()->version_operator;
+ s << version_requirements_ptr()->begin()->version_operator();
}
}
@@ -917,8 +917,8 @@ namespace
}
else if (next(version_requirements_ptr()->begin()) == version_requirements_ptr()->end())
{
- s << "-" << version_requirements_ptr()->begin()->version_spec;
- if (version_requirements_ptr()->begin()->version_operator == vo_equal_star)
+ s << "-" << version_requirements_ptr()->begin()->version_spec();
+ if (version_requirements_ptr()->begin()->version_operator() == vo_equal_star)
s << "*";
}
}
@@ -1014,14 +1014,14 @@ namespace
} while (false);
}
- if (r->version_operator == vo_equal_star)
+ if (r->version_operator() == vo_equal_star)
s << "=";
else
- s << r->version_operator;
+ s << r->version_operator();
- s << r->version_spec;
+ s << r->version_spec();
- if (r->version_operator == vo_equal_star)
+ if (r->version_operator() == vo_equal_star)
s << "*";
need_op = true;
diff --git a/paludis/elike_package_dep_spec.cc b/paludis/elike_package_dep_spec.cc
index 3c5e3d2..9edbc56 100644
--- a/paludis/elike_package_dep_spec.cc
+++ b/paludis/elike_package_dep_spec.cc
@@ -172,7 +172,9 @@ paludis::elike_remove_trailing_square_bracket_if_exists(std::string & s, Partial
}
VersionSpec vs(ver);
- result.version_requirement(VersionRequirement(vop, vs));
+ result.version_requirement(make_named_values<VersionRequirement>(
+ value_for<n::version_operator>(vop),
+ value_for<n::version_spec>(vs)));
had_bracket_version_requirements = true;
}
}
@@ -398,7 +400,9 @@ paludis::elike_get_remove_trailing_version(std::string & s)
void
paludis::elike_add_version_requirement(const VersionOperator & op, const VersionSpec & spec, PartiallyMadePackageDepSpec & result)
{
- result.version_requirement(VersionRequirement(op, spec));
+ result.version_requirement(make_named_values<VersionRequirement>(
+ value_for<n::version_operator>(op),
+ value_for<n::version_spec>(spec)));
}
void
diff --git a/paludis/files.m4 b/paludis/files.m4
index 4d5c85d..244136c 100644
--- a/paludis/files.m4
+++ b/paludis/files.m4
@@ -82,6 +82,6 @@ add(`uninstall_task', `hh', `cc')
add(`unmerger', `hh', `cc')
add(`user_dep_spec', `hh', `cc', `se', `fwd', `test')
add(`version_operator', `hh', `cc', `fwd', `se', `test')
-add(`version_requirements', `hh', `cc', `fwd', `sr')
+add(`version_requirements', `hh', `cc', `fwd')
add(`version_spec', `hh', `cc', `se', `fwd', `test')
diff --git a/paludis/install_task.cc b/paludis/install_task.cc
index 0c6b3e5..a81e065 100644
--- a/paludis/install_task.cc
+++ b/paludis/install_task.cc
@@ -472,7 +472,9 @@ InstallTask::_add_package_id(const std::tr1::shared_ptr<const PackageID> & targe
std::tr1::shared_ptr<PackageDepSpec> spec(new PackageDepSpec(make_package_dep_spec()
.package(target->name())
- .version_requirement(VersionRequirement(vo_equal, target->version()))
+ .version_requirement(make_named_values<VersionRequirement>(
+ value_for<n::version_operator>(vo_equal),
+ value_for<n::version_spec>(target->version())))
.slot_requirement(make_shared_ptr(new UserSlotExactRequirement(target->slot())))
.in_repository(target->repository()->name())));
diff --git a/paludis/match_package.cc b/paludis/match_package.cc
index 255143a..e3f3609 100644
--- a/paludis/match_package.cc
+++ b/paludis/match_package.cc
@@ -95,7 +95,7 @@ paludis::match_package(
case vr_and:
for (VersionRequirements::ConstIterator r(spec.version_requirements_ptr()->begin()),
r_end(spec.version_requirements_ptr()->end()) ; r != r_end ; ++r)
- if (! r->version_operator.as_version_spec_comparator()(entry.version(), r->version_spec))
+ if (! r->version_operator().as_version_spec_comparator()(entry.version(), r->version_spec()))
return false;
break;
@@ -104,7 +104,7 @@ paludis::match_package(
bool matched(false);
for (VersionRequirements::ConstIterator r(spec.version_requirements_ptr()->begin()),
r_end(spec.version_requirements_ptr()->end()) ; r != r_end ; ++r)
- if (r->version_operator.as_version_spec_comparator()(entry.version(), r->version_spec))
+ if (r->version_operator().as_version_spec_comparator()(entry.version(), r->version_spec()))
{
matched = true;
break;
diff --git a/paludis/range_rewriter.cc b/paludis/range_rewriter.cc
index b14c48f..84eb030 100644
--- a/paludis/range_rewriter.cc
+++ b/paludis/range_rewriter.cc
@@ -74,14 +74,14 @@ namespace
} while (false);
}
- if (r->version_operator == vo_equal_star)
+ if (r->version_operator() == vo_equal_star)
s << "=";
else
- s << r->version_operator;
+ s << r->version_operator();
- s << r->version_spec;
+ s << r->version_spec();
- if (r->version_operator == vo_equal_star)
+ if (r->version_operator() == vo_equal_star)
s << "*";
need_op = true;
diff --git a/paludis/report_task.cc b/paludis/report_task.cc
index 9204cc4..a30a316 100644
--- a/paludis/report_task.cc
+++ b/paludis/report_task.cc
@@ -17,7 +17,7 @@
* Place, Suite 330, Boston, MA 02111-1307 USA
*/
-#include "report_task.hh"
+#include <paludis/report_task.hh>
#include <paludis/util/log.hh>
#include <paludis/uninstall_list.hh>
#include <paludis/environment.hh>
@@ -32,6 +32,7 @@
#include <paludis/util/visitor-impl.hh>
#include <paludis/util/visitor_cast.hh>
#include <paludis/util/set.hh>
+#include <paludis/util/make_named_values.hh>
#include <paludis/package_database.hh>
#include <paludis/version_requirements.hh>
#include <set>
@@ -210,7 +211,9 @@ ReportTask::execute()
(generator::InRepository(RepositoryName(*o)) &
generator::Matches(make_package_dep_spec()
.package((*v)->name())
- .version_requirement(VersionRequirement(vo_equal, (*v)->version())),
+ .version_requirement(make_named_values<VersionRequirement>(
+ value_for<n::version_operator>(vo_equal),
+ value_for<n::version_spec>((*v)->version()))),
MatchPackageOptions())) |
filter::SupportsAction<InstallAction>()))]);
diff --git a/paludis/repositories/cran/package_dep_spec.cc b/paludis/repositories/cran/package_dep_spec.cc
index eb48b72..927490c 100644
--- a/paludis/repositories/cran/package_dep_spec.cc
+++ b/paludis/repositories/cran/package_dep_spec.cc
@@ -24,6 +24,7 @@
#include <paludis/util/sequence.hh>
#include <paludis/util/wrapped_forward_iterator.hh>
#include <paludis/util/make_shared_ptr.hh>
+#include <paludis/util/make_named_values.hh>
#include <paludis/dep_spec.hh>
#include <paludis/version_operator.hh>
#include <paludis/version_spec.hh>
@@ -56,9 +57,9 @@ namespace
if (! first)
result.append(", ");
first = false;
- result.append(stringify(r->version_operator));
+ result.append(stringify(r->version_operator()));
result.append(" ");
- result.append(stringify(r->version_spec));
+ result.append(stringify(r->version_spec()));
}
result.append(")");
}
@@ -193,9 +194,9 @@ paludis::cranrepository::parse_cran_package_dep_spec(const std::string & ss)
if (subtokens.size() != 2)
throw PackageDepSpecError("Invalid () entry '" + *t + "' in '" + ss + "'");
- data->version_requirement(VersionRequirement(
- VersionOperator(subtokens[0]),
- VersionSpec(cran_version_to_internal(subtokens[1]))));
+ data->version_requirement(make_named_values<VersionRequirement>(
+ value_for<n::version_operator>(VersionOperator(subtokens[0])),
+ value_for<n::version_spec>(VersionSpec(cran_version_to_internal(subtokens[1])))));
}
}
diff --git a/paludis/repositories/e/e_repository_sets.cc b/paludis/repositories/e/e_repository_sets.cc
index 898dbc9..3542f59 100644
--- a/paludis/repositories/e/e_repository_sets.cc
+++ b/paludis/repositories/e/e_repository_sets.cc
@@ -300,7 +300,9 @@ ERepositorySets::security_set(bool insecurity) const
std::tr1::shared_ptr<PackageDepSpec> spec(new PackageDepSpec(
make_package_dep_spec()
.package((*c)->name())
- .version_requirement(VersionRequirement(vo_equal, (*c)->version()))
+ .version_requirement(make_named_values<VersionRequirement>(
+ value_for<n::version_operator>(vo_equal),
+ value_for<n::version_spec>((*c)->version())))
.in_repository((*c)->repository()->name())));
spec->set_tag(glsa_tags.find(glsa->id())->second);
security_packages->add(std::tr1::shared_ptr<TreeLeaf<SetSpecTree, PackageDepSpec> >(
@@ -334,7 +336,9 @@ ERepositorySets::security_set(bool insecurity) const
std::tr1::shared_ptr<PackageDepSpec> spec(new PackageDepSpec(make_package_dep_spec()
.package((*r)->name())
- .version_requirement(VersionRequirement(vo_equal, (*r)->version()))
+ .version_requirement(make_named_values<VersionRequirement>(
+ value_for<n::version_operator>(vo_equal),
+ value_for<n::version_spec>((*r)->version())))
.in_repository((*r)->repository()->name())));
spec->set_tag(glsa_tags.find(glsa->id())->second);
security_packages->add(std::tr1::shared_ptr<SetSpecTree::ConstItem>(
diff --git a/paludis/repositories/e/vdb_repository.cc b/paludis/repositories/e/vdb_repository.cc
index d85bd5f..ef384dd 100644
--- a/paludis/repositories/e/vdb_repository.cc
+++ b/paludis/repositories/e/vdb_repository.cc
@@ -953,7 +953,7 @@ VDBRepository::need_package_ids(const CategoryNamePart & c) const
IDMap::iterator i(_imp->ids.find(*p.package_ptr()));
if (_imp->ids.end() == i)
i = _imp->ids.insert(std::make_pair(*p.package_ptr(), make_shared_ptr(new PackageIDSequence))).first;
- i->second->push_back(make_id(*p.package_ptr(), p.version_requirements_ptr()->begin()->version_spec, *d));
+ i->second->push_back(make_id(*p.package_ptr(), p.version_requirements_ptr()->begin()->version_spec(), *d));
}
}
catch (const InternalError &)
diff --git a/paludis/repositories/virtuals/package_id.cc b/paludis/repositories/virtuals/package_id.cc
index 4fc49db..3529bb6 100644
--- a/paludis/repositories/virtuals/package_id.cc
+++ b/paludis/repositories/virtuals/package_id.cc
@@ -26,6 +26,7 @@
#include <paludis/util/visitor-impl.hh>
#include <paludis/util/mutex.hh>
#include <paludis/util/hashes.hh>
+#include <paludis/util/make_named_values.hh>
#include <paludis/name.hh>
#include <paludis/dep_spec.hh>
#include <paludis/version_spec.hh>
@@ -63,7 +64,9 @@ namespace paludis
new TreeLeaf<DependencySpecTree, PackageDepSpec>(make_shared_ptr(new PackageDepSpec(
make_package_dep_spec()
.package(v->name())
- .version_requirement(VersionRequirement(vo_equal, v->version()))
+ .version_requirement(make_named_values<VersionRequirement>(
+ value_for<n::version_operator>(vo_equal),
+ value_for<n::version_spec>(v->version())))
.slot_requirement(make_shared_ptr(new UserSlotExactRequirement(v->slot())))
.in_repository(v->repository()->name()))))
:
diff --git a/paludis/user_dep_spec.cc b/paludis/user_dep_spec.cc
index 54b26b6..b60f4bf 100644
--- a/paludis/user_dep_spec.cc
+++ b/paludis/user_dep_spec.cc
@@ -164,7 +164,9 @@ namespace
}
VersionSpec vs(ver);
- result.version_requirement(VersionRequirement(vop, vs));
+ result.version_requirement(make_named_values<VersionRequirement>(
+ value_for<n::version_operator>(vop),
+ value_for<n::version_spec>(vs)));
had_bracket_version_requirements = true;
}
}
diff --git a/paludis/user_dep_spec_TEST.cc b/paludis/user_dep_spec_TEST.cc
index 3c3650c..7e1db75 100644
--- a/paludis/user_dep_spec_TEST.cc
+++ b/paludis/user_dep_spec_TEST.cc
@@ -42,7 +42,7 @@ namespace
{
std::string dump_version_requirement(const VersionRequirement & v)
{
- return stringify(v.version_operator) + stringify(v.version_spec);
+ return stringify(v.version_operator()) + stringify(v.version_spec());
}
struct UserDepSpecTestCase : TestCase
diff --git a/paludis/version_requirements.cc b/paludis/version_requirements.cc
index 25fe492..ece662c 100644
--- a/paludis/version_requirements.cc
+++ b/paludis/version_requirements.cc
@@ -1,7 +1,7 @@
/* vim: set sw=4 sts=4 et foldmethod=syntax : */
/*
- * Copyright (c) 2006, 2007 Ciaran McCreesh
+ * Copyright (c) 2006, 2007, 2008 Ciaran McCreesh
*
* This file is part of the Paludis package manager. Paludis is free software;
* you can redistribute it and/or modify it under the terms of the GNU General
@@ -17,17 +17,16 @@
* Place, Suite 330, Boston, MA 02111-1307 USA
*/
-#include "version_requirements.hh"
+#include <paludis/version_requirements.hh>
#include <paludis/util/stringify.hh>
#include <paludis/util/sequence.hh>
#include <paludis/util/sequence-impl.hh>
#include <paludis/util/wrapped_forward_iterator-impl.hh>
#include <paludis/util/wrapped_output_iterator-impl.hh>
+#include <paludis/util/make_named_values.hh>
using namespace paludis;
-#include <paludis/version_requirements-sr.cc>
-
template class Sequence<VersionRequirement>;
template class WrappedForwardIterator<Sequence<VersionRequirement>::ConstIteratorTag, const VersionRequirement>;
template class WrappedOutputIterator<Sequence<VersionRequirement>::InserterTag, VersionRequirement>;
diff --git a/paludis/version_requirements.hh b/paludis/version_requirements.hh
index 7dadd02..1d0c921 100644
--- a/paludis/version_requirements.hh
+++ b/paludis/version_requirements.hh
@@ -1,7 +1,7 @@
/* vim: set sw=4 sts=4 et foldmethod=syntax : */
/*
- * Copyright (c) 2006, 2007 Ciaran McCreesh
+ * Copyright (c) 2006, 2007, 2008 Ciaran McCreesh
*
* This file is part of the Paludis package manager. Paludis is free software;
* you can redistribute it and/or modify it under the terms of the GNU General
@@ -20,10 +20,10 @@
#ifndef PALUDIS_GUARD_PALUDIS_VERSION_REQUIREMENTS_HH
#define PALUDIS_GUARD_PALUDIS_VERSION_REQUIREMENTS_HH 1
-#include <paludis/util/sr.hh>
#include <paludis/version_requirements-fwd.hh>
#include <paludis/version_operator.hh>
#include <paludis/version_spec.hh>
+#include <paludis/util/named_value.hh>
/** \file
* Declarations for version requirements classes.
@@ -37,7 +37,28 @@
namespace paludis
{
-#include <paludis/version_requirements-sr.hh>
+ namespace n
+ {
+ struct version_operator;
+ struct version_spec;
+ }
+
+ /**
+ * A requirement for a version, consisting of a VersionOperator and an associated
+ * VersionSpec.
+ *
+ * \ingroup g_dep_spec
+ * \see PackageDepSpec
+ * \see VersionSpec
+ * \see VersionOperator
+ * \see VersionRequirements
+ * \nosubgrouping
+ */
+ struct VersionRequirement
+ {
+ NamedValue<n::version_operator, VersionOperator> version_operator;
+ NamedValue<n::version_spec, VersionSpec> version_spec;
+ };
}
#endif
diff --git a/paludis/version_requirements.sr b/paludis/version_requirements.sr
deleted file mode 100644
index 7c9df2c..0000000
--- a/paludis/version_requirements.sr
+++ /dev/null
@@ -1,29 +0,0 @@
-#!/usr/bin/env bash
-# vim: set sw=4 sts=4 et :
-
-make_class_VersionRequirement()
-{
- visible
-
- key version_operator VersionOperator
- key version_spec VersionSpec
-
- allow_named_args
- comparison_operators "equality" "all"
-
- doxygen_comment << "END"
- /**
- * A requirement for a version, consisting of a VersionOperator and an associated
- * VersionSpec.
- *
- * \ingroup g_dep_spec
- * \see PackageDepSpec
- * \see VersionSpec
- * \see VersionOperator
- * \see VersionRequirements
- * \nosubgrouping
- */
-END
-}
-
-
diff --git a/python/version_requirements.cc b/python/version_requirements.cc
index 3c6a8cb..19b092c 100644
--- a/python/version_requirements.cc
+++ b/python/version_requirements.cc
@@ -22,11 +22,23 @@
#include <paludis/version_requirements.hh>
#include <paludis/util/wrapped_forward_iterator.hh>
+#include <paludis/util/make_named_values.hh>
using namespace paludis;
using namespace paludis::python;
namespace bp = boost::python;
+namespace
+{
+ VersionRequirement * make_version_requirement(const VersionOperator & op, const VersionSpec & spec)
+ {
+ return new VersionRequirement(make_named_values<VersionRequirement>(
+ value_for<n::version_operator>(op),
+ value_for<n::version_spec>(spec)
+ ));
+ }
+}
+
void expose_version_requirements()
{
/**
@@ -41,21 +53,25 @@ void expose_version_requirements()
bp::class_<VersionRequirement>
(
"VersionRequirement",
- bp::init<const VersionOperator &, const VersionSpec &>(
- "__init__(VersionOperator, VersionSpec)"
- )
+ bp::no_init
)
- .def_readwrite("version_operator", &VersionRequirement::version_operator,
+
+ .def("__init__",
+ bp::make_constructor(&make_version_requirement),
+ "__init__(VersionOperator, VersionSpec)"
+ )
+
+ .add_property("version_operator",
+ &named_values_getter<VersionRequirement, n::version_operator, VersionOperator, &VersionRequirement::version_operator>,
+ &named_values_setter<VersionRequirement, n::version_operator, VersionOperator, &VersionRequirement::version_operator>,
"[rw] VersionOperator"
)
- .def_readwrite("version_spec", &VersionRequirement::version_spec,
+ .add_property("version_spec",
+ &named_values_getter<VersionRequirement, n::version_spec, VersionSpec, &VersionRequirement::version_spec>,
+ &named_values_setter<VersionRequirement, n::version_spec, VersionSpec, &VersionRequirement::version_spec>,
"[rw] VersionSpec"
)
-
- .def("__eq__", &VersionRequirement::operator==)
-
- .def("__ne__", &py_ne<VersionRequirement>)
;
/**
diff --git a/python/version_requirements_TEST.py b/python/version_requirements_TEST.py
index ed0f39e..6a54b7c 100755
--- a/python/version_requirements_TEST.py
+++ b/python/version_requirements_TEST.py
@@ -34,13 +34,5 @@ class TestCase_VersionRequirements(unittest.TestCase):
self.assertEquals(str(v1.version_operator), ">")
self.assertEquals(str(v1.version_spec), "1")
- def test_03_compare(self):
- v1 = VersionRequirement("<", "0")
- v2 = VersionRequirement("<", "0")
-
- self.assert_(v1 == v2)
- v1.version_operator = ">"
- self.assert_(v1 != v2)
-
if __name__ == "__main__":
unittest.main()
diff --git a/ruby/dep_spec.cc b/ruby/dep_spec.cc
index 4a5ed00..8e4e18a 100644
--- a/ruby/dep_spec.cc
+++ b/ruby/dep_spec.cc
@@ -836,9 +836,9 @@ namespace
{
result_hash = rb_hash_new();
rb_hash_aset(result_hash, ID2SYM(rb_intern("operator")),
- rb_str_new2(stringify(i->version_operator).c_str()));
+ rb_str_new2(stringify(i->version_operator()).c_str()));
rb_hash_aset(result_hash, ID2SYM(rb_intern("spec")),
- version_spec_to_value(i->version_spec));
+ version_spec_to_value(i->version_spec()));
rb_ary_push(result, result_hash);
}
return result;
diff --git a/src/clients/reconcilio/fix_linkage.cc b/src/clients/reconcilio/fix_linkage.cc
index 2f04779..5ae9934 100644
--- a/src/clients/reconcilio/fix_linkage.cc
+++ b/src/clients/reconcilio/fix_linkage.cc
@@ -29,6 +29,7 @@
#include <paludis/util/make_shared_ptr.hh>
#include <paludis/util/sequence.hh>
#include <paludis/util/stringify.hh>
+#include <paludis/util/make_named_values.hh>
#include <paludis/dep_spec.hh>
#include <paludis/user_dep_spec.hh>
@@ -99,7 +100,9 @@ do_fix_linkage(const std::tr1::shared_ptr<Environment> & env)
if (CommandLine::get_instance()->a_exact.specified())
targets->push_back(stringify(make_package_dep_spec()
.package((*pkg_it)->name())
- .version_requirement(VersionRequirement(vo_equal, (*pkg_it)->version()))
+ .version_requirement(make_named_values<VersionRequirement>(
+ value_for<n::version_operator>(vo_equal),
+ value_for<n::version_spec>((*pkg_it)->version())))
.slot_requirement(make_shared_ptr(new UserSlotExactRequirement((*pkg_it)->slot())))));
else
targets->push_back(stringify(make_package_dep_spec()