#ifndef WRITER_H
#define WRITER_H
-
#include <string>
#include <stdio.h>
#include <iostream>
#include <vector>
#include <map>
#include <set>
+#include <stdlib.h>
+#include <sys/types.h>
+#include "contents.h"
#include "cachedb.h"
-#include "multicompress.h"
#include "override.h"
#include "apt-ftparchive.h"
using std::endl;
using std::vector;
using std::map;
-
+
class FTWScanner
{
protected:
static int ScannerFile(const char *File, bool const &ReadLink);
bool Delink(string &FileName,const char *OriginalPath,
- unsigned long &Bytes,off_t const &FileSize);
+ unsigned long long &Bytes,unsigned long long const &FileSize);
inline void NewLine(unsigned const &Priority)
{
bool DoMD5;
bool DoSHA1;
bool DoSHA256;
+ bool DoSHA512;
unsigned long DeLinkLimit;
string InternalPrefix;
virtual ~FTWScanner() {};
};
+class MultiCompress;
+
class TranslationWriter
{
MultiCompress *Comp;
class SourcesWriter : public FTWScanner
{
+ CacheDB Db;
Override BOver;
Override SOver;
char *Buffer;
- unsigned long BufSize;
+ unsigned long long BufSize;
public:
bool NoOverride;
+ bool DoAlwaysStat;
// General options
string PathPrefix;
virtual bool DoPackage(string FileName);
- SourcesWriter(string const &BOverrides,string const &SOverrides,
+ SourcesWriter(string const &DB,string const &BOverrides,string const &SOverrides,
string const &ExtOverrides=string());
virtual ~SourcesWriter() {free(Buffer);};
};
string SHA256;
string SHA512;
// Limited by FileFd::Size()
- unsigned long size;
+ unsigned long long size;
~CheckSum() {};
};
map<string,struct CheckSum> CheckSums;