RTXI / rtxi

Tutorials, FAQs, and more at http://rtxi.org/docs
GNU General Public License v3.0
53 stars 15 forks source link

Problems Building data_recorder.cpp #91

Closed topquant closed 9 years ago

topquant commented 9 years ago

When compiling data_recoder.cpp, it appears that the compiler produces errors by picking out version 1 of a function rather than version 2. For example:

make[2]: Entering directory `/home/developer/rtxi-master/plugins/data_recorder' CXX data_recorder.lo data_recorder.cpp: In member function 'void DataRecorder::Panel::processData()': data_recorder.cpp:1109:70: error: too few arguments to function 'hid_t H5Tarray_create1(hid_t, int, const hsizet, const int_)' hid_t array_type = H5Tarray_create(H5T_IEEE_F64LE, 1, array_size);
^ In file included from /usr/include/H5Lpublic.h:32:0, from /usr/include/H5Opublic.h:33, from /usr/include/H5Apublic.h:24, from /usr/include/hdf5.h:25, from ./data_recorder.h:31, from data_recorder.cpp:27: /usr/include/H5Tpublic.h:594:14: note: declared here H5_DLL hid_t H5Tarray_create1(hid_t base_id, int ndims,const hsizet dim[/* ndims /],const int perm[/_ ndims */]);

Note: This code fits H5Tarray_create2 at /usr/include/H5Tpublic.h:524:14 but apparently this is ignored. Is there some parameter I need to set in my environment to force the correct syntax checking? I am using a linux 3.8.13 kernel with xenomai-2.6.4 and the standard packages installed using the install_dependecies.sh script.

sudorook commented 9 years ago

You shouldn't need to edit your PATH or any other environment variable to compile the data recorder. Likely something else is misconfigured.

First, are you running install_dependencies.sh from the master branch? I figured yes, but I should check with you just in case. Also, let us know if you edited any of the scripts/source files/etc.

Let's try something simple first. Could you re-run the install scripts after cleaning out your repository? From the base of the RTXI repository you cloned, run:

$ git clean -xdf
$ cd scripts/
$ ./install_dependencies.sh
$ ./install_rtxi.sh

git clean will delete everything from the repository that was compiled/generated/etc during the installation process. It shouldn't give you permissions errors, but if it does, it's probably fine to re-run it as root.
When you rerun install_dependencies.sh, it will recompile the HDF libraries and reinstall them. Then, try to reintall RTXI. Let us know if the same compilation error occurs.