]> git.saurik.com Git - android/aapt.git/blame_incremental - Main.h
Merge "Fix "Too many open files" error for aapt built with Mac OS X SDK 10.6."
[android/aapt.git] / Main.h
... / ...
CommitLineData
1//
2// Copyright 2006 The Android Open Source Project
3//
4// Some global defines that don't really merit their own header.
5//
6#ifndef __MAIN_H
7#define __MAIN_H
8
9#include <utils/Log.h>
10#include <utils/threads.h>
11#include <utils/List.h>
12#include <utils/Errors.h>
13#include "Bundle.h"
14#include "AaptAssets.h"
15#include "ZipFile.h"
16
17
18/* Benchmarking Flag */
19//#define BENCHMARK 1
20
21#if BENCHMARK
22 #include <time.h>
23#endif /* BENCHMARK */
24
25extern int doVersion(Bundle* bundle);
26extern int doList(Bundle* bundle);
27extern int doDump(Bundle* bundle);
28extern int doAdd(Bundle* bundle);
29extern int doRemove(Bundle* bundle);
30extern int doPackage(Bundle* bundle);
31extern int doCrunch(Bundle* bundle);
32
33extern int calcPercent(long uncompressedLen, long compressedLen);
34
35extern android::status_t writeAPK(Bundle* bundle,
36 const sp<AaptAssets>& assets,
37 const android::String8& outputFile);
38
39extern android::status_t updatePreProcessedCache(Bundle* bundle);
40
41extern android::status_t buildResources(Bundle* bundle,
42 const sp<AaptAssets>& assets);
43
44extern android::status_t writeResourceSymbols(Bundle* bundle,
45 const sp<AaptAssets>& assets, const String8& pkgName, bool includePrivate);
46
47extern android::status_t writeProguardFile(Bundle* bundle, const sp<AaptAssets>& assets);
48
49extern bool isValidResourceType(const String8& type);
50
51ssize_t processAssets(Bundle* bundle, ZipFile* zip, const sp<AaptAssets>& assets);
52
53extern status_t filterResources(Bundle* bundle, const sp<AaptAssets>& assets);
54
55int dumpResources(Bundle* bundle);
56
57String8 getAttribute(const ResXMLTree& tree, const char* ns,
58 const char* attr, String8* outError);
59
60status_t writeDependencyPreReqs(Bundle* bundle, const sp<AaptAssets>& assets,
61 FILE* fp, bool includeRaw);
62#endif // __MAIN_H