Skip to content
This repository has been archived by the owner on Apr 15, 2020. It is now read-only.

add lmdb + test #1172

Merged
merged 4 commits into from
Nov 10, 2017
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions cmake/configs/default.cmake
Original file line number Diff line number Diff line change
Expand Up @@ -212,6 +212,7 @@ hunter_config(libsodium VERSION 1.0.10)
hunter_config(libuv VERSION 1.14.0-p1)
hunter_config(libxml2 VERSION 2.9.4)
hunter_config(libyuv VERSION 1514-p3)
hunter_config(lmdb VERSION 0.9.21-p1)
hunter_config(log4cplus VERSION 1.2.0-p0)
hunter_config(lzma VERSION 5.2.3-p4)
hunter_config(mini_chromium VERSION 0.0.1-p2)
Expand Down
26 changes: 26 additions & 0 deletions cmake/projects/lmdb/hunter.cmake
Original file line number Diff line number Diff line change
@@ -0,0 +1,26 @@
# Copyright (c) 2016-2017, Ruslan Baratov
# Copyright (c) 2017, David Hirvonen
# All rights reserved.

# !!! DO NOT PLACE HEADER GUARDS HERE !!!

include(hunter_add_version)
include(hunter_cacheable)
include(hunter_cmake_args)
include(hunter_download)
include(hunter_pick_scheme)

hunter_add_version(
PACKAGE_NAME
lmdb
VERSION
0.9.21-p1
URL
"https://github.com/hunter-packages/lmdb/archive/v0.9.21-p1.tar.gz"
SHA1
4218e126cbc18756d93a798f56e5e6dd10803aae
)

hunter_pick_scheme(DEFAULT url_sha1_cmake)
hunter_cacheable(lmdb)
hunter_download(PACKAGE_NAME lmdb)
18 changes: 18 additions & 0 deletions examples/lmdb/CMakeLists.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1,18 @@
# Copyright (c) 2016-2017, Ruslan Baratov
# Copyright (c) 2017, David Hirvonen
# All rights reserved.

cmake_minimum_required(VERSION 3.0)

# Emulate HunterGate:
# * https://github.com/hunter-packages/gate
include("../common.cmake")

project(download-lmdb)

hunter_add_package(lmdb)
find_package(liblmdb CONFIG REQUIRED)

add_executable(foo foo.cpp)
target_link_libraries(foo liblmdb::lmdb)

4 changes: 4 additions & 0 deletions examples/lmdb/foo.cpp
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
#include <lmdb/lmdb.h>

int main() {
}