forked from EOSIO/abieos
-
Notifications
You must be signed in to change notification settings - Fork 6
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #3 from eosrio/develop
merge into master
- Loading branch information
Showing
93 changed files
with
35,176 additions
and
3,042 deletions.
There are no files selected for viewing
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,35 @@ | ||
cmake_minimum_required (VERSION 3.11) | ||
project(node_abieos VERSION 2.1 LANGUAGES CXX C) | ||
|
||
add_definitions(-DNAPI_VERSION=6) | ||
add_definitions(-DNAPI_EXPERIMENTAL) | ||
|
||
include_directories(${CMAKE_JS_INC}) | ||
|
||
set(default_build_type "Release") | ||
set(CMAKE_CXX_STANDARD 17) | ||
set(CMAKE_CXX_STANDARD_REQUIRED ON) | ||
set(CMAKE_CXX_EXTENSIONS ON) | ||
|
||
option(ABIEOS_NO_INT128 "disable use of __int128" OFF) | ||
|
||
find_package(Threads) | ||
|
||
add_library(abieos STATIC src/abi.cpp src/crypto.cpp include/eosio/fpconv.c) | ||
target_include_directories(abieos PUBLIC include) | ||
|
||
if(ABIEOS_NO_INT128) | ||
target_compile_definitions(abieos PUBLIC ABIEOS_NO_INT128) | ||
endif() | ||
|
||
set_target_properties(abieos PROPERTIES POSITION_INDEPENDENT_CODE ON) | ||
|
||
add_library(${PROJECT_NAME} SHARED src/main.cpp src/abieos.cpp) | ||
set_target_properties(${PROJECT_NAME} PROPERTIES PREFIX "" SUFFIX ".node") | ||
target_link_libraries(${PROJECT_NAME} ${CMAKE_JS_LIB};abieos;${CMAKE_THREAD_LIBS_INIT}) | ||
target_compile_options(${PROJECT_NAME} PRIVATE -Wall -Wextra -Wno-unused-parameter -fcolor-diagnostics) | ||
|
||
execute_process(COMMAND node -p "require('node-addon-api').include" WORKING_DIRECTORY ${CMAKE_SOURCE_DIR} OUTPUT_VARIABLE NODE_ADDON_API_DIR) | ||
string(REPLACE "\n" "" NODE_ADDON_API_DIR ${NODE_ADDON_API_DIR}) | ||
string(REPLACE "\"" "" NODE_ADDON_API_DIR ${NODE_ADDON_API_DIR}) | ||
target_include_directories(${PROJECT_NAME} PRIVATE ${NODE_ADDON_API_DIR}) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file was deleted.
Oops, something went wrong.
Binary file not shown.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Submodule date
deleted from
2cb4c3
Submodule rapidjson
deleted from
663f07
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,76 @@ | ||
BasedOnStyle: LLVM | ||
IndentWidth: 3 | ||
UseTab: Never | ||
ColumnLimit: 120 | ||
|
||
--- | ||
Language: Cpp | ||
# always align * and & to the type | ||
DerivePointerAlignment: false | ||
PointerAlignment: Left | ||
|
||
# regroup includes to these classes | ||
IncludeCategories: | ||
- Regex: '(<|"(eosio)/)' | ||
Priority: 4 | ||
- Regex: '(<|"(boost)/)' | ||
Priority: 3 | ||
- Regex: '(<|"(llvm|llvm-c|clang|clang-c)/' | ||
Priority: 3 | ||
- Regex: '<[[:alnum:]]+>' | ||
Priority: 2 | ||
- Regex: '.*' | ||
Priority: 1 | ||
|
||
#IncludeBlocks: Regroup | ||
|
||
# set indent for public, private and protected | ||
#AccessModifierOffset: 3 | ||
|
||
# make line continuations twice the normal indent | ||
ContinuationIndentWidth: 6 | ||
|
||
# add missing namespace comments | ||
FixNamespaceComments: true | ||
|
||
# add spaces to braced list i.e. int* foo = { 0, 1, 2 }; instead of int* foo = {0,1,2}; | ||
Cpp11BracedListStyle: false | ||
AlignAfterOpenBracket: Align | ||
AlignConsecutiveAssignments: true | ||
AlignConsecutiveDeclarations: true | ||
AlignOperands: true | ||
AlignTrailingComments: true | ||
AllowShortCaseLabelsOnASingleLine: true | ||
AllowShortFunctionsOnASingleLine: All | ||
AllowShortBlocksOnASingleLine: true | ||
#AllowShortIfStatementsOnASingleLine: WithoutElse | ||
#AllowShortIfStatementsOnASingleLine: true | ||
#AllowShortLambdasOnASingleLine: All | ||
AllowShortLoopsOnASingleLine: true | ||
AlwaysBreakTemplateDeclarations: true | ||
|
||
BinPackParameters: true | ||
### use this with clang9 | ||
BreakBeforeBraces: Custom | ||
BraceWrapping: | ||
#AfterCaseLabel: true | ||
AfterClass: false | ||
AfterControlStatement: false | ||
AfterEnum: false | ||
AfterFunction: false | ||
AfterNamespace: false | ||
AfterStruct: false | ||
AfterUnion: false | ||
AfterExternBlock: false | ||
BeforeCatch: false | ||
BeforeElse: false | ||
|
||
BreakConstructorInitializers: BeforeColon | ||
CompactNamespaces: true | ||
IndentCaseLabels: true | ||
IndentPPDirectives: AfterHash | ||
NamespaceIndentation: Inner | ||
ReflowComments: true | ||
SortIncludes: true | ||
SortUsingDeclarations: true | ||
--- |
Oops, something went wrong.