Merge branch 'master' of https://phabricator.tomicevic.com/diffusion/MG/memgraph into logging
* 'master' of https://phabricator.tomicevic.com/diffusion/MG/memgraph: old r3 commit was checked out added speedy to include path (root Makefile) test docker file update submodule reinitialization .gitmodules path updates The folder structure was changed, all source code is now within the src dir. Basic timer implementation; TODO: implement timer wheel
This commit is contained in:
commit
83769d7daf
1
.gitignore
vendored
1
.gitignore
vendored
@ -11,3 +11,4 @@ memgraph
|
||||
*.pyc
|
||||
*.breakpoint
|
||||
*.session.yaml
|
||||
tags
|
||||
|
12
.gitmodules
vendored
12
.gitmodules
vendored
@ -1,9 +1,9 @@
|
||||
[submodule "cypher/lexertl"]
|
||||
path = cypher/lexertl
|
||||
[submodule "src/cypher/lexertl"]
|
||||
path = src/cypher/lexertl
|
||||
url = https://github.com/BenHanson/lexertl.git
|
||||
[submodule "speedy/r3"]
|
||||
path = speedy/r3
|
||||
[submodule "src/speedy/r3"]
|
||||
path = src/speedy/r3
|
||||
url = https://github.com/c9s/r3.git
|
||||
[submodule "speedy/rapidjson"]
|
||||
path = speedy/rapidjson
|
||||
[submodule "src/speedy/rapidjson"]
|
||||
path = src/speedy/rapidjson
|
||||
url = https://github.com/miloyip/rapidjson.git
|
||||
|
8
Makefile
8
Makefile
@ -1,11 +1,11 @@
|
||||
CXX=clang++
|
||||
CFLAGS=-std=c++1y -DNDEBUG -O2 -Wall -Wno-unknown-pragmas
|
||||
CFLAGS_DEBUG=-std=c++1y -Wall -Wno-unknown-pragmas -g
|
||||
LDFLAGS=-luv -lhttp_parser speedy/r3/.libs/libr3.a -L/usr/local/lib -lpcre -pthread
|
||||
LDFLAGS=-luv -lhttp_parser src/speedy/r3/.libs/libr3.a -L/usr/local/lib -lpcre -pthread
|
||||
|
||||
INC=-I./ -I./speedy/rapidjson/include/
|
||||
SOURCES=memgraph.cpp
|
||||
EXECUTABLE=memgraph
|
||||
INC=-I./src/ -I./src/speedy/ -I./src/speedy/rapidjson/include/
|
||||
SOURCES=src/memgraph.cpp
|
||||
EXECUTABLE=build/memgraph
|
||||
|
||||
all: $(EXECUTABLE)
|
||||
|
||||
|
2
build.sh
2
build.sh
@ -16,5 +16,5 @@ if [[ -z $target ]]; then
|
||||
target="all"
|
||||
fi
|
||||
|
||||
cd api && python link_resources.py && cd ..
|
||||
cd src/api && python link_resources.py && cd ../..
|
||||
make clean && make $target
|
||||
|
2
build/.gitignore
vendored
Normal file
2
build/.gitignore
vendored
Normal file
@ -0,0 +1,2 @@
|
||||
*
|
||||
!.gitignore
|
@ -1 +0,0 @@
|
||||
Subproject commit 5acf39fbea01eb546edd140ce1334bd53f88928f
|
44
docker/test.dockerfile
Normal file
44
docker/test.dockerfile
Normal file
@ -0,0 +1,44 @@
|
||||
FROM ubuntu:16.04
|
||||
|
||||
# apt-get setup
|
||||
RUN apt-get update \
|
||||
&& apt-get install -y cmake git python clang \
|
||||
&& apt-get install -y check libpcre3 libpcre3-dev libjemalloc-dev \
|
||||
libjemalloc1 build-essential libtool automake \
|
||||
autoconf pkg-config
|
||||
# && apt-get clean && rm -rf /var/lib/apt/lists/* /tmp/* /var/tmp/*
|
||||
|
||||
RUN git clone https://pullbot:JnSdamFGKOanF1@phabricator.tomicevic.com/diffusion/MG/memgraph.git /memgraph
|
||||
|
||||
# update all submodules
|
||||
WORKDIR /memgraph
|
||||
RUN git submodule update --init
|
||||
|
||||
# install r3
|
||||
WORKDIR /memgraph/src/speedy/r3
|
||||
RUN ./autogen.sh && ./configure && make
|
||||
|
||||
# install libuv
|
||||
RUN git clone https://github.com/libuv/libuv.git /libs/libuv
|
||||
WORKDIR /libs/libuv
|
||||
RUN ./autogen.sh && ./configure && make && make check && make install
|
||||
ENV LD_LIBRARY_PATH /usr/local/lib
|
||||
|
||||
# install http_parser
|
||||
RUN git clone https://github.com/nodejs/http-parser /libs/http_parser
|
||||
WORKDIR /libs/http_parser
|
||||
# TODO: remove from here, in the time of writing the master branch
|
||||
# had a bug, some not HEAD commit was checked out
|
||||
RUN git checkout 4e382f96e6d3321538a78f2c7f9506d4e79b08d6
|
||||
RUN make && make install
|
||||
|
||||
# install lexertl and compile memgraph cypher
|
||||
WORKDIR /memgraph/src/cypher
|
||||
RUN ./init.sh
|
||||
|
||||
# compile memgraph
|
||||
WORKDIR /memgraph
|
||||
RUN ./build.sh
|
||||
|
||||
# run memgraph
|
||||
CMD /memgraph/memgraph 7474
|
@ -1 +0,0 @@
|
||||
Subproject commit 031a37514ed29da17cd990cd5ee532bec3b18b38
|
@ -1 +0,0 @@
|
||||
Subproject commit a5d9971a06d83288d1a41f9465dcdadacb562d15
|
@ -3,9 +3,9 @@
|
||||
#include "utils/command_line/arguments.hpp"
|
||||
#include "utils/string/file.hpp"
|
||||
|
||||
std::string extract_query(const vector_str& arguments)
|
||||
std::string extract_query(const std::vector<std::string>& arguments)
|
||||
{
|
||||
if (contain_argument(arguments, "-q"))
|
||||
if (contains_argument(arguments, "-q"))
|
||||
return get_argument(arguments, "-q", "CREATE (n) RETURN n");
|
||||
auto default_file = "query.cypher";
|
||||
auto file = get_argument(arguments, "-f", default_file);
|
1
src/cypher/lexertl
Submodule
1
src/cypher/lexertl
Submodule
@ -0,0 +1 @@
|
||||
Subproject commit 7d4d36a357027df0e817453cc9cf948f71047ca9
|
Some files were not shown because too many files have changed in this diff Show More
Loading…
Reference in New Issue
Block a user