ROS Resources: Documentation | Support | Discussion Forum | Index | Service Status | ros @ Robotics Stack Exchange |
1 | initial version |
I ran into the same problem using OS X 10.7.3. To get more information I ran
brew install -v log4cxx
and saw the error:
... -I/opt/subversion/include/apr-1 -I/opt/subversion/include -Os -w -pipe -march=native -Qunused-arguments -c objectptr.cpp -fno-common -DPIC -o .libs/objectptr.o objectptr.cpp:41:27: error: cast from pointer to smaller type 'apr_uint32_t' (aka 'unsigned int') loses information (apr_uint32_t) newValue); ^~~~~~~~~~~~~~~~~~~~~~~ 1 error generated.
The problem is it is trying to cast a void* to a apr_uint32_t. This would work find on a 32-bit machine but I am running on a 64-bit machine so void* is 64 bits.
I read this old post and concluded that the most likely cause is ARP, on my machine, was compiled as a 32-bit app and log4cxx is being built as a 64-bit app.
Looking at the error message above I see it is looking in the wrong place for the ARP includes. It is finding them in "-I/opt/subversion/include/apr-1" when it should be "-I/usr/include/apr-1".
The solution in my case was to remove the directory /opt/subversion and re-run "brew install -v log4cxx" in a new terminal.