Closed AIBluefisher closed 5 years ago
Looks like we may have forgotten to add the gflags headers in that file. Could you submit a patch where you add the gflags header around here? https://github.com/sweeneychris/TheiaSfM/blob/master/src/theia/io/write_calibration_test.cc#L38
I have submitted the patch. But it seems gflags itself has some internal issues with DEFINE_xxx
. I installed gflags under the fix-gflags-define
branch and fixed this issue.
Besides, I record the script for installing theia, maybe useful for someone that get trouble with using theia
## GLOG, GFlags, GTest
#sudo apt-get install libgoogle-glog-dev libgflags-dev
git clone https://github.com/google/glog.git
cd glog
mkdir build && cd build
cmake ..
make -j8
sudo make install
git clone https://github.com/AIBluefisher/googletest.git
cd googletest
mkdir build
cd build
cmake ..
make -j8
sudo make install
git clone https://github.com/gflags/gflags
cd gflags
git checkout fix-gflags-define
mkdir build && cd build
make -j8
sudo make install
## openimageio, opengl, et.
sudo apt-get install libopenimageio1.6 libopenimageio-dev
sudo apt-get install freeglut3 freeglut3-dev libglew-dev
sudo apt-get install libxmu-dev libxi-dev
sudo apt-get install libopenexr-dev
## Eigen 3
hg clone https://bitbucket.org/eigen/eigen
mkdir eigen_build && cd eigen_build
cmake . ../eigen
make && sudo make install
cd ..
## Ceres-Solver
sudo apt-get install libatlas-base-dev libsuitesparse-dev
git clone https://github.com/ceres-solver/ceres-solver.git
cd ceres-solver
git checkout $(git describe --tags) # Checkout the latest release
mkdir build
cd build
cmake .. -DBUILD_TESTING=OFF -DBUILD_EXAMPLES=OFF
make -j8
sudo make install
## install rocksdb(required by TheiaSfM)
git clone https://github.com/facebook/rocksdb
cd rocksdb
git checkout v5.9.2
make -j8 shared_lib
sudo make install
sudo cp /usr/local/lib/librocksdb.* /usr/lib
## install rapidjson
git clone https://github.com/Tencent/rapidjson.git
cd rapidjson
git submodule update --init
mkdir build && cd build
cmake ..
make -j8
sudo make install
## build && install TheiaSfM
git clone https://github.com/sweeneychris/TheiaSfM.git
cd TheiaSfM
mkdir build && cd build
cmake ..
make -j8
make test
sudo make install
Hi, @sweeneychris I found an error when compiling theia that related with gflags. But I don't know how to solve it. May you help me?