-
-
Notifications
You must be signed in to change notification settings - Fork 1.9k
posix_setup
MMKV is an efficient, small, easy-to-use mobile key-value storage framework used in the WeChat application. It's currently available on both Android, iOS/macOS, Windows and POSIX.
- Linux(Ubuntu, Arch Linux, CentOS, Gentoo), Unix(macOS, FreeBSD, OpenBSD) are supported.
- CMake 3.8.0 and above.
- C++ compiler that supports C++ 20 standard.
- Getting source code from the git repository:
git clone https://github.com/Tencent/MMKV.git
- Edit your
CMakeLists.txt
, add those lines:
add_subdirectory(mmkv/POSIX/src mmkv)
target_link_libraries(MyApp mmkv)
- Add
#include "MMKV.h"
to your source file and we are done.
note:
- You can test MMKV by building & running the demo project:
cd mmkv/POSIX
mkdir build
cd build
cmake -DCMAKE_BUILD_TYPE=Release ..
make
cd demo && ./demo
- MMKV depends on zlib. Don't worry if there's no zlib1g-dev library installed on your computer, MMKV will use its own embedded version(zlib v1.2.11).
- If you are pretty sure that encryption is not needed, you can turn on the preprocess directive
MMKV_DISABLE_CRYPT
inCore/MMKVPredef.h
to save some binary size.
MMKV is published under the BSD 3-Clause license. For details check out the LICENSE.TXT.
Check out the CHANGELOG.md for details of change history.
If you are interested in contributing, check out the CONTRIBUTING.md, also join our Tencent OpenSource Plan.
To give clarity of what is expected of our members, MMKV has adopted the code of conduct defined by the Contributor Covenant, which is widely used. And we think it articulates our values well. For more, check out the Code of Conduct.
Check out the FAQ first. Should there be any questions, don't hesitate to create issues.
User privacy is taken very seriously: MMKV does not obtain, collect or upload any personal information. Please refer to the MMKV SDK Personal Information Protection Rules for details.
- In English
- 中文
- In English
- 中文
- In English
- 中文
-
In English
-
中文
-
Golang