Переглянути джерело

Daniel Jacobowitz's gcc 2.95 C++ patch
Author: jgg
Date: 1999-07-20 05:53:32 GMT
Daniel Jacobowitz's gcc 2.95 C++ patch

Arch Librarian 22 роки тому
батько
коміт
727f18afe9

+ 2 - 2
apt-pkg/acquire-item.cc

@@ -1,6 +1,6 @@
 // -*- mode: cpp; mode: fold -*-
 // Description								/*{{{*/
-// $Id: acquire-item.cc,v 1.33 1999/07/10 05:32:25 jgg Exp $
+// $Id: acquire-item.cc,v 1.34 1999/07/20 05:53:32 jgg Exp $
 /* ######################################################################
 
    Acquire Item - Item to acquire
@@ -78,7 +78,7 @@ void pkgAcquire::Item::Failed(string Message,pkgAcquire::MethodConfig *Cnf)
 // ---------------------------------------------------------------------
 /* Stash status and the file size. Note that setting Complete means 
    sub-phases of the acquire process such as decompresion are operating */
-void pkgAcquire::Item::Start(string Message,unsigned long Size)
+void pkgAcquire::Item::Start(string /*Message*/,unsigned long Size)
 {
    Status = StatFetching;
    if (FileSize == 0 && Complete == false)

+ 2 - 2
apt-pkg/acquire-method.h

@@ -1,6 +1,6 @@
 // -*- mode: cpp; mode: fold -*-
 // Description								/*{{{*/
-// $Id: acquire-method.h,v 1.10 1999/01/27 02:48:52 jgg Exp $
+// $Id: acquire-method.h,v 1.11 1999/07/20 05:53:33 jgg Exp $
 /* ######################################################################
 
    Acquire Method - Method helper class + functions
@@ -52,7 +52,7 @@ class pkgAcqMethod
       
    // Handlers for messages
    virtual bool Configuration(string Message);
-   virtual bool Fetch(FetchItem *Item) {return true;};
+   virtual bool Fetch(FetchItem * /*Item*/) {return true;};
    
    // Outgoing messages
    void Fail(bool Transient = false);

+ 5 - 5
apt-pkg/acquire.h

@@ -1,6 +1,6 @@
 // -*- mode: cpp; mode: fold -*-
 // Description								/*{{{*/
-// $Id: acquire.h,v 1.23 1999/07/09 04:38:00 jgg Exp $
+// $Id: acquire.h,v 1.24 1999/07/20 05:53:33 jgg Exp $
 /* ######################################################################
 
    Acquire - File Acquiration
@@ -259,10 +259,10 @@ class pkgAcquireStatus
    virtual bool MediaChange(string Media,string Drive) = 0;
    
    // Each of these is called by the workers when an event occures
-   virtual void IMSHit(pkgAcquire::ItemDesc &Itm) {};
-   virtual void Fetch(pkgAcquire::ItemDesc &Itm) {};
-   virtual void Done(pkgAcquire::ItemDesc &Itm) {};
-   virtual void Fail(pkgAcquire::ItemDesc &Itm) {};
+   virtual void IMSHit(pkgAcquire::ItemDesc &/*Itm*/) {};
+   virtual void Fetch(pkgAcquire::ItemDesc &/*Itm*/) {};
+   virtual void Done(pkgAcquire::ItemDesc &/*Itm*/) {};
+   virtual void Fail(pkgAcquire::ItemDesc &/*Itm*/) {};
    virtual bool Pulse(pkgAcquire *Owner); // returns false on user cancel
    virtual void Start();
    virtual void Stop();

+ 2 - 2
apt-pkg/algorithms.cc

@@ -1,6 +1,6 @@
 // -*- mode: cpp; mode: fold -*-
 // Description								/*{{{*/
-// $Id: algorithms.cc,v 1.21 1999/07/09 04:11:33 jgg Exp $
+// $Id: algorithms.cc,v 1.22 1999/07/20 05:53:33 jgg Exp $
 /* ######################################################################
 
    Algorithms - A set of misc algorithms
@@ -36,7 +36,7 @@ pkgSimulate::pkgSimulate(pkgDepCache &Cache) : pkgPackageManager(Cache),
 
    // Fake a filename so as not to activate the media swapping
    string Jnk = "SIMULATE";
-   for (int I = 0; I != Cache.Head().PackageCount; I++)
+   for (unsigned int I = 0; I != Cache.Head().PackageCount; I++)
       FileNames[I] = Jnk;
 }
 									/*}}}*/

+ 2 - 2
apt-pkg/clean.h

@@ -1,6 +1,6 @@
 // -*- mode: cpp; mode: fold -*-
 // Description								/*{{{*/
-// $Id: clean.h,v 1.1 1999/02/01 08:11:57 jgg Exp $
+// $Id: clean.h,v 1.2 1999/07/20 05:53:33 jgg Exp $
 /* ######################################################################
 
    Clean - Clean out downloaded directories
@@ -20,7 +20,7 @@ class pkgArchiveCleaner
 {
    protected:
    
-   virtual void Erase(const char *File,string Pkg,string Ver,struct stat &St) {};
+   virtual void Erase(const char * /*File*/,string /*Pkg*/,string /*Ver*/,struct stat & /*St*/) {};
 
    public:   
    

+ 15 - 1
apt-pkg/contrib/fileutl.cc

@@ -1,6 +1,6 @@
 // -*- mode: cpp; mode: fold -*-
 // Description								/*{{{*/
-// $Id: fileutl.cc,v 1.28 1999/07/11 22:42:32 jgg Exp $
+// $Id: fileutl.cc,v 1.29 1999/07/20 05:53:33 jgg Exp $
 /* ######################################################################
    
    File Utilities
@@ -370,6 +370,20 @@ bool FileFd::Seek(unsigned long To)
       return _error->Error("Unable to seek to %u",To);
    }
    
+   return true;
+}
+									/*}}}*/
+// FileFd::Skip - Seek in the file					/*{{{*/
+// ---------------------------------------------------------------------
+/* */
+bool FileFd::Skip(unsigned long Over)
+{
+   if (lseek(iFd,Over,SEEK_CUR) < 0)
+   {
+      Flags |= Fail;
+      return _error->Error("Unable to seek ahead %u",Over);
+   }
+   
    return true;
 }
 									/*}}}*/

+ 2 - 1
apt-pkg/contrib/fileutl.h

@@ -1,6 +1,6 @@
 // -*- mode: cpp; mode: fold -*-
 // Description								/*{{{*/
-// $Id: fileutl.h,v 1.19 1999/07/11 22:42:32 jgg Exp $
+// $Id: fileutl.h,v 1.20 1999/07/20 05:53:33 jgg Exp $
 /* ######################################################################
    
    File Utilities
@@ -42,6 +42,7 @@ class FileFd
    bool Read(void *To,unsigned long Size);
    bool Write(const void *From,unsigned long Size);
    bool Seek(unsigned long To);
+   bool Skip(unsigned long To);
    bool Truncate(unsigned long To);
    unsigned long Tell();
    unsigned long Size();

+ 11 - 11
apt-pkg/orderlist.cc

@@ -1,6 +1,6 @@
 // -*- mode: cpp; mode: fold -*-
 // Description								/*{{{*/
-// $Id: orderlist.cc,v 1.7 1999/07/19 01:49:44 jgg Exp $
+// $Id: orderlist.cc,v 1.8 1999/07/20 05:53:33 jgg Exp $
 /* ######################################################################
 
    Order List - Represents and Manipulates an ordered list of packages.
@@ -150,7 +150,7 @@ bool pkgOrderList::OrderCritical()
 {
    FileList = 0;
    
-   Primary = &DepUnPackPre;
+   Primary = &pkgOrderList::DepUnPackPre;
    Secondary = 0;
    RevDepends = 0;
    Remove = 0;
@@ -176,10 +176,10 @@ bool pkgOrderList::OrderUnpack(string *FileList)
 {
    this->FileList = FileList;
 
-   Primary = &DepUnPackCrit;
-   Secondary = &DepConfigure;
-   RevDepends = &DepUnPackDep;
-   Remove = &DepRemove;
+   Primary = &pkgOrderList::DepUnPackCrit;
+   Secondary = &pkgOrderList::DepConfigure;
+   RevDepends = &pkgOrderList::DepUnPackDep;
+   Remove = &pkgOrderList::DepRemove;
    LoopCount = -1;
 
    // Sort
@@ -200,7 +200,7 @@ bool pkgOrderList::OrderUnpack(string *FileList)
       return false;
 
    LoopCount = 0;
-   Primary = &DepUnPackPre;
+   Primary = &pkgOrderList::DepUnPackPre;
    if (DoRun() == false)
       return false;
 
@@ -222,7 +222,7 @@ bool pkgOrderList::OrderUnpack(string *FileList)
 bool pkgOrderList::OrderConfigure()
 {
    FileList = 0;
-   Primary = &DepConfigure;
+   Primary = &pkgOrderList::DepConfigure;
    Secondary = 0;
    RevDepends = 0;
    Remove = 0;
@@ -475,8 +475,8 @@ bool pkgOrderList::VisitNode(PkgIterator Pkg)
    DepFunc Old = Primary;
    
    // Perform immedate configuration of the package if so flagged.
-   if (IsFlag(Pkg,Immediate) == true && Primary != &DepUnPackPre)
-      Primary = &DepUnPackPreD;
+   if (IsFlag(Pkg,Immediate) == true && Primary != &pkgOrderList::DepUnPackPre)
+      Primary = &pkgOrderList::DepUnPackPreD;
 
    if (IsNow(Pkg) == true)
    {
@@ -589,7 +589,7 @@ bool pkgOrderList::DepUnPackCrit(DepIterator D)
 	 DepFunc Old = Primary;
 	 bool Res = false;
 	 if (D->Type == pkgCache::Dep::PreDepends)
-	    Primary = &DepUnPackPreD;
+	    Primary = &pkgOrderList::DepUnPackPreD;
 	 Res = VisitProvides(D,true);
 	 Primary = Old;
 	 if (Res == false)

+ 2 - 2
apt-pkg/packagemanager.h

@@ -1,6 +1,6 @@
 // -*- mode: cpp; mode: fold -*-
 // Description								/*{{{*/
-// $Id: packagemanager.h,v 1.9 1999/07/09 04:11:34 jgg Exp $
+// $Id: packagemanager.h,v 1.10 1999/07/20 05:53:33 jgg Exp $
 /* ######################################################################
 
    Package Manager - Abstacts the package manager
@@ -74,7 +74,7 @@ class pkgPackageManager
    // The Actuall installation implementation
    virtual bool Install(PkgIterator /*Pkg*/,string /*File*/) {return false;};
    virtual bool Configure(PkgIterator /*Pkg*/) {return false;};
-   virtual bool Remove(PkgIterator /*Pkg*/,bool Purge=false) {return false;};
+   virtual bool Remove(PkgIterator /*Pkg*/,bool /*Purge*/=false) {return false;};
    virtual bool Go() {return true;};
    virtual void Reset() {};
    

+ 2 - 2
apt-pkg/sourcelist.cc

@@ -1,6 +1,6 @@
 // -*- mode: cpp; mode: fold -*-
 // Description								/*{{{*/
-// $Id: sourcelist.cc,v 1.13 1999/04/07 05:30:17 jgg Exp $
+// $Id: sourcelist.cc,v 1.14 1999/07/20 05:53:33 jgg Exp $
 /* ######################################################################
 
    List of Sources
@@ -73,7 +73,7 @@ bool pkgSourceList::Read(string File)
       string Type;
       string URI;
       Item Itm;
-      char *C = Buffer;
+      const char *C = Buffer;
       if (ParseQuoteWord(C,Type) == false)
 	 return _error->Error("Malformed line %u in source list %s (type)",CurLine,File.c_str());
       if (ParseQuoteWord(C,URI) == false)

+ 2 - 2
apt-pkg/srcrecords.h

@@ -1,6 +1,6 @@
 // -*- mode: cpp; mode: fold -*-
 // Description								/*{{{*/
-// $Id: srcrecords.h,v 1.3 1999/04/07 05:30:18 jgg Exp $
+// $Id: srcrecords.h,v 1.4 1999/07/20 05:53:33 jgg Exp $
 /* ######################################################################
    
    Source Package Records - Allows access to source package records
@@ -52,7 +52,7 @@ class pkgSrcRecords
       virtual string Maintainer() = 0;
       virtual string Section() = 0;
       virtual const char **Binaries() = 0;
-      virtual bool Files(vector<File> &F) = 0;
+      virtual bool Files(vector<pkgSrcRecords::File> &F) = 0;
       
       Parser(FileFd *File,pkgSourceList::const_iterator SrcItem) : File(File), 
              SrcItem(SrcItem) {};

+ 0 - 2
buildlib/config.h.in

@@ -1,5 +1,3 @@
-/* buildlib/config.h.in.  Generated automatically from configure.in by autoheader.  */
-
 /* Define if your processor stores words with the most significant
    byte first (like Motorola and SPARC, unlike Intel and VAX).  */
 #undef WORDS_BIGENDIAN