thegoodhen / AprilTools

A marker-based camera tracker for Blender based around the AprilTags Library by University of Michigan
GNU General Public License v3.0
253 stars 29 forks source link

'python_build_flags.py' not found #10

Open rizerphe opened 5 years ago

rizerphe commented 5 years ago

Tested on raspberry pi. The prebuilt version doesn't work due to difference in architecture, cmake finishes successfully but says that file 'python_build_flags.py' doesn't exist, and make returns Error 2. This doesn't depend on the OS - I tried both Kali and raspbian.

thegoodhen commented 5 years ago

Alright, thank you... I am not sure how high-priority this problem is, but I'll look into it!

rizerphe commented 5 years ago

I tried both building release .tar.gz code and received by 'git clone', and even (on raspbian) downloaded as zip. Every time I also entered the downloaded repo folder and ran 'git clone' for apriltag

rizerphe commented 5 years ago

See makefile&cmake logs for raspbian 'git clone'. CMake output:

-- The CXX compiler identification is GNU 6.3.0
-- Check for working C compiler: /usr/bin/cc
-- Check for working C compiler: /usr/bin/cc -- works
-- Detecting C compiler ABI info
-- Detecting C compiler ABI info - done
-- Detecting C compile features
-- Detecting C compile features - done
-- Check for working CXX compiler: /usr/bin/c++
-- Check for working CXX compiler: /usr/bin/c++ -- works
-- Detecting CXX compiler ABI info
-- Detecting CXX compiler ABI info - done
-- Detecting CXX compile features
-- Detecting CXX compile features - done
-- Looking for pthread.h
-- Looking for pthread.h - found
-- Looking for pthread_create
-- Looking for pthread_create - not found
-- Looking for pthread_create in pthreads
-- Looking for pthread_create in pthreads - not found
-- Looking for pthread_create in pthread
-- Looking for pthread_create in pthread - found
-- Found Threads: TRUE  
-- Found PythonLibs: /usr/lib/arm-linux-gnueabihf/libpython3.5m.so (found version "3.5.3") 
python3: can't open file '/home/pi/AprilTools/python_build_flags.py': [Errno 2] No such file or directory
-- Configuring done
-- Generating done
-- Build files have been written to: /home/pi/AprilTools/build

CMakeError.log CMakeOutput.log Make output:


make[2]: *** No rule to make target 'apriltag/apriltag.c', needed by 'apriltag/CMakeFiles/apriltag.dir/apriltag.c.o'.  Stop.
CMakeFiles/Makefile2:128: recipe for target 'apriltag/CMakeFiles/apriltag.dir/all' failed
make[1]: *** [apriltag/CMakeFiles/apriltag.dir/all] Error 2
Makefile:127: recipe for target 'all' failed
make: *** [all] Error 2```
rizerphe commented 5 years ago

Raspbian source compilation from the release logs similar things. On Kali, the same 'git clone'. Cmake:

-- The CXX compiler identification is GNU 9.2.1
-- Check for working C compiler: /usr/bin/cc
-- Check for working C compiler: /usr/bin/cc -- works
-- Detecting C compiler ABI info
-- Detecting C compiler ABI info - done
-- Detecting C compile features
-- Detecting C compile features - done
-- Check for working CXX compiler: /usr/bin/c++
-- Check for working CXX compiler: /usr/bin/c++ -- works
-- Detecting CXX compiler ABI info
-- Detecting CXX compiler ABI info - done
-- Detecting CXX compile features
-- Detecting CXX compile features - done
-- Found OpenCV: /usr (found version "3.2.0") 
-- Looking for pthread.h
-- Looking for pthread.h - found
-- Looking for pthread_create
-- Looking for pthread_create - not found
-- Looking for pthread_create in pthreads
-- Looking for pthread_create in pthreads - not found
-- Looking for pthread_create in pthread
-- Looking for pthread_create in pthread - found
-- Found Threads: TRUE  
-- Found PythonLibs: /usr/lib/aarch64-linux-gnu/libpython3.7m.so (found version "3.7.4") 
python3: can't open file '/root/AprilTools/python_build_flags.py': [Errno 2] No such file or directory
-- Configuring done
-- Generating done
-- Build files have been written to: /root/AprilTools/build

CMakeError.log CMakeOutput.log

Make:

[  3%] Building C object apriltag/CMakeFiles/apriltag.dir/apriltag.c.o
[  6%] Building C object apriltag/CMakeFiles/apriltag.dir/apriltag_pose.c.o
[ 10%] Building C object apriltag/CMakeFiles/apriltag.dir/apriltag_quad_thresh.c.o
[ 13%] Building C object apriltag/CMakeFiles/apriltag.dir/common/g2d.c.o
[ 17%] Building C object apriltag/CMakeFiles/apriltag.dir/common/getopt.c.o
[ 20%] Building C object apriltag/CMakeFiles/apriltag.dir/common/homography.c.o
[ 24%] Building C object apriltag/CMakeFiles/apriltag.dir/common/image_u8.c.o
[ 27%] Building C object apriltag/CMakeFiles/apriltag.dir/common/image_u8x3.c.o
[ 31%] Building C object apriltag/CMakeFiles/apriltag.dir/common/image_u8x4.c.o
[ 34%] Building C object apriltag/CMakeFiles/apriltag.dir/common/matd.c.o
[ 37%] Building C object apriltag/CMakeFiles/apriltag.dir/common/pam.c.o
[ 41%] Building C object apriltag/CMakeFiles/apriltag.dir/common/pjpeg-idct.c.o
[ 44%] Building C object apriltag/CMakeFiles/apriltag.dir/common/pjpeg.c.o
[ 48%] Building C object apriltag/CMakeFiles/apriltag.dir/common/pnm.c.o
[ 51%] Building C object apriltag/CMakeFiles/apriltag.dir/common/string_util.c.o
[ 55%] Building C object apriltag/CMakeFiles/apriltag.dir/common/svd22.c.o
[ 58%] Building C object apriltag/CMakeFiles/apriltag.dir/common/time_util.c.o
[ 62%] Building C object apriltag/CMakeFiles/apriltag.dir/common/unionfind.c.o
[ 65%] Building C object apriltag/CMakeFiles/apriltag.dir/common/workerpool.c.o
[ 68%] Building C object apriltag/CMakeFiles/apriltag.dir/common/zarray.c.o
[ 72%] Building C object apriltag/CMakeFiles/apriltag.dir/common/zhash.c.o
[ 75%] Building C object apriltag/CMakeFiles/apriltag.dir/common/zmaxheap.c.o
[ 79%] Linking C shared library lib/libapriltag.so
[ 79%] Built target apriltag
Scanning dependencies of target apriltools
[ 82%] Building CXX object CMakeFiles/apriltools.dir/AprilTools.cc.o
/root/AprilTools/AprilTools.cc: In function ‘uint8_t compareFilenames(std::string, std::string)’:
/root/AprilTools/AprilTools.cc:273:1: warning: control reaches end of non-void function [-Wreturn-type]
  273 | }
      | ^
[ 86%] Linking CXX executable apriltools
/usr/bin/ld: CMakeFiles/apriltools.dir/AprilTools.cc.o: in function `main':
AprilTools.cc:(.text+0x1ae4): undefined reference to `tag36h11_create'
/usr/bin/ld: AprilTools.cc:(.text+0x1b08): undefined reference to `tag25h9_create'
/usr/bin/ld: AprilTools.cc:(.text+0x1b2c): undefined reference to `tag16h5_create'
/usr/bin/ld: AprilTools.cc:(.text+0x1b50): undefined reference to `tagCircle21h7_create'
/usr/bin/ld: AprilTools.cc:(.text+0x1b74): undefined reference to `tagCircle49h12_create'
/usr/bin/ld: AprilTools.cc:(.text+0x1b98): undefined reference to `tagStandard41h12_create'
/usr/bin/ld: AprilTools.cc:(.text+0x1bbc): undefined reference to `tagStandard52h13_create'
/usr/bin/ld: AprilTools.cc:(.text+0x1be0): undefined reference to `tagCustom48h12_create'
/usr/bin/ld: AprilTools.cc:(.text+0x2530): undefined reference to `tag36h11_destroy'
/usr/bin/ld: AprilTools.cc:(.text+0x2554): undefined reference to `tag25h9_destroy'
/usr/bin/ld: AprilTools.cc:(.text+0x2578): undefined reference to `tag16h5_destroy'
/usr/bin/ld: AprilTools.cc:(.text+0x259c): undefined reference to `tagCircle21h7_destroy'
/usr/bin/ld: AprilTools.cc:(.text+0x25c0): undefined reference to `tagCircle49h12_destroy'
/usr/bin/ld: AprilTools.cc:(.text+0x25e4): undefined reference to `tagStandard41h12_destroy'
/usr/bin/ld: AprilTools.cc:(.text+0x2608): undefined reference to `tagStandard52h13_destroy'
/usr/bin/ld: AprilTools.cc:(.text+0x262c): undefined reference to `tagCustom48h12_destroy'
collect2: error: ld returned 1 exit status
make[2]: *** [CMakeFiles/apriltools.dir/build.make:126: apriltools] Error 1
make[1]: *** [CMakeFiles/Makefile2:73: CMakeFiles/apriltools.dir/all] Error 2
make: *** [Makefile:130: all] Error 2
rizerphe commented 4 years ago

Tried again, everything works perfectly now except make gets stuck at 21% for a LONG time.