compiling optimization to get smaller library's size

This commit is contained in:
zhengshuxin 2019-05-19 16:54:20 +08:00
parent b71b8840bf
commit b1b7d08a0c
163 changed files with 465 additions and 130 deletions

View File

@ -25,6 +25,10 @@ CFLAGS = -c -g -W \
-Winvalid-pch \
-DACL_PREPARE_COMPILE \
#-DACL_CLIENT_ONLY \
#-DACL_REDIS_DISABLE \
#-DACL_BEANSTALK_DISABLE \
#-DACL_DB_DISABLE \
#-DACL_MIME_DISABLE \
#-DUSE_DYNAMIC
# -Wcast-align
#-Wcast-qual

View File

@ -6,7 +6,7 @@
#include "../stdlib/noncopyable.hpp"
#include "../stream/socket_stream.hpp"
#ifndef ACL_CLIENT_ONLY
#if !defined(ACL_CLIENT_ONLY) && !defined(ACL_BEANSTALK_DISABLE)
struct ACL_ARGV;
@ -311,4 +311,4 @@ private:
} // namespace acl
#endif // ACL_CLIENT_ONLY
#endif // !defined(ACL_CLIENT_ONLY) && !defined(ACL_BEANSTALK_DISABLE)

View File

@ -3,7 +3,7 @@
#include "../stdlib/noncopyable.hpp"
#include <map>
#ifndef ACL_CLIENT_ONLY
#if !defined(ACL_CLIENT_ONLY) && !defined(ACL_BEANSTALK_DISABLE)
namespace acl {
@ -53,4 +53,4 @@ private:
} // namespace acl
#endif // ACL_CLIENT_ONLY
#endif // !defined(ACL_CLIENT_ONLY) && !defined(ACL_BEANSTALK_DISABLE)

View File

@ -2,6 +2,8 @@
#include "../acl_cpp_define.hpp"
#include "../stdlib/noncopyable.hpp"
#if !defined(ACL_DB_DISABLE)
namespace acl
{
@ -13,3 +15,5 @@ public:
};
}
#endif // !defined(ACL_DB_DISABLE)

View File

@ -5,6 +5,8 @@
#include "../stdlib/noncopyable.hpp"
#include "../connpool/connect_client.hpp"
#if !defined(ACL_DB_DISABLE)
namespace acl {
/**
@ -496,3 +498,5 @@ protected:
};
} // namespace acl
#endif // !defined(ACL_DB_DISABLE)

View File

@ -3,7 +3,7 @@
#include "../stdlib/string.hpp"
#include "../db/db_handle.hpp"
#ifndef ACL_CLIENT_ONLY
#if !defined(ACL_CLIENT_ONLY) && !defined(ACL_DB_DISABLE)
typedef struct st_mysql MYSQL;
@ -164,4 +164,4 @@ private:
} // namespace acl
#endif // ACL_CLIENT_ONLY
#endif // !defined(ACL_CLIENT_ONLY) && !defined(ACL_DB_DISABLE)

View File

@ -3,7 +3,7 @@
#include "../stdlib/string.hpp"
#include "../db/db_handle.hpp"
#ifndef ACL_CLIENT_ONLY
#if !defined(ACL_CLIENT_ONLY) && !defined(ACL_DB_DISABLE)
typedef struct pg_conn PGconn;
@ -106,4 +106,4 @@ private:
} // namespace acl
#endif // ACL_CLIENT_ONLY
#endif // !defined(ACL_CLIENT_ONLY) && !defined(ACL_DB_DISABLE)

View File

@ -4,6 +4,8 @@
#include "../db/db_handle.hpp"
#include "../connpool/connect_pool.hpp"
#if !defined(ACL_DB_DISABLE)
namespace acl {
class db_handle;
@ -66,3 +68,5 @@ public:
};
} // namespace acl
#endif // !defined(ACL_DB_DISABLE)

View File

@ -4,6 +4,8 @@
#include "../ipc/ipc_service.hpp"
#include "../stdlib/string.hpp"
#if !defined(ACL_DB_DISABLE)
namespace acl {
typedef enum
@ -115,3 +117,5 @@ private:
};
} // namespace acl
#endif // !defined(ACL_DB_DISABLE)

View File

@ -3,7 +3,7 @@
#include "../stdlib/string.hpp"
#include "../db/db_service.hpp"
#ifndef ACL_CLIENT_ONLY
#if !defined(ACL_CLIENT_ONLY) && !defined(ACL_DB_DISABLE)
namespace acl {
@ -57,4 +57,4 @@ private:
}
#endif // ACL_CLIENT_ONLY
#endif // !defined(ACL_CLIENT_ONLY) && !defined(ACL_DB_DISABLE)

View File

@ -3,6 +3,8 @@
#include "../stdlib/string.hpp"
#include "../db/db_service.hpp"
#if !defined(ACL_DB_DISABLE)
namespace acl {
class ACL_CPP_API db_service_sqlite : public db_service
@ -33,3 +35,5 @@ private:
};
}
#endif // !defined(ACL_DB_DISABLE)

View File

@ -3,6 +3,8 @@
#include "../stdlib/string.hpp"
#include "../db/db_handle.hpp"
#if !defined(ACL_DB_DISABLE)
typedef struct sqlite3 sqlite3;
namespace acl {
@ -169,3 +171,5 @@ private:
};
} // namespace acl
#endif // !defined(ACL_DB_DISABLE)

View File

@ -1,7 +1,7 @@
#pragma once
#include "../acl_cpp_define.hpp"
#ifndef ACL_CLIENT_ONLY
#if !defined(ACL_CLIENT_ONLY) && !defined(ACL_DB_DISABLE)
namespace acl {
@ -152,4 +152,4 @@ private:
} // namespace acl
#endif // ACL_CLIENT_ONLY
#endif // !defined(ACL_CLIENT_ONLY) && !defined(ACL_DB_DISABLE)

View File

@ -4,7 +4,7 @@
#include "../stdlib/string.hpp"
#include "../connpool/connect_manager.hpp"
#ifndef ACL_CLIENT_ONLY
#if !defined(ACL_CLIENT_ONLY) && !defined(ACL_DB_DISABLE)
namespace acl {
@ -61,4 +61,4 @@ private:
} // namespace acl
#endif // ACL_CLIENT_ONLY
#endif // !defined(ACL_CLIENT_ONLY) && !defined(ACL_DB_DISABLE)

View File

@ -2,7 +2,7 @@
#include "../acl_cpp_define.hpp"
#include "../db/db_pool.hpp"
#ifndef ACL_CLIENT_ONLY
#if !defined(ACL_CLIENT_ONLY) && !defined(ACL_DB_DISABLE)
namespace acl {
@ -49,4 +49,4 @@ private:
} // namespace acl
#endif // ACL_CLIENT_ONLY
#endif // !defined(ACL_CLIENT_ONLY) && !defined(ACL_DB_DISABLE)

View File

@ -1,7 +1,7 @@
#pragma once
#include "../acl_cpp_define.hpp"
#ifndef ACL_CLIENT_ONLY
#if !defined(ACL_CLIENT_ONLY) && !defined(ACL_DB_DISABLE)
namespace acl {
@ -130,4 +130,4 @@ private:
} // namespace acl
#endif // ACL_CLIENT_ONLY
#endif // !defined(ACL_CLIENT_ONLY) && !defined(ACL_DB_DISABLE)

View File

@ -4,7 +4,7 @@
#include "../stdlib/string.hpp"
#include "../connpool/connect_manager.hpp"
#ifndef ACL_CLIENT_ONLY
#if !defined(ACL_CLIENT_ONLY) && !defined(ACL_DB_DISABLE)
namespace acl {
@ -40,4 +40,4 @@ private:
} // namespace acl
#endif // ACL_CLIENT_ONLY
#endif // !defined(ACL_CLIENT_ONLY) && !defined(ACL_DB_DISABLE)

View File

@ -2,7 +2,7 @@
#include "../acl_cpp_define.hpp"
#include "../db/db_pool.hpp"
#ifndef ACL_CLIENT_ONLY
#if !defined(ACL_CLIENT_ONLY) && !defined(ACL_DB_DISABLE)
namespace acl {
@ -25,4 +25,4 @@ private:
} // namespace acl
#endif // ACL_CLIENT_ONLY
#endif // !defined(ACL_CLIENT_ONLY) && !defined(ACL_DB_DISABLE)

View File

@ -4,6 +4,8 @@
#include "../stdlib/noncopyable.hpp"
#include <map>
#if !defined(ACL_DB_DISABLE)
namespace acl
{
@ -196,3 +198,5 @@ private:
};
} // namespace acl
#endif // !defined(ACL_DB_DISABLE)

View File

@ -3,6 +3,8 @@
#include "../stdlib/string.hpp"
#include "db_cursor.hpp"
#if !defined(ACL_DB_DISABLE)
struct sqlite3_stmt;
namespace acl
@ -91,3 +93,5 @@ private:
};
}
#endif // !defined(ACL_DB_DISABLE)

View File

@ -2,6 +2,8 @@
#include "../acl_cpp_define.hpp"
#include "../connpool/connect_manager.hpp"
#if !defined(ACL_DB_DISABLE)
namespace acl {
class ACL_CPP_API sqlite_manager : public connect_manager
@ -39,3 +41,5 @@ private:
};
} // namespace acl
#endif // !defined(ACL_DB_DISABLE)

View File

@ -2,6 +2,8 @@
#include "../acl_cpp_define.hpp"
#include "../db/db_pool.hpp"
#if !defined(ACL_DB_DISABLE)
namespace acl {
class db_handle;
@ -31,3 +33,5 @@ private:
};
} // namespace acl
#endif // !defined(ACL_DB_DISABLE)

View File

@ -3,6 +3,8 @@
#include "../stdlib/string.hpp"
#include "../stdlib/noncopyable.hpp"
#if !defined(ACL_MIME_DISABLE)
namespace acl {
/**
@ -81,3 +83,5 @@ private:
};
} // namespace acl
#endif // !defined(ACL_MIME_DISABLE)

View File

@ -7,6 +7,8 @@
#include "../mime/mime_attach.hpp"
#include "http_type.hpp"
#if !defined(ACL_MIME_DISABLE)
struct MIME_STATE;
struct MIME_NODE;
@ -128,3 +130,5 @@ private:
};
} // namespace acl
#endif // !defined(ACL_MIME_DISABLE)

View File

@ -5,6 +5,8 @@
#include <string>
#include "mime_head.hpp"
#if !defined(ACL_MIME_DISABLE)
struct MIME_STATE;
namespace acl {
@ -478,3 +480,5 @@ private:
};
} // namespace acl
#endif // !defined(ACL_MIME_DISABLE)

View File

@ -3,6 +3,8 @@
#include "../stdlib/string.hpp"
#include "mime_node.hpp"
#if !defined(ACL_MIME_DISABLE)
namespace acl {
class ACL_CPP_API mime_attach : public mime_node
@ -25,3 +27,5 @@ private:
};
} // namespace acl
#endif // !defined(ACL_MIME_DISABLE)

View File

@ -2,6 +2,8 @@
#include "../acl_cpp_define.hpp"
#include "mime_code.hpp"
#if !defined(ACL_MIME_DISABLE)
namespace acl {
class ACL_CPP_API mime_base64 : public mime_code
@ -34,3 +36,5 @@ public:
};
} // namespace acl
#endif // !defined(ACL_MIME_DISABLE)

View File

@ -2,6 +2,8 @@
#include "../acl_cpp_define.hpp"
#include "mime_node.hpp"
#if !defined(ACL_MIME_DISABLE)
struct MIME_NODE;
namespace acl {
@ -119,3 +121,5 @@ private:
};
} // namespace acl
#endif // !defined(ACL_MIME_DISABLE)

View File

@ -2,6 +2,8 @@
#include "../acl_cpp_define.hpp"
#include "../stdlib/pipe_stream.hpp"
#if !defined(ACL_MIME_DISABLE)
namespace acl {
class string;
@ -157,3 +159,5 @@ private:
};
} // namespace acl
#endif // !defined(ACL_MIME_DISABLE)

View File

@ -1,6 +1,8 @@
#pragma once
#include "../acl_cpp_define.hpp"
#if !defined(ACL_MIME_DISABLE)
/*
* Content types and subtypes that we care about, either because we have to,
* or because we want to filter out broken MIME messages.
@ -45,3 +47,5 @@
#define MIME_MIN MIME_CTYPE_OTHER
#define MIME_MAX MIME_ENC_MAX
#endif // !defined(ACL_MIME_DISABLE)

View File

@ -4,6 +4,8 @@
#include "../stdlib/noncopyable.hpp"
#include <list>
#if !defined(ACL_MIME_DISABLE)
namespace acl {
typedef struct HEADER
@ -70,3 +72,5 @@ private:
};
} // namespace acl
#endif // !defined(ACL_MIME_DISABLE)

View File

@ -2,6 +2,8 @@
#include "../acl_cpp_define.hpp"
#include "mime_node.hpp"
#if !defined(ACL_MIME_DISABLE)
namespace acl {
class ACL_CPP_API mime_image : public mime_node
@ -20,3 +22,5 @@ public:
};
} // namespace acl
#endif // !defined(ACL_MIME_DISABLE)

View File

@ -5,6 +5,8 @@
#include "../stdlib/noncopyable.hpp"
#include "../stdlib/string.hpp"
#if !defined(ACL_MIME_DISABLE)
struct MIME_NODE;
namespace acl {
@ -269,3 +271,5 @@ protected:
};
} // namespace acl
#endif // !defined(ACL_MIME_DISABLE)

View File

@ -2,6 +2,8 @@
#include "../acl_cpp_define.hpp"
#include "mime_code.hpp"
#if !defined(ACL_MIME_DISABLE)
namespace acl {
class string;
@ -117,3 +119,4 @@ private:
} // namespace acl
#endif // !defined(ACL_MIME_DISABLE)

View File

@ -2,6 +2,8 @@
#include "../acl_cpp_define.hpp"
#include "mime_code.hpp"
#if !defined(ACL_MIME_DISABLE)
namespace acl {
class ACL_CPP_API mime_uucode : public mime_code
@ -37,3 +39,5 @@ private:
};
} // namespace acl
#endif // !defined(ACL_MIME_DISABLE)

View File

@ -2,6 +2,8 @@
#include "../acl_cpp_define.hpp"
#include "mime_code.hpp"
#if !defined(ACL_MIME_DISABLE)
namespace acl {
class ACL_CPP_API mime_xxcode : public mime_code
@ -37,3 +39,5 @@ private:
};
} // namespace acl
#endif // !defined(ACL_MIME_DISABLE)

View File

@ -3,6 +3,8 @@
#include "../stdlib/noncopyable.hpp"
#include <list>
#if !defined(ACL_MIME_DISABLE)
namespace acl {
class string;
@ -137,3 +139,5 @@ public:
};
} // namespace acl
#endif // !defined(ACL_MIME_DISABLE)

View File

@ -4,6 +4,8 @@
#include <list>
#include <time.h>
#if !defined(ACL_MIME_DISABLE)
namespace acl {
/**
@ -100,3 +102,5 @@ private:
};
} // namespace acl
#endif // !defined(ACL_MIME_DISABLE)

View File

@ -16,7 +16,7 @@
#include "redis_geo.hpp"
#include "redis_stream.hpp"
#ifndef ACL_CLIENT_ONLY
#if !defined(ACL_CLIENT_ONLY) && !defined(ACL_REDIS_DISABLE)
namespace acl
{
@ -71,4 +71,4 @@ public:
} // namespace acl
#endif // ACL_CLIENT_ONLY
#endif // !defined(ACL_CLIENT_ONLY) && !defined(ACL_REDIS_DISABLE)

View File

@ -5,7 +5,7 @@
#include "../stdlib/string.hpp"
#include "../connpool/connect_client.hpp"
#ifndef ACL_CLIENT_ONLY
#if !defined(ACL_CLIENT_ONLY) && !defined(ACL_REDIS_DISABLE)
namespace acl
{
@ -188,4 +188,4 @@ private:
} // end namespace acl
#endif // ACL_CLIENT_ONLY
#endif // !defined(ACL_CLIENT_ONLY) && !defined(ACL_REDIS_DISABLE)

View File

@ -5,7 +5,7 @@
#include "../stdlib/string.hpp"
#include "../connpool/connect_manager.hpp"
#ifndef ACL_CLIENT_ONLY
#if !defined(ACL_CLIENT_ONLY) && !defined(ACL_REDIS_DISABLE)
namespace acl
{
@ -193,4 +193,4 @@ private:
} // namespace acl
#endif // ACL_CLIENT_ONLY
#endif // !defined(ACL_CLIENT_ONLY) && !defined(ACL_REDIS_DISABLE)

View File

@ -2,7 +2,7 @@
#include "../acl_cpp_define.hpp"
#include "../connpool/connect_pool.hpp"
#ifndef ACL_CLIENT_ONLY
#if !defined(ACL_CLIENT_ONLY) && !defined(ACL_REDIS_DISABLE)
namespace acl
{
@ -73,4 +73,4 @@ private:
} // namespace acl
#endif // ACL_CLIENT_ONLY
#endif // !defined(ACL_CLIENT_ONLY) && !defined(ACL_REDIS_DISABLE)

View File

@ -6,7 +6,7 @@
#include "../stdlib/string.hpp"
#include "redis_command.hpp"
#ifndef ACL_CLIENT_ONLY
#if !defined(ACL_CLIENT_ONLY) && !defined(ACL_REDIS_DISABLE)
namespace acl
{
@ -315,5 +315,4 @@ private:
} // namespace acl
#endif // ACL_CLIENT_ONLY
#endif // !defined(ACL_CLIENT_ONLY) && !defined(ACL_REDIS_DISABLE)

View File

@ -6,7 +6,7 @@
#include <vector>
#include "redis_result.hpp"
#ifndef ACL_CLIENT_ONLY
#if !defined(ACL_CLIENT_ONLY) && !defined(ACL_REDIS_DISABLE)
namespace acl
{
@ -443,4 +443,4 @@ protected:
} // namespace acl
#endif // ACL_CLIENT_ONLY
#endif // !defined(ACL_CLIENT_ONLY) && !defined(ACL_REDIS_DISABLE)

View File

@ -2,7 +2,7 @@
#include "../acl_cpp_define.hpp"
#include "redis_command.hpp"
#ifndef ACL_CLIENT_ONLY
#if !defined(ACL_CLIENT_ONLY) && !defined(ACL_REDIS_DISABLE)
namespace acl
{
@ -84,4 +84,4 @@ public:
} // namespace acl
#endif // ACL_CLIENT_ONLY
#endif // !defined(ACL_CLIENT_ONLY) && !defined(ACL_REDIS_DISABLE)

View File

@ -5,7 +5,7 @@
#include "../stdlib/string.hpp"
#include "redis_command.hpp"
#ifndef ACL_CLIENT_ONLY
#if !defined(ACL_CLIENT_ONLY) && !defined(ACL_REDIS_DISABLE)
namespace acl
{
@ -331,4 +331,4 @@ private:
} // namespace acl
#endif // ACL_CLIENT_ONLY
#endif // !defined(ACL_CLIENT_ONLY) && !defined(ACL_REDIS_DISABLE)

View File

@ -5,7 +5,7 @@
#include "../stdlib/string.hpp"
#include "redis_command.hpp"
#ifndef ACL_CLIENT_ONLY
#if !defined(ACL_CLIENT_ONLY) && !defined(ACL_REDIS_DISABLE)
namespace acl
{
@ -362,4 +362,4 @@ public:
} // namespace acl
#endif // ACL_CLIENT_ONLY
#endif // !defined(ACL_CLIENT_ONLY) && !defined(ACL_REDIS_DISABLE)

View File

@ -4,7 +4,7 @@
#include "../stdlib/string.hpp"
#include "redis_command.hpp"
#ifndef ACL_CLIENT_ONLY
#if !defined(ACL_CLIENT_ONLY) && !defined(ACL_REDIS_DISABLE)
namespace acl
{
@ -87,4 +87,4 @@ public:
} // namespace acl
#endif // ACL_CLIENT_ONLY
#endif // !defined(ACL_CLIENT_ONLY) && !defined(ACL_REDIS_DISABLE)

View File

@ -4,7 +4,7 @@
#include "../stdlib/string.hpp"
#include "redis_command.hpp"
#ifndef ACL_CLIENT_ONLY
#if !defined(ACL_CLIENT_ONLY) && !defined(ACL_REDIS_DISABLE)
namespace acl {
@ -407,4 +407,4 @@ public:
} // namespace acl
#endif // ACL_CLIENT_ONLY
#endif // !defined(ACL_CLIENT_ONLY) && !defined(ACL_REDIS_DISABLE)

View File

@ -2,7 +2,7 @@
#include "../acl_cpp_define.hpp"
#include "redis_command.hpp"
#ifndef ACL_CLIENT_ONLY
#if !defined(ACL_CLIENT_ONLY) && !defined(ACL_REDIS_DISABLE)
namespace acl
{
@ -442,4 +442,4 @@ private:
} // namespace acl
#endif // ACL_CLIENT_ONLY
#endif // !defined(ACL_CLIENT_ONLY) && !defined(ACL_REDIS_DISABLE)

View File

@ -2,7 +2,7 @@
#include "../acl_cpp_define.hpp"
#include "../stdlib/string.hpp"
#ifndef ACL_CLIENT_ONLY
#if !defined(ACL_CLIENT_ONLY) && !defined(ACL_REDIS_DISABLE)
namespace acl
{
@ -37,4 +37,4 @@ public:
}
#endif // ACL_CLIENT_ONLY
#endif // !defined(ACL_CLIENT_ONLY) && !defined(ACL_REDIS_DISABLE)

View File

@ -5,7 +5,7 @@
#include "../stdlib/string.hpp"
#include "../stdlib/noncopyable.hpp"
#ifndef ACL_CLIENT_ONLY
#if !defined(ACL_CLIENT_ONLY) && !defined(ACL_REDIS_DISABLE)
namespace acl
{
@ -265,4 +265,4 @@ private:
} // namespace acl
#endif // ACL_CLIENT_ONLY
#endif // !defined(ACL_CLIENT_ONLY) && !defined(ACL_REDIS_DISABLE)

View File

@ -4,7 +4,7 @@
#include <map>
#include "redis_command.hpp"
#ifndef ACL_CLIENT_ONLY
#if !defined(ACL_CLIENT_ONLY) && !defined(ACL_REDIS_DISABLE)
namespace acl
{
@ -205,4 +205,4 @@ private:
} // namespace acl
#endif // ACL_CLIENT_ONLY
#endif // !defined(ACL_CLIENT_ONLY) && !defined(ACL_REDIS_DISABLE)

View File

@ -3,7 +3,7 @@
#include "../stdlib/noncopyable.hpp"
#include <vector>
#ifndef ACL_CLIENT_ONLY
#if !defined(ACL_CLIENT_ONLY) && !defined(ACL_REDIS_DISABLE)
namespace acl
{
@ -225,4 +225,4 @@ private:
} // namespace acl
#endif // ACL_CLIENT_ONLY
#endif // !defined(ACL_CLIENT_ONLY) && !defined(ACL_REDIS_DISABLE)

View File

@ -5,7 +5,7 @@
#include "../stdlib/string.hpp"
#include "redis_command.hpp"
#ifndef ACL_CLIENT_ONLY
#if !defined(ACL_CLIENT_ONLY) && !defined(ACL_REDIS_DISABLE)
namespace acl
{
@ -119,4 +119,4 @@ private:
}
#endif // ACL_CLIENT_ONLY
#endif // !defined(ACL_CLIENT_ONLY) && !defined(ACL_REDIS_DISABLE)

View File

@ -4,7 +4,7 @@
#include "../stdlib/string.hpp"
#include "redis_command.hpp"
#ifndef ACL_CLIENT_ONLY
#if !defined(ACL_CLIENT_ONLY) && !defined(ACL_REDIS_DISABLE)
namespace acl
{
@ -164,4 +164,4 @@ private:
} // namespace acl
#endif // ACL_CLIENT_ONLY
#endif // !defined(ACL_CLIENT_ONLY) && !defined(ACL_REDIS_DISABLE)

View File

@ -5,7 +5,7 @@
#include "redis_master.hpp"
#include "redis_slave.hpp"
#ifndef ACL_CLIENT_ONLY
#if !defined(ACL_CLIENT_ONLY) && !defined(ACL_REDIS_DISABLE)
namespace acl
{
@ -39,4 +39,4 @@ public:
}
#endif // ACL_CLIENT_ONLY
#endif // !defined(ACL_CLIENT_ONLY) && !defined(ACL_REDIS_DISABLE)

View File

@ -4,7 +4,7 @@
#include "../stdlib/string.hpp"
#include "redis_command.hpp"
#ifndef ACL_CLIENT_ONLY
#if !defined(ACL_CLIENT_ONLY) && !defined(ACL_REDIS_DISABLE)
namespace acl
{
@ -215,4 +215,4 @@ public:
} // namespace acl
#endif // ACL_CLIENT_ONLY
#endif // !defined(ACL_CLIENT_ONLY) && !defined(ACL_REDIS_DISABLE)

View File

@ -4,7 +4,7 @@
#include "../stdlib/string.hpp"
#include "redis_command.hpp"
#ifndef ACL_CLIENT_ONLY
#if !defined(ACL_CLIENT_ONLY) && !defined(ACL_REDIS_DISABLE)
namespace acl
{
@ -357,4 +357,4 @@ public:
} // namespace acl
#endif // ACL_CLIENT_ONLY
#endif // !defined(ACL_CLIENT_ONLY) && !defined(ACL_REDIS_DISABLE)

View File

@ -2,7 +2,7 @@
#include "../acl_cpp_define.hpp"
#include "../stdlib/string.hpp"
#ifndef ACL_CLIENT_ONLY
#if !defined(ACL_CLIENT_ONLY) && !defined(ACL_REDIS_DISABLE)
namespace acl
{
@ -37,4 +37,4 @@ public:
}
#endif // ACL_CLIENT_ONLY
#endif // !defined(ACL_CLIENT_ONLY) && !defined(ACL_REDIS_DISABLE)

View File

@ -2,7 +2,7 @@
#include "../acl_cpp_define.hpp"
#include <vector>
#ifndef ACL_CLIENT_ONLY
#if !defined(ACL_CLIENT_ONLY) && !defined(ACL_REDIS_DISABLE)
namespace acl
{
@ -98,4 +98,4 @@ private:
} // namespace acl
#endif // ACL_CLIENT_ONLY
#endif // !defined(ACL_CLIENT_ONLY) && !defined(ACL_REDIS_DISABLE)

View File

@ -3,7 +3,7 @@
#include "../stdlib/string.hpp"
#include "redis_command.hpp"
#ifndef ACL_CLIENT_ONLY
#if !defined(ACL_CLIENT_ONLY) && !defined(ACL_REDIS_DISABLE)
namespace acl
{
@ -546,4 +546,4 @@ private:
} // namespace acl
#endif // ACL_CLIENT_ONLY
#endif // !defined(ACL_CLIENT_ONLY) && !defined(ACL_REDIS_DISABLE)

View File

@ -4,7 +4,7 @@
#include <vector>
#include "redis_command.hpp"
#ifndef ACL_CLIENT_ONLY
#if !defined(ACL_CLIENT_ONLY) && !defined(ACL_REDIS_DISABLE)
namespace acl
{
@ -531,5 +531,4 @@ private:
} // namespace acl
#endif // ACL_CLIENT_ONLY
#endif // !defined(ACL_CLIENT_ONLY) && !defined(ACL_REDIS_DISABLE)

View File

@ -4,7 +4,7 @@
#include "../stdlib/string.hpp"
#include "redis_command.hpp"
#ifndef ACL_CLIENT_ONLY
#if !defined(ACL_CLIENT_ONLY) && !defined(ACL_REDIS_DISABLE)
namespace acl
{
@ -149,4 +149,4 @@ private:
} // namespace acl
#endif // ACL_CLIENT_ONLY
#endif // !defined(ACL_CLIENT_ONLY) && !defined(ACL_REDIS_DISABLE)

View File

@ -5,7 +5,7 @@
#include <utility>
#include "redis_command.hpp"
#ifndef ACL_CLIENT_ONLY
#if !defined(ACL_CLIENT_ONLY) && !defined(ACL_REDIS_DISABLE)
namespace acl
{
@ -556,4 +556,4 @@ private:
} // namespace acl
#endif // ACL_CLIENT_ONLY
#endif // !defined(ACL_CLIENT_ONLY) && !defined(ACL_REDIS_DISABLE)

View File

@ -2,6 +2,8 @@
#include "../acl_cpp_define.hpp"
#include "../stdlib/string.hpp"
#if !defined(ACL_MIME_DISABLE)
namespace acl {
class mime_code;
@ -110,3 +112,5 @@ private:
};
} // namespace acl
#endif // !defined(ACL_MIME_DISABLE)

View File

@ -5,6 +5,8 @@
#include "../stdlib/noncopyable.hpp"
#include "../http/http_ctype.hpp"
#if !defined(ACL_MIME_DISABLE)
namespace acl {
class mime_code;
@ -204,3 +206,5 @@ private:
};
} // namespace acl
#endif // !defined(ACL_MIME_DISABLE)

View File

@ -4,6 +4,8 @@
#include "../stdlib/noncopyable.hpp"
#include <vector>
#if !defined(ACL_MIME_DISABLE)
namespace acl {
class dbuf_pool;
@ -297,3 +299,5 @@ private:
};
} // namespace acl
#endif // !defined(ACL_MIME_DISABLE)

View File

@ -4,6 +4,8 @@
#include "../stream/socket_stream.hpp"
#include <vector>
#if !defined(ACL_MIME_DISABLE)
struct SMTP_CLIENT;
namespace acl {
@ -218,3 +220,5 @@ private:
};
} // namespace acl
#endif // !defined(ACL_MIME_DISABLE)

View File

@ -7,7 +7,7 @@
#include "acl_cpp/beanstalk/beanstalk.hpp"
#endif
#ifndef ACL_CLIENT_ONLY
#if !defined(ACL_CLIENT_ONLY) && !defined(ACL_BEANSTALK_DISABLE)
namespace acl
{
@ -860,4 +860,4 @@ void beanstalk::quit()
} // namespace acl
#endif // ACL_CLIENT_ONLY
#endif // !defined(ACL_CLIENT_ONLY) && !defined(ACL_BEANSTALK_DISABLE)

View File

@ -5,7 +5,7 @@
#include "acl_cpp/beanstalk/beanstalk_pool.hpp"
#endif
#ifndef ACL_CLIENT_ONLY
#if !defined(ACL_CLIENT_ONLY) && !defined(ACL_BEANSTALK_DISABLE)
namespace acl {
@ -67,4 +67,4 @@ void beanstalk_pool::put(beanstalk* client, bool clean_watch /* = true */,
} // namespace acl
#endif // ACL_CLIENT_ONLY
#endif // !defined(ACL_CLIENT_ONLY) && !defined(ACL_BEANSTALK_DISABLE)

View File

@ -7,6 +7,8 @@
#include "acl_cpp/db/db_handle.hpp"
#endif
#if !defined(ACL_DB_DISABLE)
namespace acl
{
@ -430,3 +432,5 @@ const char* db_handle::get_loadpath()
}
} // namespace acl
#endif // !defined(ACL_DB_DISABLE)

View File

@ -10,7 +10,7 @@
#include "acl_cpp/db/db_mysql.hpp"
#endif
#ifndef ACL_CLIENT_ONLY
#if !defined(ACL_CLIENT_ONLY) && !defined(ACL_DB_DISABLE)
//////////////////////////////////////////////////////////////////////////
@ -944,4 +944,4 @@ const char* db_mysql::get_error(void) const
#endif // !HAS_MYSQL && !HAS_MYSQL_DLL
#endif // ACL_CLIENT_ONLY
#endif // !defined(ACL_CLIENT_ONLY) && !defined(ACL_DB_DISABLE)

View File

@ -9,7 +9,7 @@
#include "acl_cpp/db/db_pgsql.hpp"
#endif
#ifndef ACL_CLIENT_ONLY
#if !defined(ACL_CLIENT_ONLY) && !defined(ACL_DB_DISABLE)
//////////////////////////////////////////////////////////////////////////
@ -680,4 +680,4 @@ const char* db_pgsql::get_error() const
#endif // !HAS_MYSQL && !HAS_MYSQL_DLL
#endif // ACL_CLIENT_ONLY
#endif // !defined(ACL_CLIENT_ONLY) && !defined(ACL_DB_DISABLE)

View File

@ -5,6 +5,8 @@
#include "acl_cpp/db/db_pool.hpp"
#endif
#if !defined(ACL_DB_DISABLE)
namespace acl
{
@ -35,3 +37,5 @@ db_guard::~db_guard(void)
}
} // namespace acl
#endif // !defined(ACL_DB_DISABLE)

View File

@ -9,6 +9,8 @@
#include "acl_cpp/db/db_service.hpp"
#endif
#if !defined(ACL_DB_DISABLE)
namespace acl
{
@ -323,3 +325,5 @@ void db_service::push_back(db_handle* db)
}
} // namespace acl
#endif // !defined(ACL_DB_DISABLE)

View File

@ -4,7 +4,7 @@
#include "acl_cpp/db/db_service_mysql.hpp"
#endif
#ifndef ACL_CLIENT_ONLY
#if !defined(ACL_CLIENT_ONLY) && !defined(ACL_DB_DISABLE)
namespace acl
{
@ -41,4 +41,4 @@ db_handle* db_service_mysql::db_create(void)
}
#endif // ACL_CLIENT_ONLY
#endif // !defined(ACL_CLIENT_ONLY) && !defined(ACL_DB_DISABLE)

View File

@ -4,6 +4,8 @@
#include "acl_cpp/db/db_service_sqlite.hpp"
#endif
#if !defined(ACL_DB_DISABLE)
namespace acl
{
@ -30,3 +32,5 @@ db_handle* db_service_sqlite::db_create(void)
}
} // namespace acl
#endif // !defined(ACL_DB_DISABLE)

View File

@ -9,6 +9,8 @@
#include "acl_cpp/db/db_sqlite.hpp"
#endif
#if !defined(ACL_DB_DISABLE)
#if defined(HAS_SQLITE) || defined(HAS_SQLITE_DLL)
# ifdef HAS_SQLITE_DLL
@ -761,4 +763,5 @@ bool db_sqlite::next(sqlite_cursor&, db_row*) { return false; }
} // namespace acl
#endif // !HAS_SQLITE && !HAS_SQLITE_DLL
#endif // !HAS_SQLITE && !HAS_SQLITE_DLL
#endif // !defined(ACL_DB_DISABLE)

View File

@ -3,7 +3,7 @@
#include "acl_cpp/db/mysql_conf.hpp"
#endif
#ifndef ACL_CLIENT_ONLY
#if !defined(ACL_CLIENT_ONLY) && !defined(ACL_DB_DISABLE)
namespace acl {
@ -138,4 +138,4 @@ mysql_conf& mysql_conf::set_rw_timeout(int timeout)
} // namespace acl
#endif // ACL_CLIENT_ONLY
#endif // !defined(ACL_CLIENT_ONLY) && !defined(ACL_DB_DISABLE)

View File

@ -6,7 +6,7 @@
#include "acl_cpp/db/mysql_manager.hpp"
#endif
#ifndef ACL_CLIENT_ONLY
#if !defined(ACL_CLIENT_ONLY) && !defined(ACL_DB_DISABLE)
namespace acl {
@ -105,4 +105,4 @@ connect_pool* mysql_manager::create_pool(const char* key, size_t, size_t)
} // namespace acl
#endif // ACL_CLIENT_ONLY
#endif // !defined(ACL_CLIENT_ONLY) && !defined(ACL_DB_DISABLE)

View File

@ -7,7 +7,7 @@
#include "acl_cpp/db/mysql_pool.hpp"
#endif
#ifndef ACL_CLIENT_ONLY
#if !defined(ACL_CLIENT_ONLY) && !defined(ACL_DB_DISABLE)
namespace acl
{
@ -55,4 +55,4 @@ connect_client* mysql_pool::create_connect()
} // namespace acl
#endif // ACL_CLIENT_ONLY
#endif // !defined(ACL_CLIENT_ONLY) && !defined(ACL_DB_DISABLE)

View File

@ -3,7 +3,7 @@
#include "acl_cpp/db/pgsql_conf.hpp"
#endif
#ifndef ACL_CLIENT_ONLY
#if !defined(ACL_CLIENT_ONLY) && !defined(ACL_DB_DISABLE)
namespace acl {
@ -126,4 +126,4 @@ pgsql_conf& pgsql_conf::set_rw_timeout(int timeout)
} // namespace acl
#endif // ACL_CLIENT_ONLY
#endif // !deifned(ACL_CLIENT_ONLY) && !defined(ACL_DB_DISABLE)

View File

@ -6,7 +6,7 @@
#include "acl_cpp/db/pgsql_manager.hpp"
#endif
#ifndef ACL_CLIENT_ONLY
#if !defined(ACL_CLIENT_ONLY) && !defined(ACL_DB_DISABLE)
namespace acl {
@ -60,4 +60,4 @@ connect_pool* pgsql_manager::create_pool(const char* key, size_t, size_t)
} // namespace acl
#endif // ACL_CLIENT_ONLY
#endif // !defined(ACL_CLIENT_ONLY) && !defined(ACL_DB_DISABLE)

View File

@ -7,7 +7,7 @@
#include "acl_cpp/db/pgsql_pool.hpp"
#endif
#ifndef ACL_CLIENT_ONLY
#if !defined(ACL_CLIENT_ONLY) && !defined(ACL_DB_DISABLE)
namespace acl
{
@ -30,4 +30,4 @@ connect_client* pgsql_pool::create_connect()
} // namespace acl
#endif // ACL_CLIENT_ONLY
#endif // !defined(ACL_CLIENT_ONLY) && !defined(ACL_DB_DISABLE)

View File

@ -6,6 +6,8 @@
#include "acl_cpp/db/query.hpp"
#endif
#if !defined(ACL_DB_DISABLE)
namespace acl
{
@ -431,3 +433,5 @@ const char* query::to_date(time_t t, string& out,
}
} // namespace acl
#endif // !defind(ACL_DB_DISABLE)

View File

@ -6,6 +6,8 @@
#include "acl_cpp/db/sqlite_cursor.hpp"
#endif
#if !defined(ACL_DB_DISABLE)
namespace acl
{
@ -64,3 +66,5 @@ void sqlite_cursor::add_column_value(const char* s)
}
} // namespace acl
#endif // !defined(ACL_DB_DISABLE)

View File

@ -4,6 +4,8 @@
#include "acl_cpp/db/sqlite_manager.hpp"
#endif
#if !defined(ACL_DB_DISABLE)
namespace acl {
sqlite_manager::sqlite_manager(const char* charset /* = "utf-8" */)
@ -35,3 +37,5 @@ connect_pool* sqlite_manager::create_pool(const char*, size_t, size_t)
}
} // namespace acl
#endif // !defined(ACL_DB_DISABLE)

View File

@ -6,6 +6,8 @@
#include "acl_cpp/db/sqlite_pool.hpp"
#endif
#if !defined(ACL_DB_DISABLE)
namespace acl
{
@ -34,3 +36,5 @@ connect_client* sqlite_pool::create_connect()
}
} // namespace acl
#endif // !defined(ACL_DB_DISABLE)

View File

@ -5,6 +5,8 @@
#include "acl_cpp/http/http_ctype.hpp"
#endif
#if !defined(ACL_MIME_DISABLE)
namespace acl
{
@ -193,3 +195,5 @@ const char* http_ctype::get_charset() const
}
} // namespace acl
#endif // !defined(ACL_MIME_DISABLE)

View File

@ -11,6 +11,8 @@
#include "acl_cpp/http/http_mime.hpp"
#endif
#if !defined(ACL_MIME_DISABLE)
namespace acl
{
@ -241,3 +243,5 @@ const http_mime_node* http_mime::get_node(const char* name) const
}
} // namespace acl
#endif // !defined(ACL_MIME_DISABLE)

View File

@ -502,6 +502,8 @@ void http_request::set_charset_conv()
if (ptr == NULL || *ptr == 0)
return;
#if !defined(ACL_MIME_DISABLE)
http_ctype ctype;
ctype.parse(ptr);
@ -526,6 +528,8 @@ void http_request::set_charset_conv()
delete conv_;
conv_ = NULL;
}
#endif // !defined(ACL_MIME_DISABLE)
}
http_pipe* http_request::get_pipe(const char* to_charset)

View File

@ -87,6 +87,8 @@ http_pipe* http_response::get_pipe(const char* to_charset)
if (ptr == NULL || *ptr == 0)
return NULL;
#if !defined(ACL_MIME_DISABLE)
http_ctype ctype;
ctype.parse(ptr);
@ -100,6 +102,9 @@ http_pipe* http_response::get_pipe(const char* to_charset)
}
else
return NULL;
#else
return NULL;
#endif // !defined(ACL_MIME_DISABLE)
}
bool http_response::get_body(xml& out, const char* to_charset /* = NULL */)

View File

@ -31,6 +31,9 @@
/* System library. */
#include "acl_stdafx.hpp"
#if !defined(ACL_MIME_DISABLE)
#include <ctype.h>
/* Utility library. */
@ -223,3 +226,5 @@ void header_nv_free(HEADER_NV *header)
acl_myfree(header);
}
}
#endif // !defined(ACL_MIME_DISABLE)

View File

@ -1,6 +1,8 @@
#ifndef _HEADER_OPTS_H_INCLUDED_
#define _HEADER_OPTS_H_INCLUDED_
#if !defined(ACL_MIME_DISABLE)
/*++
* NAME
* header_opts 3h
@ -93,4 +95,5 @@ extern void header_nv_free(HEADER_NV *header);
* Yorktown Heights, NY 10598, USA
*--*/
#endif // !defined(ACL_MIME_DISABLE)
#endif

View File

@ -80,6 +80,9 @@
/* System library. */
#include "acl_stdafx.hpp"
#if !defined(ACL_MIME_DISABLE)
#include <string.h>
#include <ctype.h>
@ -267,3 +270,5 @@ ssize_t header_token(HEADER_TOKEN *token, ssize_t token_len,
return (tok_count);
}
#endif // !defined(ACL_MIME_DISABLE)

View File

@ -12,10 +12,13 @@
* .nf
*/
#if !defined(ACL_MIME_DISABLE)
/*
* Utility library.
*/
#include <stdlib.h>
#include "stdlib/acl_vstring.h"
/*
@ -46,4 +49,5 @@ extern ssize_t header_token(HEADER_TOKEN *, ssize_t, ACL_VSTRING *, const char *
* Yorktown Heights, NY 10598, USA
*--*/
#endif // !defined(ACL_MIME_DISABLE)
#endif

View File

@ -35,6 +35,9 @@
/* System library. */
#include "acl_stdafx.hpp"
#if !defined(ACL_MIME_DISABLE)
#include <ctype.h>
/* Global library. */
@ -90,3 +93,5 @@ ssize_t is_header_buf(const char *str, ssize_t str_len)
/* Redundant return for future proofing. */
return (0);
}
#endif // !defined(ACL_MIME_DISABLE)

View File

@ -1,6 +1,8 @@
#ifndef _IS_HEADER_H_INCLUDED_
#define _IS_HEADER_H_INCLUDED_
#if !defined(ACL_MIME_DISABLE)
/*++
* NAME
* is_header 3h
@ -30,4 +32,5 @@ extern ssize_t is_header_buf(const char *, ssize_t);
* Yorktown Heights, NY 10598, USA
*--*/
#endif // !defined(ACL_MIME_DISABLE)
#endif

View File

@ -1,6 +1,8 @@
#ifndef _LEX_822_H_INCLUDED_
#define _LEX_822_H_INCLUDED_
#if !defined(ACL_MIME_DISABLE)
/*++
* NAME
* lex_822 3h
@ -34,4 +36,5 @@
* Yorktown Heights, NY 10598, USA
*--*/
#endif // !defined(ACL_MIME_DISABLE)
#endif

Some files were not shown because too many files have changed in this diff Show More