1

After updating to Mac OS X El Capitan, my bbndk setup is not working anymore. When I try to build a sample cmake project, it fails with below error.

$source /Applications//Momentics.app/bbndk-env_10_3_1_995.sh
$ make
-- The C compiler identification is unknown
-- The CXX compiler identification is unknown
-- Check for working C compiler: /Applications/Momentics.app/host_10_3_1_12/darwin/x86/usr/bin/qcc
-- Check for working C compiler: /Applications/Momentics.app/host_10_3_1_12/darwin/x86/usr/bin/qcc -- broken
CMake Error at /Applications/CMake.app/Contents/share/cmake-3.4/Modules/CMakeTestCCompiler.cmake:61 (message):
  The C compiler
  "/Applications/Momentics.app/host_10_3_1_12/darwin/x86/usr/bin/qcc" is not
  able to compile a simple test program.

  It fails with the following output:

   Change Dir: /Users/test/bb10-arm-build/CMakeFiles/CMakeTmp



  Run Build
  Command:"/Applications/Momentics.app/host_10_3_1_12/darwin/x86/usr/bin/make"
  "cmTC_31e1d/fast"

  /Applications/Momentics.app/host_10_3_1_12/darwin/x86/usr/bin/make -f
  CMakeFiles/cmTC_31e1d.dir/build.make CMakeFiles/cmTC_31e1d.dir/build

  make[1]: Entering directory
  '/Users/test/bb10-arm-build/CMakeFiles/CMakeTmp'

  Building C object CMakeFiles/cmTC_31e1d.dir/testCCompiler.c.o

  /Applications/Momentics.app/host_10_3_1_12/darwin/x86/usr/bin/qcc
  -V4.8.3,gcc_ntoarmv7le_cpp -marm -mcpu=cortex-a9 -fstack-protector
  -fstack-protector-all -Wno-psabi -D__QNX__ -D_REENTRANT -DQ_OS_BLACKBERRY
  -DQT_DECLARATIVE_LIB -DQT_GUI_LIB -DQT_CORE_LIB -DQT_SHARED -o
  CMakeFiles/cmTC_31e1d.dir/testCCompiler.c.o -c
  /Users/test/bb10-arm-build/CMakeFiles/CMakeTmp/testCCompiler.c


  dyld: Library not loaded:
  /usr/darwin/x86_64-apple-darwin/x86_64-apple-darwin/lib/libmpc.2.dylib

    Referenced from: /Applications/Momentics.app/host_10_3_1_12/darwin/x86/usr/lib/gcc/arm-unknown-nto-qnx8.0.0eabi/4.8.3/cc1
    Reason: image not found

  cc:
  /Applications/Momentics.app/host_10_3_1_12/darwin/x86/usr/lib/gcc/arm-unknown-nto-qnx8.0.0eabi/4.8.3/cc1
  caught signal 5

  CMakeFiles/cmTC_31e1d.dir/build.make:65: recipe for target
  'CMakeFiles/cmTC_31e1d.dir/testCCompiler.c.o' failed

  make[1]: Leaving directory
  '/Users/test/bb10-arm-build/CMakeFiles/CMakeTmp'

  Makefile:126: recipe for target 'cmTC_31e1d/fast' failed

  make[1]: *** [CMakeFiles/cmTC_31e1d.dir/testCCompiler.c.o] Error 1

  make: *** [cmTC_31e1d/fast] Error 2





  CMake will not be able to correctly generate this project.
Call Stack (most recent call first):
  CMakeLists.txt:2 (project)


-- Configuring incomplete, errors occurred!
See also "/Users/test/CMakeOutput.log".
See also "/Users/test/CMakeError.log".
$

Have reinstalled Momentics and cmake but no success. I see that qcc is looking at the wrong place for the library

/usr/darwin/x86_64-apple-darwin/x86_64-apple-darwin/lib/libmpc.2.dylib

Any idea why qcc does not use the value from DYLIB_LIBRARY_PATH to look for the library?

The first few lines from the CMakeError.log is below

Compiling the C compiler identification source file "CMakeCCompilerId.c" failed.
Compiler: /Applications/Momentics.app/host_10_3_1_12/darwin/x86/usr/bin/qcc 
Build flags: -V4.8.3,gcc_ntoarmv7le_cpp;-marm;-mcpu=cortex-a9;-fstack-protector;-fstack-protector-all;;-Wno-psabi;-D__QNX__;-D_REENTRANT;-DQ_OS_BLACKBERRY;-DQT_DECLARATIVE_LIB;-DQT_GUI_LIB;-DQT_CORE_LIB;-DQT_SHARED
Id flags: 

The output was:
1
dyld: Library not loaded: /usr/darwin/x86_64-apple-darwin/x86_64-apple-darwin/lib/libmpc.2.dylib
  Referenced from: /Applications/Momentics.app/host_10_3_1_12/darwin/x86/usr/lib/gcc/arm-unknown-nto-qnx8.0.0eabi/4.8.3/cc1
  Reason: image not found
cc: /Applications/Momentics.app/host_10_3_1_12/darwin/x86/usr/lib/gcc/arm-unknown-nto-qnx8.0.0eabi/4.8.3/cc1 caught signal 5
Cœur
  • 37,241
  • 25
  • 195
  • 267
BTR Naidu
  • 1,063
  • 3
  • 18
  • 45
  • Have you deleted your build directory and rerun cmake? – usr1234567 Oct 20 '15 at 18:38
  • Yes. No luck. The entire build process broke after MAC OS X upgrade.. – BTR Naidu Oct 20 '15 at 19:18
  • Check CMakeFiles/CMakeError.log in your build directory what error the compiler emits. It should be at the very beginning. – usr1234567 Oct 20 '15 at 19:38
  • Added to the main question. The output shown in the error log does not mention more that what is from the compile output. – BTR Naidu Oct 20 '15 at 20:21
  • I have this same problem. Did you ever resolve it? Looks like BB has not updated its developer tools in more than a year. Maybe it is a lost cause. – tofutim Dec 04 '16 at 00:01
  • The setup script does have DYLD_LIBRARY_PATH="$QNX_HOST/usr/lib:$QNX_TARGET/../darwin/x86/usr/lib/qt$QTVERSION/lib:$DYLD_LIBRARY_PATH" -- and I see the library right i /Applications/Momentics.app/host_10_3_1_12/darwin/x86/usr/lib – tofutim Dec 04 '16 at 00:08
  • Apparently DYLD_LIBRARY_PATH gets overwritten by OSX. It was too much to solve after reading in forums. So I moved to Linux. – BTR Naidu Dec 05 '16 at 10:04

0 Answers0