Skip to content
This repository was archived by the owner on Jan 13, 2022. It is now read-only.
Open
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
35 commits
Select commit Hold shift + click to select a range
6c5e9a6
Update CMakeLists.txt
qinghuizhao Dec 26, 2016
05dbaab
Update fbpython-0.1-1.rockspec
qinghuizhao Dec 26, 2016
e75bb2e
Update Lib.cpp
qinghuizhao Dec 26, 2016
3e0380a
Update Lib.cpp
qinghuizhao Dec 26, 2016
7e2c4d8
Update Lib.cpp
qinghuizhao Dec 26, 2016
a3aac5f
Update Lib.cpp
qinghuizhao Dec 26, 2016
575ca88
Update Lib.cpp
qinghuizhao Dec 26, 2016
d5721ed
Update Lib.cpp
qinghuizhao Dec 26, 2016
bf0d97a
Update Lib.cpp
qinghuizhao Dec 26, 2016
256a13f
Update Lib.cpp
qinghuizhao Dec 26, 2016
c7e0d50
Update LuaToPython.h
qinghuizhao Dec 26, 2016
646bc0b
Update Lib.cpp
qinghuizhao Dec 26, 2016
1997363
Update LuaToPython.h
qinghuizhao Dec 26, 2016
e0ec614
Update Lib.cpp
qinghuizhao Dec 26, 2016
96aec19
Update Lib.cpp
qinghuizhao Dec 26, 2016
eeb8a2f
Update Lib.cpp
qinghuizhao Dec 26, 2016
3092229
Update Lib.cpp
qinghuizhao Dec 26, 2016
059a1a5
Update Lib.cpp
qinghuizhao Dec 26, 2016
c79226d
Update Lib.cpp
qinghuizhao Dec 26, 2016
25e2baa
Update Lib.cpp
qinghuizhao Dec 26, 2016
5c75891
Update Lib.cpp
qinghuizhao Dec 26, 2016
bcbd565
Update Lib.cpp
qinghuizhao Dec 26, 2016
d61ad7d
Update Lib.cpp
qinghuizhao Dec 26, 2016
8f27695
Update Lib.cpp
qinghuizhao Dec 26, 2016
4a0ad58
Update install_all.sh
qinghuizhao Jan 2, 2017
ae50e77
Update CMakeLists.txt
qinghuizhao Jan 2, 2017
efb1c6a
Update fbpython-0.1-1.rockspec
qinghuizhao Jan 2, 2017
68f6103
Update CMakeLists.txt
qinghuizhao Jan 2, 2017
da9409a
Update CMakeLists.txt
qinghuizhao Jan 2, 2017
9894087
Update fbpython-0.1-1.rockspec
qinghuizhao Jan 3, 2017
98ed933
Update build.sh
qinghuizhao Jan 3, 2017
23f517d
Update build.sh
qinghuizhao Jan 3, 2017
d83983c
Update build.sh
qinghuizhao Jan 3, 2017
bd146ca
Update build.sh
qinghuizhao Jan 3, 2017
aad9d30
Update install_all.sh
qinghuizhao Jan 3, 2017
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
2 changes: 1 addition & 1 deletion fblualib/build.sh
Original file line number Diff line number Diff line change
Expand Up @@ -31,5 +31,5 @@ for rock in $rocks; do
cd $root/$rock
# Unfortunately, luarocks doesn't like separating the "build" and
# "install" phases, so we have to run as root.
sudo luarocks make rockspec/fb$rock-$version.rockspec
sudo ~/torch/install/bin/luarocks make rockspec/fb$rock-$version.rockspec
done
2 changes: 1 addition & 1 deletion fblualib/ffivector/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@ INCLUDE_DIRECTORIES(
${FOLLY_INCLUDE_DIR}
)

SET(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -std=gnu++11")
SET(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -std=gnu++14")

SET(src
FFIVector.cpp
Expand Down
2 changes: 1 addition & 1 deletion fblualib/mattorch/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -35,7 +35,7 @@ INCLUDE_DIRECTORIES(
${MATIO_INCLUDE_DIR}
)

SET(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -std=gnu++11")
SET(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -std=gnu++14")

SET(src
MatTorch.cpp
Expand Down
2 changes: 1 addition & 1 deletion fblualib/python/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -63,7 +63,7 @@ INCLUDE_DIRECTORIES(
${Boost_INCLUDE_DIRS}
)

SET(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -std=gnu++11")
SET(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -std=gnu++14")

SET(src
Debug.cpp
Expand Down
12 changes: 6 additions & 6 deletions fblualib/python/Lib.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -187,7 +187,7 @@ const struct luaL_reg pythonFuncs[] = {
{"dict", getDict},
{"import", getModule},
{"_check_no_refs", checkNoRefs},
{nullptr, nullptr},
{nullptr, nullptr},
};

} // namespace
Expand Down Expand Up @@ -231,7 +231,7 @@ PythonInitializer::PythonInitializer() {

std::mutex gPythonInitMutex;

} // namespace
//} // namespace

extern "C" int LUAOPEN(lua_State* L) {
reloadGlobal();
Expand All @@ -240,9 +240,8 @@ extern "C" int LUAOPEN(lua_State* L) {
static PythonInitializer initializer; // only once, thread-safe

lua_newtable(L);
luaL_register(L, nullptr, pythonFuncs);

{
luaL_register(L, nullptr, pythonFuncs);
{
// numpy's import_array() doesn't appear to be thread-safe...

std::lock_guard<std::mutex> lock(gPythonInitMutex);
Expand All @@ -253,7 +252,8 @@ extern "C" int LUAOPEN(lua_State* L) {
// Initialization finished. Any Python references created so far are there
// to stay until the module is unloaded.
debugSetWatermark();
}
}

return 1;
}
} // namespace
2 changes: 1 addition & 1 deletion fblualib/torch/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,7 @@ INCLUDE_DIRECTORIES(

INCLUDE_DIRECTORIES(${LUA_INCDIR})

SET(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -std=gnu++11")
SET(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -std=gnu++14")

SET(src
AsyncRNG.cpp
Expand Down
7 changes: 5 additions & 2 deletions install_all.sh
Original file line number Diff line number Diff line change
Expand Up @@ -88,8 +88,11 @@ echo
if [ $current -eq 1 ]; then
git clone --depth 1 https://github.com/facebook/folly
git clone --depth 1 https://github.com/facebook/fbthrift
git clone https://github.com/facebook/thpp
git clone https://github.com/facebook/fblualib
#error ubuntu16.04
#git clone https://github.com/facebook/thpp
#add my thpp
git clone https://github.com/qinghuizhao/thpp
git clone https://github.com/qinghuizhao/fblualib
git clone https://github.com/facebook/wangle
else
git clone -b v0.35.0 --depth 1 https://github.com/facebook/folly
Expand Down