mirror of
https://github.com/pentoo/pentoo-overlay
synced 2026-05-03 04:00:54 +02:00
ovaldi: pushed to Gentoo
This commit is contained in:
parent
79da09eca6
commit
cba3cd7117
11 changed files with 0 additions and 835 deletions
|
|
@ -1,12 +0,0 @@
|
|||
AUX ovaldi-5.8.2-disable-ldap-probes.patch 1237 RMD160 5c75a4eb790712f2a5e219035c3bd66b6437b7b4 SHA1 fe627c386fd1e9f299b7caa06b73fe3ac943cae6 SHA256 ca8846757488a75d434a4cc909a96de44cf4b8f6d8f7950c2938630668bbde6a
|
||||
AUX ovaldi-5.8.2-strnicmp.patch 292 RMD160 30058fc991df58e38be9b19855512602879d0136 SHA1 09f4ef19ba2dc009a45ff3b89e93dae6e9fd0cb6 SHA256 aa4a1f23df2fd4b8ed0456a23948cc597d0573eb1e9881f8a8f229b8778f6a54
|
||||
AUX ovaldi-5.8.2-xerces3.patch 12336 RMD160 501377cc5cbe1256a72bf2cd0be8a67943aca50e SHA1 024a2860faf0783c728d468fbe77dd6dc0da5a2f SHA256 70754174e4d390663b79b0dc070eba536d2868ce5b68aae1632e805a52b0e0f0
|
||||
AUX ovaldi-5.9.1-disable-ldap-probes.patch 1237 RMD160 5c75a4eb790712f2a5e219035c3bd66b6437b7b4 SHA1 fe627c386fd1e9f299b7caa06b73fe3ac943cae6 SHA256 ca8846757488a75d434a4cc909a96de44cf4b8f6d8f7950c2938630668bbde6a
|
||||
AUX ovaldi-5.9.1-strnicmp.patch 292 RMD160 30058fc991df58e38be9b19855512602879d0136 SHA1 09f4ef19ba2dc009a45ff3b89e93dae6e9fd0cb6 SHA256 aa4a1f23df2fd4b8ed0456a23948cc597d0573eb1e9881f8a8f229b8778f6a54
|
||||
AUX ovaldi-5.9.1-xerces3.patch 12336 RMD160 501377cc5cbe1256a72bf2cd0be8a67943aca50e SHA1 024a2860faf0783c728d468fbe77dd6dc0da5a2f SHA256 70754174e4d390663b79b0dc070eba536d2868ce5b68aae1632e805a52b0e0f0
|
||||
AUX rpmdb.patch 2131 RMD160 eab0ea48e95ae7d278b80b555a73ca456ac07703 SHA1 ae06d023162d19019f27fdbbc9476fcf57d10cad SHA256 d40775d272b8aed6062b983640cf4c0a330a9d318012b922099eeb04d4c1d131
|
||||
AUX use_local_rpmdb.patch 429 RMD160 4a8f35be13522873bcfc5e03842964e84fc557b0 SHA1 70fe83d0f9f1c8716a2a8afec70da94c9183b2be SHA256 e7956ab2c1de68b0c5284641a36136643aa5a6e12cfd8b6042f0484c1cba63cd
|
||||
DIST ovaldi-5.8.2-src.tar.bz2 7763462 RMD160 04ce0dbce70e2a417f1ebcd612142ade49f42b81 SHA1 d5f2f82c818a5fee28822e4a3608d775df05f031 SHA256 a24d4f2ab88032887ee6a8617994836e9bd7f86565b29811891d4de6a3e9b8e2
|
||||
DIST ovaldi-5.9.1-src.tar.bz2 7811571 RMD160 73aac9c0ebb7bb2cdab7f82ec24779c5a8d1a2f2 SHA1 7da8d20c60e435fd40173de715c5c1c948858639 SHA256 e65950f45ad55f4489bf63bac61f764d4b8577230cb41f50b0ad2e9c636286f6
|
||||
EBUILD ovaldi-5.8.2-r2.ebuild 1758 RMD160 755e88dce99442248d5f4cdbd9a417a0838942b8 SHA1 b9bbc3c99e20c68c068bebb4b55b81567c1e5465 SHA256 66ec3ab9d2aa17f775640e54799fd1a57faa0e7328eb6dd0c6bc29f6ed00b954
|
||||
EBUILD ovaldi-5.9.1.ebuild 1758 RMD160 755e88dce99442248d5f4cdbd9a417a0838942b8 SHA1 b9bbc3c99e20c68c068bebb4b55b81567c1e5465 SHA256 66ec3ab9d2aa17f775640e54799fd1a57faa0e7328eb6dd0c6bc29f6ed00b954
|
||||
|
|
@ -1,32 +0,0 @@
|
|||
--- src/linux/ProbeFactory.cpp 2010-12-10 13:37:00.019140703 +0100
|
||||
+++ src/linux/ProbeFactory.cpp 2010-08-27 21:23:41.000000000 +0200
|
||||
@@ -61,8 +61,6 @@
|
||||
probe = XmlFileContentProbe::Instance();
|
||||
} else if(objectName.compare("textfilecontent54_object") == 0) {
|
||||
probe = TextFileContent54Probe::Instance();
|
||||
- } else if(objectName.compare("ldap_object") == 0) {
|
||||
- probe = LDAPProbe::Instance();
|
||||
|
||||
// here are the objects defined in the unix schema
|
||||
} else if(objectName.compare("file_object") == 0) {
|
||||
--- src/linux/ProbeFactory.h 2010-12-10 13:36:50.315386197 +0100
|
||||
+++ src/linux/ProbeFactory.h 2010-08-27 21:23:41.000000000 +0200
|
||||
@@ -68,7 +68,6 @@
|
||||
#include "RunLevelProbe.h"
|
||||
#include "XinetdProbe.h"
|
||||
#include "InetdProbe.h"
|
||||
-#include "LDAPProbe.h"
|
||||
|
||||
|
||||
|
||||
--- project/linux/Makefile 2010-12-10 13:49:06.655143160 +0100
|
||||
+++ project/linux/Makefile 2010-12-10 13:47:37.247382096 +0100
|
||||
@@ -49,7 +49,7 @@
|
||||
LIBDIR = -L/usr/local/lib -L/usr/lib
|
||||
|
||||
# What libraries do we need?
|
||||
-LIBS = -lxerces-c -lxalan-c -lpcre -lpopt -lgcrypt -lldap
|
||||
+LIBS = -lxerces-c -lxalan-c -lpcre -lpopt -lgcrypt
|
||||
|
||||
# Determine what package management system is being used
|
||||
PACKAGE_RPM = $(shell /usr/bin/env rpm --version 2>/dev/null)
|
||||
|
|
@ -1,11 +0,0 @@
|
|||
--- src/Main.h.old 2010-10-22 14:59:13.000000000 +0200
|
||||
+++ src/Main.h 2010-10-22 14:59:38.000000000 +0200
|
||||
@@ -38,7 +38,7 @@
|
||||
#endif
|
||||
|
||||
#ifdef LINUX
|
||||
-# define STRNICMP strnicmp
|
||||
+# define STRNICMP strncasecmp
|
||||
#elif defined SUNOS
|
||||
# define STRNICMP strncasecmp
|
||||
#elif defined DARWIN
|
||||
|
|
@ -1,270 +0,0 @@
|
|||
--- src/XmlProcessor.cpp.old 2010-10-25 15:13:58.000000000 +0200
|
||||
+++ src/XmlProcessor.cpp 2010-10-26 09:14:46.000000000 +0200
|
||||
@@ -34,8 +34,17 @@
|
||||
//****************************************************************************************//
|
||||
// DataDirResolver Class //
|
||||
//****************************************************************************************//
|
||||
-
|
||||
+#if XERCES_VERSION_MAJOR < 3
|
||||
DOMInputSource* DataDirResolver::resolveEntity (const XMLCh *const /*publicId*/, const XMLCh *const systemId, const XMLCh *const /*baseURI*/) {
|
||||
+#else
|
||||
+InputSource* DataDirResolver::resolveEntity(const XMLCh* publicId, const XMLCh* systemId)
|
||||
+{
|
||||
+ return NULL;
|
||||
+ //return DataDirResolver::resolveEntity (publicId, systemId, NULL);
|
||||
+}
|
||||
+
|
||||
+DOMLSInput* DataDirResolver::resolveEntity (const XMLCh *const publicId, const XMLCh *const systemId, const XMLCh *const baseURI) {
|
||||
+#endif
|
||||
string path = "";
|
||||
size_t last;
|
||||
string schemapath = Common::GetSchemaPath();
|
||||
@@ -111,21 +120,35 @@
|
||||
// Instantiate the DOM parser.
|
||||
static const XMLCh gLS[] = { chLatin_L, chLatin_S, chNull };
|
||||
DOMImplementation *impl = DOMImplementationRegistry::getDOMImplementation(gLS);
|
||||
+#if XERCES_VERSION_MAJOR < 3
|
||||
parser = ((DOMImplementationLS*)impl)->createDOMBuilder(DOMImplementationLS::MODE_SYNCHRONOUS, 0);
|
||||
+#else
|
||||
+ parser = ((DOMImplementationLS*)impl)->createLSParser(DOMImplementationLS::MODE_SYNCHRONOUS, 0);
|
||||
+#endif
|
||||
|
||||
///////////////////////////////////////////////////////
|
||||
// Set fetuares on the builder
|
||||
///////////////////////////////////////////////////////
|
||||
|
||||
+#if XERCES_VERSION_MAJOR < 3
|
||||
+#define SetParameter(parser,n,v) parser->setFeature(n,v)
|
||||
+#else
|
||||
+#define SetParameter(parser,n,v) parser->getDomConfig()->setParameter(n,v)
|
||||
+#endif
|
||||
+ SetParameter(parser, XMLUni::fgDOMComments, false); // Discard Comment nodes in the document.
|
||||
+ SetParameter(parser, XMLUni::fgDOMDatatypeNormalization, true); // Let the validation process do its datatype normalization that is defined in the used schema language.
|
||||
+ SetParameter(parser, XMLUni::fgDOMNamespaces, true); // Perform Namespace processing
|
||||
+#if XERCES_VERSION_MAJOR < 3
|
||||
+ SetParameter(parser, XMLUni::fgDOMValidation, true); // Report all validation errors.
|
||||
+#else
|
||||
+ SetParameter(parser, XMLUni::fgDOMValidate, true); // Report all validation errors.
|
||||
+#endif
|
||||
+ SetParameter(parser, XMLUni::fgXercesSchema, true); // Enable the parser's schema support.
|
||||
+ SetParameter(parser, XMLUni::fgXercesSchemaFullChecking, true); // Enable full schema constraint checking, including checking which may be time-consuming or memory intensive. Currently, particle unique attribution constraint checking and particle derivation restriction checking are controlled by this option.
|
||||
+ SetParameter(parser, XMLUni::fgXercesValidationErrorAsFatal, true); // The parser will treat validation error as fatal and will exit
|
||||
+ SetParameter(parser, XMLUni::fgXercesDOMHasPSVIInfo, true); // Enable storing of PSVI information in element and attribute nodes.
|
||||
|
||||
- parser->setFeature(XMLUni::fgDOMComments, false); // Discard Comment nodes in the document.
|
||||
- parser->setFeature(XMLUni::fgDOMDatatypeNormalization, true); // Let the validation process do its datatype normalization that is defined in the used schema language.
|
||||
- parser->setFeature(XMLUni::fgDOMNamespaces, true); // Perform Namespace processing
|
||||
- parser->setFeature(XMLUni::fgDOMValidation, true); // Report all validation errors.
|
||||
- parser->setFeature(XMLUni::fgXercesSchema, true); // Enable the parser's schema support.
|
||||
- parser->setFeature(XMLUni::fgXercesSchemaFullChecking, true); // Enable full schema constraint checking, including checking which may be time-consuming or memory intensive. Currently, particle unique attribution constraint checking and particle derivation restriction checking are controlled by this option.
|
||||
- parser->setFeature(XMLUni::fgXercesValidationErrorAsFatal, true); // The parser will treat validation error as fatal and will exit
|
||||
- parser->setFeature(XMLUni::fgXercesDOMHasPSVIInfo, true); // Enable storing of PSVI information in element and attribute nodes.
|
||||
+#undef SetParameter
|
||||
|
||||
///////////////////////////////////////////////////////
|
||||
//****************************************************************************************//
|
||||
@@ -133,7 +156,11 @@
|
||||
//****************************************************************************************//
|
||||
/* Look for XML schemas in local directory instead of Internet */
|
||||
DataDirResolver resolver;
|
||||
+#if XERCES_VERSION_MAJOR < 3
|
||||
parser->setEntityResolver (&resolver);
|
||||
+#else
|
||||
+ parser->getDomConfig()->setParameter(XMLUni::fgXercesEntityResolver, &resolver);
|
||||
+#endif
|
||||
//****************************************************************************************//
|
||||
// End of air-gap code //
|
||||
//****************************************************************************************//
|
||||
@@ -144,7 +171,11 @@
|
||||
// Create a new DOMErrorHandler
|
||||
// and set it to the builder
|
||||
XmlProcessorErrorHandler *errHandler = new XmlProcessorErrorHandler();
|
||||
+#if XERCES_VERSION_MAJOR < 3
|
||||
parser->setErrorHandler(errHandler);
|
||||
+#else
|
||||
+ parser->getDomConfig()->setParameter(XMLUni::fgDOMErrorHandler, errHandler);
|
||||
+#endif
|
||||
|
||||
try {
|
||||
// reset document pool
|
||||
@@ -215,24 +246,26 @@
|
||||
XMLCh tempStr[100];
|
||||
XMLString::transcode("LS", tempStr, 99);
|
||||
DOMImplementation *impl = DOMImplementationRegistry::getDOMImplementation(tempStr);
|
||||
+#if XERCES_VERSION_MAJOR < 3
|
||||
DOMWriter *theSerializer = ((DOMImplementationLS*)impl)->createDOMWriter();
|
||||
+#else
|
||||
+ DOMLSSerializer *theSerializer = ((DOMImplementationLS*)impl)->createLSSerializer();
|
||||
+#endif
|
||||
+
|
||||
+#if XERCES_VERSION_MAJOR < 3
|
||||
+#define SetParameter(serializer,n,v) if (serializer->canSetFeature(n,v)) serializer->setFeature(n,v)
|
||||
+#else
|
||||
+#define SetParameter(serializer,n,v) if (serializer->getDomConfig()->canSetParameter(n,v)) serializer->getDomConfig()->setParameter(n,v)
|
||||
+#endif
|
||||
|
||||
// set feature if the serializer supports the feature/mode
|
||||
- if (theSerializer->canSetFeature(XMLUni::fgDOMWRTSplitCdataSections, true))
|
||||
- theSerializer->setFeature(XMLUni::fgDOMWRTSplitCdataSections, true);
|
||||
-
|
||||
- if (theSerializer->canSetFeature(XMLUni::fgDOMWRTDiscardDefaultContent, true))
|
||||
- theSerializer->setFeature(XMLUni::fgDOMWRTDiscardDefaultContent, true);
|
||||
-
|
||||
- if (theSerializer->canSetFeature(XMLUni::fgDOMWRTFormatPrettyPrint, true))
|
||||
- theSerializer->setFeature(XMLUni::fgDOMWRTFormatPrettyPrint, true);
|
||||
-
|
||||
- if (theSerializer->canSetFeature(XMLUni::fgDOMWRTBOM, false))
|
||||
- theSerializer->setFeature(XMLUni::fgDOMWRTBOM, false);
|
||||
-
|
||||
- //if (theSerializer->canSetFeature(XMLUni::fgDOMWRTDiscardDefaultContent, true))
|
||||
- // theSerializer->setFeature(XMLUni::fgDOMWRTBOM, true);
|
||||
+ SetParameter(theSerializer, XMLUni::fgDOMWRTSplitCdataSections, true);
|
||||
+ SetParameter(theSerializer, XMLUni::fgDOMWRTDiscardDefaultContent, true);
|
||||
+ SetParameter(theSerializer, XMLUni::fgDOMWRTFormatPrettyPrint, true);
|
||||
+ SetParameter(theSerializer, XMLUni::fgDOMWRTBOM, false);
|
||||
+ //SetParameter(theSerializer, XMLUni::fgDOMWRTBOM, true);
|
||||
|
||||
+#undef SetParameter
|
||||
//
|
||||
// Plug in a format target to receive the resultant
|
||||
// XML stream from the serializer.
|
||||
@@ -249,7 +282,13 @@
|
||||
//
|
||||
// do the serialization through DOMWriter::writeNode();
|
||||
//
|
||||
+#if XERCES_VERSION_MAJOR < 3
|
||||
theSerializer->writeNode(myFormTarget, *doc);
|
||||
+#else
|
||||
+ DOMLSOutput *output = ((DOMImplementationLS*)impl)->createLSOutput();
|
||||
+ output->setByteStream(myFormTarget);
|
||||
+ theSerializer->write(doc, output);
|
||||
+#endif
|
||||
|
||||
delete theSerializer;
|
||||
delete myFormTarget;
|
||||
--- src/XmlProcessor.h.old 2010-10-22 12:06:05.000000000 +0200
|
||||
+++ src/XmlProcessor.h 2010-10-22 12:06:20.000000000 +0200
|
||||
@@ -40,7 +40,7 @@
|
||||
|
||||
// required xerces includes
|
||||
#include <xercesc/dom/DOMImplementationRegistry.hpp>
|
||||
-#include <xercesc/dom/DOMBuilder.hpp>
|
||||
+//#include <xercesc/dom/DOMBuilder.hpp>
|
||||
#include <xercesc/dom/DOMException.hpp>
|
||||
#include <xercesc/dom/DOMErrorHandler.hpp>
|
||||
#include <xercesc/dom/DOMError.hpp>
|
||||
--- src/XmlProcessor.h.old 2010-10-22 14:40:45.000000000 +0200
|
||||
+++ src/XmlProcessor.h 2010-10-22 14:42:00.000000000 +0200
|
||||
@@ -50,18 +50,23 @@
|
||||
// for dom Writer
|
||||
#include <xercesc/dom/DOMImplementation.hpp>
|
||||
#include <xercesc/dom/DOMImplementationLS.hpp>
|
||||
-#include <xercesc/dom/DOMWriter.hpp>
|
||||
+//#include <xercesc/dom/DOMWriter.hpp>
|
||||
#include <xercesc/framework/StdOutFormatTarget.hpp>
|
||||
#include <xercesc/framework/LocalFileFormatTarget.hpp>
|
||||
#include <xercesc/parsers/XercesDOMParser.hpp>
|
||||
#include <xercesc/util/XMLUni.hpp>
|
||||
|
||||
// for entity resolver
|
||||
-#include <xercesc/dom/DOMEntityResolver.hpp>
|
||||
-#include <xercesc/dom/DOMInputSource.hpp>
|
||||
+//#include <xercesc/dom/DOMEntityResolver.hpp>
|
||||
+//#include <xercesc/dom/DOMInputSource.hpp>
|
||||
#include <xercesc/framework/LocalFileInputSource.hpp>
|
||||
#include <xercesc/framework/Wrapper4InputSource.hpp>
|
||||
|
||||
+#include <xercesc/dom/DOMImplementationRegistry.hpp>
|
||||
+#include <xercesc/sax/EntityResolver.hpp>
|
||||
+#include <xercesc/sax/InputSource.hpp>
|
||||
+#include <xercesc/sax2/SAX2XMLReader.hpp>
|
||||
+
|
||||
|
||||
XERCES_CPP_NAMESPACE_USE
|
||||
|
||||
--- src/XmlProcessor.h.old 2010-10-22 14:43:06.000000000 +0200
|
||||
+++ src/XmlProcessor.h 2010-10-22 14:44:16.000000000 +0200
|
||||
@@ -75,12 +75,14 @@
|
||||
This class extends the default DOMEntityResolver and implments the resolve entity method
|
||||
to support
|
||||
*/
|
||||
-class DataDirResolver : public DOMEntityResolver {
|
||||
+class DataDirResolver : public EntityResolver {
|
||||
public:
|
||||
/**
|
||||
*
|
||||
*/
|
||||
- DOMInputSource *resolveEntity (const XMLCh *const publicId, const XMLCh *const systemId, const XMLCh *const baseURI);
|
||||
+// DOMInputSource *resolveEntity (const XMLCh *const publicId, const XMLCh *const systemId, const XMLCh *const baseURI);
|
||||
+ InputSource *resolveEntity (const XMLCh *const publicId, const XMLCh *const systemId);
|
||||
+ DOMLSInput *resolveEntity (const XMLCh *const publicId, const XMLCh *const systemId, const XMLCh *const baseURI);
|
||||
};
|
||||
|
||||
/**
|
||||
@@ -120,7 +122,7 @@
|
||||
|
||||
static XmlProcessor* instance;
|
||||
|
||||
- DOMBuilder *parser;
|
||||
+ DOMLSParser *parser;
|
||||
};
|
||||
|
||||
/**
|
||||
--- src/probes/independent/XmlFileContentProbe.cpp.old 2010-10-22 14:49:22.000000000 +0200
|
||||
+++ src/probes/independent/XmlFileContentProbe.cpp 2010-10-22 14:51:39.000000000 +0200
|
||||
@@ -419,12 +419,24 @@
|
||||
return new DummyEntityResolver::DoNothingBinInputStream();
|
||||
}
|
||||
|
||||
+#if XERCES_VERSION_MAJOR < 3
|
||||
unsigned int DummyEntityResolver::DoNothingBinInputStream::curPos() const
|
||||
+#else
|
||||
+const XMLCh* DummyEntityResolver::DoNothingBinInputStream::getContentType() const
|
||||
+{
|
||||
+ return NULL;
|
||||
+}
|
||||
+XMLFilePos DummyEntityResolver::DoNothingBinInputStream::curPos() const
|
||||
+#endif
|
||||
{
|
||||
return 0;
|
||||
}
|
||||
|
||||
+#if XERCES_VERSION_MAJOR < 3
|
||||
unsigned int DummyEntityResolver::DoNothingBinInputStream::readBytes(XMLByte *const /*toFill*/, const unsigned int /*maxToRead*/)
|
||||
+#else
|
||||
+XMLSize_t DummyEntityResolver::DoNothingBinInputStream::readBytes(XMLByte *const toFill, XMLSize_t maxToRead)
|
||||
+#endif
|
||||
{
|
||||
return 0;
|
||||
}
|
||||
--- src/probes/independent/XmlFileContentProbe.h.old 2010-10-22 14:55:47.000000000 +0200
|
||||
+++ src/probes/independent/XmlFileContentProbe.h 2010-10-22 14:57:00.000000000 +0200
|
||||
@@ -134,8 +134,14 @@
|
||||
class DoNothingBinInputStream : public BinInputStream
|
||||
{
|
||||
public:
|
||||
+#if XERCES_VERSION_MAJOR < 3
|
||||
virtual unsigned int curPos() const;
|
||||
virtual unsigned int readBytes(XMLByte *const toFill, const unsigned int maxToRead);
|
||||
+#else
|
||||
+ virtual XMLFilePos curPos() const;
|
||||
+ virtual const XMLCh* getContentType() const;
|
||||
+ virtual XMLSize_t readBytes(XMLByte *const toFill, XMLSize_t maxToRead);
|
||||
+#endif
|
||||
};
|
||||
};
|
||||
|
||||
--- src/XmlCommon.cpp.old
|
||||
+++ src/XmlCommon.cpp
|
||||
@@ -546,7 +546,11 @@ void XmlCommon::AddSchemaLocation(XERCES_CPP_NAMESPACE_QUALIFIER DOMDocument *do
|
||||
string XmlCommon::GetNamespace(DOMElement *element) {
|
||||
|
||||
string xmlns = "";
|
||||
+#if XERCES_VERSION_MAJOR < 3
|
||||
xmlns = XmlCommon::ToString(element->getTypeInfo()->getNamespace());
|
||||
+#else
|
||||
+ xmlns = XmlCommon::ToString(element->getSchemaTypeInfo()->getTypeNamespace());
|
||||
+#endif
|
||||
if (xmlns.compare("") == 0) {
|
||||
xmlns = "";
|
||||
}
|
||||
|
|
@ -1,32 +0,0 @@
|
|||
--- src/linux/ProbeFactory.cpp 2010-12-10 13:37:00.019140703 +0100
|
||||
+++ src/linux/ProbeFactory.cpp 2010-08-27 21:23:41.000000000 +0200
|
||||
@@ -61,8 +61,6 @@
|
||||
probe = XmlFileContentProbe::Instance();
|
||||
} else if(objectName.compare("textfilecontent54_object") == 0) {
|
||||
probe = TextFileContent54Probe::Instance();
|
||||
- } else if(objectName.compare("ldap_object") == 0) {
|
||||
- probe = LDAPProbe::Instance();
|
||||
|
||||
// here are the objects defined in the unix schema
|
||||
} else if(objectName.compare("file_object") == 0) {
|
||||
--- src/linux/ProbeFactory.h 2010-12-10 13:36:50.315386197 +0100
|
||||
+++ src/linux/ProbeFactory.h 2010-08-27 21:23:41.000000000 +0200
|
||||
@@ -68,7 +68,6 @@
|
||||
#include "RunLevelProbe.h"
|
||||
#include "XinetdProbe.h"
|
||||
#include "InetdProbe.h"
|
||||
-#include "LDAPProbe.h"
|
||||
|
||||
|
||||
|
||||
--- project/linux/Makefile 2010-12-10 13:49:06.655143160 +0100
|
||||
+++ project/linux/Makefile 2010-12-10 13:47:37.247382096 +0100
|
||||
@@ -49,7 +49,7 @@
|
||||
LIBDIR = -L/usr/local/lib -L/usr/lib
|
||||
|
||||
# What libraries do we need?
|
||||
-LIBS = -lxerces-c -lxalan-c -lpcre -lpopt -lgcrypt -lldap
|
||||
+LIBS = -lxerces-c -lxalan-c -lpcre -lpopt -lgcrypt
|
||||
|
||||
# Determine what package management system is being used
|
||||
PACKAGE_RPM = $(shell /usr/bin/env rpm --version 2>/dev/null)
|
||||
|
|
@ -1,11 +0,0 @@
|
|||
--- src/Main.h.old 2010-10-22 14:59:13.000000000 +0200
|
||||
+++ src/Main.h 2010-10-22 14:59:38.000000000 +0200
|
||||
@@ -38,7 +38,7 @@
|
||||
#endif
|
||||
|
||||
#ifdef LINUX
|
||||
-# define STRNICMP strnicmp
|
||||
+# define STRNICMP strncasecmp
|
||||
#elif defined SUNOS
|
||||
# define STRNICMP strncasecmp
|
||||
#elif defined DARWIN
|
||||
|
|
@ -1,270 +0,0 @@
|
|||
--- src/XmlProcessor.cpp.old 2010-10-25 15:13:58.000000000 +0200
|
||||
+++ src/XmlProcessor.cpp 2010-10-26 09:14:46.000000000 +0200
|
||||
@@ -34,8 +34,17 @@
|
||||
//****************************************************************************************//
|
||||
// DataDirResolver Class //
|
||||
//****************************************************************************************//
|
||||
-
|
||||
+#if XERCES_VERSION_MAJOR < 3
|
||||
DOMInputSource* DataDirResolver::resolveEntity (const XMLCh *const /*publicId*/, const XMLCh *const systemId, const XMLCh *const /*baseURI*/) {
|
||||
+#else
|
||||
+InputSource* DataDirResolver::resolveEntity(const XMLCh* publicId, const XMLCh* systemId)
|
||||
+{
|
||||
+ return NULL;
|
||||
+ //return DataDirResolver::resolveEntity (publicId, systemId, NULL);
|
||||
+}
|
||||
+
|
||||
+DOMLSInput* DataDirResolver::resolveEntity (const XMLCh *const publicId, const XMLCh *const systemId, const XMLCh *const baseURI) {
|
||||
+#endif
|
||||
string path = "";
|
||||
size_t last;
|
||||
string schemapath = Common::GetSchemaPath();
|
||||
@@ -111,21 +120,35 @@
|
||||
// Instantiate the DOM parser.
|
||||
static const XMLCh gLS[] = { chLatin_L, chLatin_S, chNull };
|
||||
DOMImplementation *impl = DOMImplementationRegistry::getDOMImplementation(gLS);
|
||||
+#if XERCES_VERSION_MAJOR < 3
|
||||
parser = ((DOMImplementationLS*)impl)->createDOMBuilder(DOMImplementationLS::MODE_SYNCHRONOUS, 0);
|
||||
+#else
|
||||
+ parser = ((DOMImplementationLS*)impl)->createLSParser(DOMImplementationLS::MODE_SYNCHRONOUS, 0);
|
||||
+#endif
|
||||
|
||||
///////////////////////////////////////////////////////
|
||||
// Set fetuares on the builder
|
||||
///////////////////////////////////////////////////////
|
||||
|
||||
+#if XERCES_VERSION_MAJOR < 3
|
||||
+#define SetParameter(parser,n,v) parser->setFeature(n,v)
|
||||
+#else
|
||||
+#define SetParameter(parser,n,v) parser->getDomConfig()->setParameter(n,v)
|
||||
+#endif
|
||||
+ SetParameter(parser, XMLUni::fgDOMComments, false); // Discard Comment nodes in the document.
|
||||
+ SetParameter(parser, XMLUni::fgDOMDatatypeNormalization, true); // Let the validation process do its datatype normalization that is defined in the used schema language.
|
||||
+ SetParameter(parser, XMLUni::fgDOMNamespaces, true); // Perform Namespace processing
|
||||
+#if XERCES_VERSION_MAJOR < 3
|
||||
+ SetParameter(parser, XMLUni::fgDOMValidation, true); // Report all validation errors.
|
||||
+#else
|
||||
+ SetParameter(parser, XMLUni::fgDOMValidate, true); // Report all validation errors.
|
||||
+#endif
|
||||
+ SetParameter(parser, XMLUni::fgXercesSchema, true); // Enable the parser's schema support.
|
||||
+ SetParameter(parser, XMLUni::fgXercesSchemaFullChecking, true); // Enable full schema constraint checking, including checking which may be time-consuming or memory intensive. Currently, particle unique attribution constraint checking and particle derivation restriction checking are controlled by this option.
|
||||
+ SetParameter(parser, XMLUni::fgXercesValidationErrorAsFatal, true); // The parser will treat validation error as fatal and will exit
|
||||
+ SetParameter(parser, XMLUni::fgXercesDOMHasPSVIInfo, true); // Enable storing of PSVI information in element and attribute nodes.
|
||||
|
||||
- parser->setFeature(XMLUni::fgDOMComments, false); // Discard Comment nodes in the document.
|
||||
- parser->setFeature(XMLUni::fgDOMDatatypeNormalization, true); // Let the validation process do its datatype normalization that is defined in the used schema language.
|
||||
- parser->setFeature(XMLUni::fgDOMNamespaces, true); // Perform Namespace processing
|
||||
- parser->setFeature(XMLUni::fgDOMValidation, true); // Report all validation errors.
|
||||
- parser->setFeature(XMLUni::fgXercesSchema, true); // Enable the parser's schema support.
|
||||
- parser->setFeature(XMLUni::fgXercesSchemaFullChecking, true); // Enable full schema constraint checking, including checking which may be time-consuming or memory intensive. Currently, particle unique attribution constraint checking and particle derivation restriction checking are controlled by this option.
|
||||
- parser->setFeature(XMLUni::fgXercesValidationErrorAsFatal, true); // The parser will treat validation error as fatal and will exit
|
||||
- parser->setFeature(XMLUni::fgXercesDOMHasPSVIInfo, true); // Enable storing of PSVI information in element and attribute nodes.
|
||||
+#undef SetParameter
|
||||
|
||||
///////////////////////////////////////////////////////
|
||||
//****************************************************************************************//
|
||||
@@ -133,7 +156,11 @@
|
||||
//****************************************************************************************//
|
||||
/* Look for XML schemas in local directory instead of Internet */
|
||||
DataDirResolver resolver;
|
||||
+#if XERCES_VERSION_MAJOR < 3
|
||||
parser->setEntityResolver (&resolver);
|
||||
+#else
|
||||
+ parser->getDomConfig()->setParameter(XMLUni::fgXercesEntityResolver, &resolver);
|
||||
+#endif
|
||||
//****************************************************************************************//
|
||||
// End of air-gap code //
|
||||
//****************************************************************************************//
|
||||
@@ -144,7 +171,11 @@
|
||||
// Create a new DOMErrorHandler
|
||||
// and set it to the builder
|
||||
XmlProcessorErrorHandler *errHandler = new XmlProcessorErrorHandler();
|
||||
+#if XERCES_VERSION_MAJOR < 3
|
||||
parser->setErrorHandler(errHandler);
|
||||
+#else
|
||||
+ parser->getDomConfig()->setParameter(XMLUni::fgDOMErrorHandler, errHandler);
|
||||
+#endif
|
||||
|
||||
try {
|
||||
// reset document pool
|
||||
@@ -215,24 +246,26 @@
|
||||
XMLCh tempStr[100];
|
||||
XMLString::transcode("LS", tempStr, 99);
|
||||
DOMImplementation *impl = DOMImplementationRegistry::getDOMImplementation(tempStr);
|
||||
+#if XERCES_VERSION_MAJOR < 3
|
||||
DOMWriter *theSerializer = ((DOMImplementationLS*)impl)->createDOMWriter();
|
||||
+#else
|
||||
+ DOMLSSerializer *theSerializer = ((DOMImplementationLS*)impl)->createLSSerializer();
|
||||
+#endif
|
||||
+
|
||||
+#if XERCES_VERSION_MAJOR < 3
|
||||
+#define SetParameter(serializer,n,v) if (serializer->canSetFeature(n,v)) serializer->setFeature(n,v)
|
||||
+#else
|
||||
+#define SetParameter(serializer,n,v) if (serializer->getDomConfig()->canSetParameter(n,v)) serializer->getDomConfig()->setParameter(n,v)
|
||||
+#endif
|
||||
|
||||
// set feature if the serializer supports the feature/mode
|
||||
- if (theSerializer->canSetFeature(XMLUni::fgDOMWRTSplitCdataSections, true))
|
||||
- theSerializer->setFeature(XMLUni::fgDOMWRTSplitCdataSections, true);
|
||||
-
|
||||
- if (theSerializer->canSetFeature(XMLUni::fgDOMWRTDiscardDefaultContent, true))
|
||||
- theSerializer->setFeature(XMLUni::fgDOMWRTDiscardDefaultContent, true);
|
||||
-
|
||||
- if (theSerializer->canSetFeature(XMLUni::fgDOMWRTFormatPrettyPrint, true))
|
||||
- theSerializer->setFeature(XMLUni::fgDOMWRTFormatPrettyPrint, true);
|
||||
-
|
||||
- if (theSerializer->canSetFeature(XMLUni::fgDOMWRTBOM, false))
|
||||
- theSerializer->setFeature(XMLUni::fgDOMWRTBOM, false);
|
||||
-
|
||||
- //if (theSerializer->canSetFeature(XMLUni::fgDOMWRTDiscardDefaultContent, true))
|
||||
- // theSerializer->setFeature(XMLUni::fgDOMWRTBOM, true);
|
||||
+ SetParameter(theSerializer, XMLUni::fgDOMWRTSplitCdataSections, true);
|
||||
+ SetParameter(theSerializer, XMLUni::fgDOMWRTDiscardDefaultContent, true);
|
||||
+ SetParameter(theSerializer, XMLUni::fgDOMWRTFormatPrettyPrint, true);
|
||||
+ SetParameter(theSerializer, XMLUni::fgDOMWRTBOM, false);
|
||||
+ //SetParameter(theSerializer, XMLUni::fgDOMWRTBOM, true);
|
||||
|
||||
+#undef SetParameter
|
||||
//
|
||||
// Plug in a format target to receive the resultant
|
||||
// XML stream from the serializer.
|
||||
@@ -249,7 +282,13 @@
|
||||
//
|
||||
// do the serialization through DOMWriter::writeNode();
|
||||
//
|
||||
+#if XERCES_VERSION_MAJOR < 3
|
||||
theSerializer->writeNode(myFormTarget, *doc);
|
||||
+#else
|
||||
+ DOMLSOutput *output = ((DOMImplementationLS*)impl)->createLSOutput();
|
||||
+ output->setByteStream(myFormTarget);
|
||||
+ theSerializer->write(doc, output);
|
||||
+#endif
|
||||
|
||||
delete theSerializer;
|
||||
delete myFormTarget;
|
||||
--- src/XmlProcessor.h.old 2010-10-22 12:06:05.000000000 +0200
|
||||
+++ src/XmlProcessor.h 2010-10-22 12:06:20.000000000 +0200
|
||||
@@ -40,7 +40,7 @@
|
||||
|
||||
// required xerces includes
|
||||
#include <xercesc/dom/DOMImplementationRegistry.hpp>
|
||||
-#include <xercesc/dom/DOMBuilder.hpp>
|
||||
+//#include <xercesc/dom/DOMBuilder.hpp>
|
||||
#include <xercesc/dom/DOMException.hpp>
|
||||
#include <xercesc/dom/DOMErrorHandler.hpp>
|
||||
#include <xercesc/dom/DOMError.hpp>
|
||||
--- src/XmlProcessor.h.old 2010-10-22 14:40:45.000000000 +0200
|
||||
+++ src/XmlProcessor.h 2010-10-22 14:42:00.000000000 +0200
|
||||
@@ -50,18 +50,23 @@
|
||||
// for dom Writer
|
||||
#include <xercesc/dom/DOMImplementation.hpp>
|
||||
#include <xercesc/dom/DOMImplementationLS.hpp>
|
||||
-#include <xercesc/dom/DOMWriter.hpp>
|
||||
+//#include <xercesc/dom/DOMWriter.hpp>
|
||||
#include <xercesc/framework/StdOutFormatTarget.hpp>
|
||||
#include <xercesc/framework/LocalFileFormatTarget.hpp>
|
||||
#include <xercesc/parsers/XercesDOMParser.hpp>
|
||||
#include <xercesc/util/XMLUni.hpp>
|
||||
|
||||
// for entity resolver
|
||||
-#include <xercesc/dom/DOMEntityResolver.hpp>
|
||||
-#include <xercesc/dom/DOMInputSource.hpp>
|
||||
+//#include <xercesc/dom/DOMEntityResolver.hpp>
|
||||
+//#include <xercesc/dom/DOMInputSource.hpp>
|
||||
#include <xercesc/framework/LocalFileInputSource.hpp>
|
||||
#include <xercesc/framework/Wrapper4InputSource.hpp>
|
||||
|
||||
+#include <xercesc/dom/DOMImplementationRegistry.hpp>
|
||||
+#include <xercesc/sax/EntityResolver.hpp>
|
||||
+#include <xercesc/sax/InputSource.hpp>
|
||||
+#include <xercesc/sax2/SAX2XMLReader.hpp>
|
||||
+
|
||||
|
||||
XERCES_CPP_NAMESPACE_USE
|
||||
|
||||
--- src/XmlProcessor.h.old 2010-10-22 14:43:06.000000000 +0200
|
||||
+++ src/XmlProcessor.h 2010-10-22 14:44:16.000000000 +0200
|
||||
@@ -75,12 +75,14 @@
|
||||
This class extends the default DOMEntityResolver and implments the resolve entity method
|
||||
to support
|
||||
*/
|
||||
-class DataDirResolver : public DOMEntityResolver {
|
||||
+class DataDirResolver : public EntityResolver {
|
||||
public:
|
||||
/**
|
||||
*
|
||||
*/
|
||||
- DOMInputSource *resolveEntity (const XMLCh *const publicId, const XMLCh *const systemId, const XMLCh *const baseURI);
|
||||
+// DOMInputSource *resolveEntity (const XMLCh *const publicId, const XMLCh *const systemId, const XMLCh *const baseURI);
|
||||
+ InputSource *resolveEntity (const XMLCh *const publicId, const XMLCh *const systemId);
|
||||
+ DOMLSInput *resolveEntity (const XMLCh *const publicId, const XMLCh *const systemId, const XMLCh *const baseURI);
|
||||
};
|
||||
|
||||
/**
|
||||
@@ -120,7 +122,7 @@
|
||||
|
||||
static XmlProcessor* instance;
|
||||
|
||||
- DOMBuilder *parser;
|
||||
+ DOMLSParser *parser;
|
||||
};
|
||||
|
||||
/**
|
||||
--- src/probes/independent/XmlFileContentProbe.cpp.old 2010-10-22 14:49:22.000000000 +0200
|
||||
+++ src/probes/independent/XmlFileContentProbe.cpp 2010-10-22 14:51:39.000000000 +0200
|
||||
@@ -419,12 +419,24 @@
|
||||
return new DummyEntityResolver::DoNothingBinInputStream();
|
||||
}
|
||||
|
||||
+#if XERCES_VERSION_MAJOR < 3
|
||||
unsigned int DummyEntityResolver::DoNothingBinInputStream::curPos() const
|
||||
+#else
|
||||
+const XMLCh* DummyEntityResolver::DoNothingBinInputStream::getContentType() const
|
||||
+{
|
||||
+ return NULL;
|
||||
+}
|
||||
+XMLFilePos DummyEntityResolver::DoNothingBinInputStream::curPos() const
|
||||
+#endif
|
||||
{
|
||||
return 0;
|
||||
}
|
||||
|
||||
+#if XERCES_VERSION_MAJOR < 3
|
||||
unsigned int DummyEntityResolver::DoNothingBinInputStream::readBytes(XMLByte *const /*toFill*/, const unsigned int /*maxToRead*/)
|
||||
+#else
|
||||
+XMLSize_t DummyEntityResolver::DoNothingBinInputStream::readBytes(XMLByte *const toFill, XMLSize_t maxToRead)
|
||||
+#endif
|
||||
{
|
||||
return 0;
|
||||
}
|
||||
--- src/probes/independent/XmlFileContentProbe.h.old 2010-10-22 14:55:47.000000000 +0200
|
||||
+++ src/probes/independent/XmlFileContentProbe.h 2010-10-22 14:57:00.000000000 +0200
|
||||
@@ -134,8 +134,14 @@
|
||||
class DoNothingBinInputStream : public BinInputStream
|
||||
{
|
||||
public:
|
||||
+#if XERCES_VERSION_MAJOR < 3
|
||||
virtual unsigned int curPos() const;
|
||||
virtual unsigned int readBytes(XMLByte *const toFill, const unsigned int maxToRead);
|
||||
+#else
|
||||
+ virtual XMLFilePos curPos() const;
|
||||
+ virtual const XMLCh* getContentType() const;
|
||||
+ virtual XMLSize_t readBytes(XMLByte *const toFill, XMLSize_t maxToRead);
|
||||
+#endif
|
||||
};
|
||||
};
|
||||
|
||||
--- src/XmlCommon.cpp.old
|
||||
+++ src/XmlCommon.cpp
|
||||
@@ -546,7 +546,11 @@ void XmlCommon::AddSchemaLocation(XERCES_CPP_NAMESPACE_QUALIFIER DOMDocument *do
|
||||
string XmlCommon::GetNamespace(DOMElement *element) {
|
||||
|
||||
string xmlns = "";
|
||||
+#if XERCES_VERSION_MAJOR < 3
|
||||
xmlns = XmlCommon::ToString(element->getTypeInfo()->getNamespace());
|
||||
+#else
|
||||
+ xmlns = XmlCommon::ToString(element->getSchemaTypeInfo()->getTypeNamespace());
|
||||
+#endif
|
||||
if (xmlns.compare("") == 0) {
|
||||
xmlns = "";
|
||||
}
|
||||
|
|
@ -1,58 +0,0 @@
|
|||
--- src/probes/linux/rpmdb.h.old 2010-10-22 15:16:49.000000000 +0200
|
||||
+++ src/probes/linux/rpmdb.h 2010-10-22 15:22:09.000000000 +0200
|
||||
@@ -8,8 +8,8 @@
|
||||
*/
|
||||
|
||||
#include <assert.h>
|
||||
-#include "rpmlib.h"
|
||||
-#include "rpmsw.h"
|
||||
+/*#include <rpmlib.h>
|
||||
+#include <rpmsw.h>*/
|
||||
#include "db.h"
|
||||
|
||||
/*@-exportlocal@*/
|
||||
@@ -508,7 +508,7 @@
|
||||
* @param opx per-rpmdb accumulator index (aka rpmtsOpX)
|
||||
* @return per-rpmdb accumulator pointer
|
||||
*/
|
||||
-void * dbiStatsAccumulator(dbiIndex dbi, int opx)
|
||||
+rpmop_s * dbiStatsAccumulator(dbiIndex dbi, int opx)
|
||||
/*@*/;
|
||||
|
||||
#if !defined(SWIG)
|
||||
@@ -576,7 +576,7 @@
|
||||
/*@globals fileSystem, internalState @*/
|
||||
/*@modifies dbi, *dbcursor, fileSystem, internalState @*/
|
||||
{
|
||||
- void * sw = dbiStatsAccumulator(dbi, 16); /* RPMTS_OP_DBDEL */
|
||||
+ rpmop_s *sw = dbiStatsAccumulator(dbi, 16); /* RPMTS_OP_DBDEL */
|
||||
int rc;
|
||||
assert(key->data != NULL && key->size > 0);
|
||||
(void) rpmswEnter(sw, 0);
|
||||
@@ -600,7 +600,7 @@
|
||||
/*@globals fileSystem, internalState @*/
|
||||
/*@modifies dbi, *dbcursor, *key, *data, fileSystem, internalState @*/
|
||||
{
|
||||
- void * sw = dbiStatsAccumulator(dbi, 14); /* RPMTS_OP_DBGET */
|
||||
+ rpmop_s * sw = dbiStatsAccumulator(dbi, 14); /* RPMTS_OP_DBGET */
|
||||
int rc;
|
||||
assert((flags == DB_NEXT) || (key->data != NULL && key->size > 0));
|
||||
(void) rpmswEnter(sw, 0);
|
||||
@@ -625,7 +625,7 @@
|
||||
/*@globals fileSystem, internalState @*/
|
||||
/*@modifies dbi, *dbcursor, *key, *pkey, *data, fileSystem, internalState @*/
|
||||
{
|
||||
- void * sw = dbiStatsAccumulator(dbi, 14); /* RPMTS_OP_DBGET */
|
||||
+ rpmop_s * sw = dbiStatsAccumulator(dbi, 14); /* RPMTS_OP_DBGET */
|
||||
int rc;
|
||||
assert((flags == DB_NEXT) || (key->data != NULL && key->size > 0));
|
||||
(void) rpmswEnter(sw, 0);
|
||||
@@ -649,7 +649,7 @@
|
||||
/*@globals fileSystem, internalState @*/
|
||||
/*@modifies dbi, *dbcursor, *key, fileSystem, internalState @*/
|
||||
{
|
||||
- void * sw = dbiStatsAccumulator(dbi, 15); /* RPMTS_OP_DBPUT */
|
||||
+ rpmop_s * sw = dbiStatsAccumulator(dbi, 15); /* RPMTS_OP_DBPUT */
|
||||
int rc;
|
||||
assert(key->data != NULL && key->size > 0 && data->data != NULL && data->size > 0);
|
||||
(void) rpmswEnter(sw, 0);
|
||||
|
|
@ -1,11 +0,0 @@
|
|||
--- src/probes/linux/RPMInfoProbe.h.old 2010-10-22 15:12:50.000000000 +0200
|
||||
+++ src/probes/linux/RPMInfoProbe.h 2010-10-22 15:13:02.000000000 +0200
|
||||
@@ -36,7 +36,7 @@
|
||||
#include <rpm/rpmlib.h>
|
||||
#include <rpm/rpmio.h>
|
||||
#include <rpm/rpmts.h>
|
||||
-#include <rpm/rpmdb.h>
|
||||
+#include "rpmdb.h"
|
||||
#include <rpm/header.h>
|
||||
#include <rpm/rpmcli.h> // added for rpm query function
|
||||
#include <rpm/rpmds.h> // added for rpm query function
|
||||
|
|
@ -1,64 +0,0 @@
|
|||
# Copyright 1999-2010 Gentoo Foundation
|
||||
# Distributed under the terms of the GNU General Public License v2
|
||||
# $Header: $
|
||||
|
||||
EAPI=3
|
||||
|
||||
inherit eutils
|
||||
|
||||
DESCRIPTION="Free implementation of OVAL"
|
||||
HOMEPAGE="http://oval.mitre.org/language/interpreter.html"
|
||||
SRC_URI="mirror://sourceforge/${PN}/${P}-src.tar.bz2"
|
||||
|
||||
LICENSE="BSD"
|
||||
SLOT="0"
|
||||
KEYWORDS="~amd64 ~x86"
|
||||
IUSE="ldap rpm"
|
||||
|
||||
DEPEND="rpm? ( app-arch/rpm )
|
||||
dev-libs/libgcrypt
|
||||
dev-libs/libpcre
|
||||
dev-libs/xalan-c
|
||||
dev-libs/xerces-c
|
||||
ldap? ( net-nds/openldap )"
|
||||
RDEPEND="${DEPEND}"
|
||||
|
||||
S="${WORKDIR}/${P}-src"
|
||||
|
||||
src_prepare() {
|
||||
epatch "${FILESDIR}"/${P}-xerces3.patch
|
||||
epatch "${FILESDIR}"/${P}-strnicmp.patch
|
||||
if ! use ldap ; then
|
||||
einfo "Disabling LDAP probes"
|
||||
epatch "${FILESDIR}"/${P}-disable-ldap-probes.patch
|
||||
rm src/probes/independent/LDAPProbe.{cpp,h} || die
|
||||
fi
|
||||
|
||||
# rpm probes support is build dependant only on the presence of the rpm binary
|
||||
if use rpm ; then
|
||||
#Same problems as bug 274679, so i do a local copy of the header and patch it
|
||||
cp /usr/include/rpm/rpmdb.h src/probes/linux/ || die
|
||||
epatch "${FILESDIR}"/use_local_rpmdb.patch
|
||||
epatch "${FILESDIR}"/rpmdb.patch
|
||||
else
|
||||
einfo "Disabling rpm probes"
|
||||
sed -i 's/^PACKAGE_RPM/#PACKAGE_RPM/' project/linux/Makefile || die
|
||||
fi
|
||||
# same thing for dpkg, but package dpkg is not sufficient, needs app-arch/apt-pkg that is not on tree
|
||||
einfo "Disabling dpkg probes"
|
||||
sed -i 's/^PACKAGE_DPKG/#PACKAGE_DPKG/' project/linux/Makefile || die
|
||||
}
|
||||
|
||||
src_compile () {
|
||||
emake -C project/linux || die
|
||||
}
|
||||
|
||||
src_install () {
|
||||
# no make install in Makefile
|
||||
dosbin project/linux/Release/ovaldi project/linux/ovaldi.sh || die
|
||||
dodir /var/log/${PN} || die
|
||||
insinto /usr/share/${PN}
|
||||
doins xml/* || die
|
||||
dodoc docs/{README.txt,version.txt} || die
|
||||
doman docs/ovaldi.1 || die
|
||||
}
|
||||
|
|
@ -1,64 +0,0 @@
|
|||
# Copyright 1999-2010 Gentoo Foundation
|
||||
# Distributed under the terms of the GNU General Public License v2
|
||||
# $Header: $
|
||||
|
||||
EAPI=3
|
||||
|
||||
inherit eutils
|
||||
|
||||
DESCRIPTION="Free implementation of OVAL"
|
||||
HOMEPAGE="http://oval.mitre.org/language/interpreter.html"
|
||||
SRC_URI="mirror://sourceforge/${PN}/${P}-src.tar.bz2"
|
||||
|
||||
LICENSE="BSD"
|
||||
SLOT="0"
|
||||
KEYWORDS="~amd64 ~x86"
|
||||
IUSE="ldap rpm"
|
||||
|
||||
DEPEND="rpm? ( app-arch/rpm )
|
||||
dev-libs/libgcrypt
|
||||
dev-libs/libpcre
|
||||
dev-libs/xalan-c
|
||||
dev-libs/xerces-c
|
||||
ldap? ( net-nds/openldap )"
|
||||
RDEPEND="${DEPEND}"
|
||||
|
||||
S="${WORKDIR}/${P}-src"
|
||||
|
||||
src_prepare() {
|
||||
epatch "${FILESDIR}"/${P}-xerces3.patch
|
||||
epatch "${FILESDIR}"/${P}-strnicmp.patch
|
||||
if ! use ldap ; then
|
||||
einfo "Disabling LDAP probes"
|
||||
epatch "${FILESDIR}"/${P}-disable-ldap-probes.patch
|
||||
rm src/probes/independent/LDAPProbe.{cpp,h} || die
|
||||
fi
|
||||
|
||||
# rpm probes support is build dependant only on the presence of the rpm binary
|
||||
if use rpm ; then
|
||||
#Same problems as bug 274679, so i do a local copy of the header and patch it
|
||||
cp /usr/include/rpm/rpmdb.h src/probes/linux/ || die
|
||||
epatch "${FILESDIR}"/use_local_rpmdb.patch
|
||||
epatch "${FILESDIR}"/rpmdb.patch
|
||||
else
|
||||
einfo "Disabling rpm probes"
|
||||
sed -i 's/^PACKAGE_RPM/#PACKAGE_RPM/' project/linux/Makefile || die
|
||||
fi
|
||||
# same thing for dpkg, but package dpkg is not sufficient, needs app-arch/apt-pkg that is not on tree
|
||||
einfo "Disabling dpkg probes"
|
||||
sed -i 's/^PACKAGE_DPKG/#PACKAGE_DPKG/' project/linux/Makefile || die
|
||||
}
|
||||
|
||||
src_compile () {
|
||||
emake -C project/linux || die
|
||||
}
|
||||
|
||||
src_install () {
|
||||
# no make install in Makefile
|
||||
dosbin project/linux/Release/ovaldi project/linux/ovaldi.sh || die
|
||||
dodir /var/log/${PN} || die
|
||||
insinto /usr/share/${PN}
|
||||
doins xml/* || die
|
||||
dodoc docs/{README.txt,version.txt} || die
|
||||
doman docs/ovaldi.1 || die
|
||||
}
|
||||
Loading…
Reference in a new issue