IntelRealSense / librealsense

Intel® RealSense™ SDK
https://www.intelrealsense.com/
Apache License 2.0
7.55k stars 4.81k forks source link

install python wrapper failed at make -j4 #1915

Closed bhomass closed 6 years ago

bhomass commented 6 years ago

I got thru the instructions for installing python wrapper all the way to make -j4. It says

make: *** No targets specified and no makefile found. Stop.

indeed, there is no makefile in the build or any sub directories.

where are you suppose to exec this command?

ev-mp commented 6 years ago

Hi @bhomass , if you start in librealsense root and follow the instructions, then reaching 'make -j' stage would put you:

--| . . . . . . (librealsense root dir) ....| .github ....| build . . . . . .|. here
... ....| include ....| src ....| scripts ...

bhomass commented 6 years ago

you mean the build subdirectory? I am in that exact location, and make -j4 gives me that error about no makefile. Should I have a makefile there by this stage? There are some .cmake files though. But make command is not using them.

TheMikeyR commented 6 years ago

@bhomass did you do following before make in the build folder ? cmake ../ -DBUILD_PYTHON_BINDINGS=bool:true

bhomass commented 6 years ago

yes, I did. It completes with no error. The response is as follows

-- Info: REALSENSE_VERSION_STRING=2.12.0 CMake Warning at CMakeLists.txt:576 (message): Using libuvc!

-- Found PythonInterp: /Library/Frameworks/Python.framework/Versions/3.6/bin/python3.6 (found version "3.6.4") -- Found PythonLibs: /Library/Frameworks/Python.framework/Versions/3.6/lib/libpython3.6m.dylib -- Performing Test HAS_CPP14_FLAG -- Performing Test HAS_CPP14_FLAG - Success -- pybind11 v2.2.1 -- Performing Test HAS_FLTO -- Performing Test HAS_FLTO - Success -- LTO enabled -- Configuring done -- Generating done -- Build files have been written to: /Users/bruceho/workspace/librealsense/build

But still no makefile created. The directory listing is

CMakeCache.txt cmake_uninstall.cmake log.txt tools CMakeFiles config realsense2Config.cmake wrappers CMakeScripts examples realsense2ConfigVersion.cmake cmake_install.cmake librealsense2.xcodeproj third-party

bhomass commented 6 years ago

I found the problem. You can not try build the entire repo in the same build dir, and then build the wrapper. I created a separate build dir, and this wrapper build worked.

RealSense-Customer-Engineering commented 6 years ago

[Realsense Customer Engineering Team Comment] hi @bhomass,

would like to check some basic for this topic, what's your OS? Ubuntu? version? thanks.

TonyFaith commented 6 years ago

@bhomass Hi,I came with the same trouble as you. Did you mean that we should move wrapper/python repo to another place and then build that follow the instruction? wait for your kind reply.

bhomass commented 6 years ago

@TonyFaith no, I just mean you need to create a different build directory for the wrapper code (such as python_build), which is distinct from the build directory you may have used to build the repo at the root level. If you didn't try building at root level, then nothing to worry about.

@customer-engineering I have OSX, but my problem and solution is unrelated to which OS.