[Botan-devel] Botan SUNWspro build errors

Jack Lloyd lloyd at randombit.net
Tue Oct 9 14:20:21 EDT 2007


On Tue, Oct 09, 2007 at 01:26:37PM -0400, Yan Shpilsky wrote:

> While this code was not in asn1_obj.h, it was in stl_util.h, where the 

Oops, instructions fixed. Thanks for the report.

> CC -Ibuild/include -xO2  +p -D__EXTENSIONS__ +w -c src/datastor.cpp -o 
> build/lib/datastor.o
> "src/datastor.cpp", line 53: Error: Could not find a match for 
> std::multimap<std::string, std::string, std::less<std::string>, 
> std::allocator<std::pair<const std::string, 
> std::string>>>::insert(std::pair<std::string, std::string>) needed in 
> Botan::Data_Store::search_with(const Botan::Data_Store::Matcher&) const.
> 1 Error(s) detected.
> *** Error code 1
> make: Fatal error: Command failed for target `build/lib/datastor.o'

Ugh. Try the attached patch. Sorry, I have no access to any Forte
compiler at the moment (though IIRC OpenSolaris includes it, I need to
look into that) so this is just going blind.

Could you send me the compiler and OS version info and the version of
Botan you're using? Is this x86 or SPARC?

-Jack
-------------- next part --------------
#
# old_revision [34f9be417992db1e0a941697596019d801d5b41b]
#
# patch "include/datastor.h"
#  from [3f6602fad0bcd817cc7934c9497648d14074070b]
#    to [1b63537a73a63cf191ba5bdc9be82d7f6245eea0]
# 
# patch "src/datastor.cpp"
#  from [301a7be0303d65b1589216c1f2bcb072ac17e34b]
#    to [5231cc96bc6b7e1be9b1db2e70dd78ee0c2703c9]
#
============================================================
--- include/datastor.h  3f6602fad0bcd817cc7934c9497648d14074070b
+++ include/datastor.h  1b63537a73a63cf191ba5bdc9be82d7f6245eea0
@@ -26,7 +26,7 @@ class Data_Store
             virtual bool operator()(const std::string&,
                                     const std::string&) const = 0;
 
-            virtual std::pair<std::string, std::string>
+            virtual std::pair<const std::string, std::string>
                transform(const std::string&, const std::string&) const;
 
             virtual ~Matcher() {}
============================================================
--- src/datastor.cpp    301a7be0303d65b1589216c1f2bcb072ac17e34b
+++ src/datastor.cpp    5231cc96bc6b7e1be9b1db2e70dd78ee0c2703c9
@@ -13,11 +13,11 @@ namespace Botan {
 /*************************************************
 * Default Matcher transform operation (identity) *
 *************************************************/
-std::pair<std::string, std::string>
+std::pair<const std::string, std::string>
 Data_Store::Matcher::transform(const std::string& key,
                                const std::string& value) const
    {
-   return std::make_pair(key, value);
+   return std::make_pair<const std::string, std::string>(key, value);
    }
 
 /*************************************************


More information about the botan-devel mailing list