2013-10-18 Keith Marshall <keithmarshall@users.sourceforge.net>
+ Don't attempt to resolve dependencies for unidentified packages.
+
+ * src/pkgdeps.cpp (pkgXmlDocument::ResolveDependencies):
+ [selected == NULL]: Current dependency is unresolved; do not make any
+ recursive call for this unidentified requirement. This avoids posting
+ misleading "can't get 'tarname' for non-release element <<<unknown>>>"
+ diagnostic messages, where the subsequent "unresolved dependency"
+ message is sufficient; include dmhmsgs.h, and add...
+ (PKGMSG_SPECIFICATION_ERROR): ...this preamble instead.
+
+2013-10-18 Keith Marshall <keithmarshall@users.sourceforge.net>
+
Implement foundation for future NLS enabled diagnostics.
* src/dmhmsgs.h: New file; it declares the NLS capable DMH interface.
#include <string.h>
#include "dmh.h"
+#include "dmhmsgs.h"
#include "debug.h"
#include "pkginfo.h"
/* Regardless of the action scheduled, we must recursively
* consider further dependencies of the resolved prerequisite;
+ * (but note that attempting to do this would be pointless if
+ * the prerequisite package could not be identified).
+ *
* FIXME: do we need to do this, when performing a removal?
* Right now, I (KDM) don't think so...
*/
- if( (request & ACTION_INSTALL) != 0 )
+ if( (selected != NULL) && ((request & ACTION_INSTALL) != 0) )
ResolveDependencies( selected, rank );
}
const char *requestor = refpkg->GetPropVal( tarname_key, value_unknown );
dmh_control( DMH_BEGIN_DIGEST );
+ dmh_notify( DMH_ERROR, PKGMSG_SPECIFICATION_ERROR );
dmh_notify( DMH_ERROR, "%s: requires...\n", requestor );
for( int i = 0; i < sizeof( key ) / sizeof( char* ); i++ )
if( (ref = dep->GetPropVal( key[i], NULL )) != NULL )