compile fixes
authorDuncan Mac-Vicar P <dmacvicar@suse.de>
Tue, 29 Aug 2006 10:06:18 +0000 (10:06 +0000)
committerDuncan Mac-Vicar P <dmacvicar@suse.de>
Tue, 29 Aug 2006 10:06:18 +0000 (10:06 +0000)
devel/devel.dmacvicar/testbed.cc
testsuite/target/tests/import_old_sources_test.cc
tools/zmart/Makefile.am

index 1db0833..609262c 100644 (file)
@@ -27,8 +27,9 @@ int main()
   {
     ZYpp::Ptr z = getZYpp();
     
-    PublicKey key("repomd.xml.key");
-    cout << key << endl;
+    //PublicKey key("repomd.xml.key");
+    //cout << key << endl;
+    z->initializeTarget("/");
         
   }
   catch ( const Exception &e )
index a3d1ce0..b0abcab 100644 (file)
@@ -42,6 +42,13 @@ using namespace zypp::source;
 
 using namespace boost::filesystem;
 
+using namespace zypp::parser;
+
+void progress( int p )
+{
+  cout << p << "%" << endl;
+}
+
 /*
 =Type: UnitedLinux
 =URL: ftp://dist.suse.de//next-i386
@@ -65,6 +72,11 @@ struct OldPMSourceParser : public parser::tagfile::TagFileParser
 {
   source::SourceInfo result;
   
+  OldPMSourceParser( ParserProgress::Ptr pp ) : tagfile::TagFileParser( pp )
+  {
+    
+  }
+  
   virtual void beginParse()
   {
   }
@@ -116,7 +128,9 @@ static int import_old_sources()
       {
         DBG << dir_itr->leaf() << std::endl;
         Pathname full(Pathname(dir_path.string()) + dir_itr->leaf() + "/DESCRIPTION/description");
-        OldPMSourceParser parser;
+        ParserProgress::Ptr pptr;
+        pptr.reset( new ParserProgress( &progress ) );
+        OldPMSourceParser parser( pptr );
         MIL << "Going to parse " << full << std::endl;
         parser.parse(full);
         backend.storeSource(parser.result);
index 227d93e..5310814 100644 (file)
@@ -5,6 +5,14 @@ noinst_PROGRAMS = zmart
 
 ## ##################################################
 
+zmartincludedir = $(pkgincludedir)/source
+
+zmartinclude_HEADERS = \
+       AliveCursor.h \
+       zmart-keyring-callbacks.h  \
+       zmart-rpm-callbacks.h  \
+       zmart-source-callbacks.h
+
 INCLUDES = -I$(top_srcdir)/tools/zmart -I$(oldincludedir)/libxml2
 AM_LDFLAGS =