{"action":"created","issue":{"url":"https://api.github.com/repos/ARMmbed/uvisor/issues/312","repository_url":"https://api.github.com/repos/ARMmbed/uvisor","labels_url":"https://api.github.com/repos/ARMmbed/uvisor/issues/312/labels{/name}","comments_url":"https://api.github.com/repos/ARMmbed/uvisor/issues/312/comments","events_url":"https://api.github.com/repos/ARMmbed/uvisor/issues/312/events","html_url":"https://github.com/ARMmbed/uvisor/issues/312","id":172762704,"number":312,"title":"Undefined reference to __wrap__calloc_r when compiling","user":{"login":"sherrellbc","id":8580880,"avatar_url":"https://avatars.githubusercontent.com/u/8580880?v=3","gravatar_id":"","url":"https://api.github.com/users/sherrellbc","html_url":"https://github.com/sherrellbc","followers_url":"https://api.github.com/users/sherrellbc/followers","following_url":"https://api.github.com/users/sherrellbc/following{/other_user}","gists_url":"https://api.github.com/users/sherrellbc/gists{/gist_id}","starred_url":"https://api.github.com/users/sherrellbc/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/sherrellbc/subscriptions","organizations_url":"https://api.github.com/users/sherrellbc/orgs","repos_url":"https://api.github.com/users/sherrellbc/repos","events_url":"https://api.github.com/users/sherrellbc/events{/privacy}","received_events_url":"https://api.github.com/users/sherrellbc/received_events","type":"User","site_admin":false},"labels":[{"url":"https://api.github.com/repos/ARMmbed/uvisor/labels/mirrored","name":"mirrored","color":"ededed"}],"state":"open","locked":false,"assignee":null,"assignees":[],"milestone":null,"comments":3,"created_at":"2016-08-23T17:47:10Z","updated_at":"2016-08-24T12:02:43Z","closed_at":null,"body":"I have been playing around with this one for too many hours. If one follows the steps outlined in the QuickStart markdown I am met with this every time. Is anyone else seeing this problem? \r\n\r\nThe problem only manifests itself once I enabled uVisor; the simply blinky program works fine. \r\n\r\n**GCC Version**\r\narm-none-eabi-gxx :  (GNU Tools for ARM Embedded Processors) 5.4.1 20160609 (release) [ARM/embedded-5-branch revision 237715]\r\n\r\n**Operating System**\r\nArch Linux; Kernel 4.7.0-1-ARCH \r\n\r\n> $ mbed compile -m K64F -t GCC_ARM\r\nBuilding project uvisor-example (K64F, GCC_ARM)\r\nScan: .\r\nScan: FEATURE_CLIENT\r\nScan: FEATURE_BLE\r\nScan: FEATURE_UVISOR\r\nScan: FEATURE_COMMON_PAL\r\nScan: FEATURE_STORAGE\r\nScan: FEATURE_IPV6\r\nScan: FEATURE_IPV4\r\nScan: mbed\r\nScan: env\r\nLink: uvisor-example\r\n/home/user/.programs/gcc-arm-none-eabi-5_4-2016q2/bin/../lib/gcc/arm-none-eabi/5.4.1/../../../../arm-none-eabi/bin/ld: Warning: alignment 1 of symbol `__uvisor_ps' in ./mbed-os/features/FEATURE_UVISOR/targets/TARGET_UVISOR_SUPPORTED/TARGET_MCU_K64F/TARGET_RELEASE/TARGET_M4/libconfiguration_kinetis_m4_0x1fff0000.a(uvisor-output.o) is smaller than 4 in ./mbed-os/features/FEATURE_UVISOR/targets/TARGET_UVISOR_SUPPORTED/TARGET_MCU_K64F/TARGET_RELEASE/TARGET_M4/libconfiguration_kinetis_m4_0x1fff0000.a(disabled.o)\r\n/home/user/.programs/gcc-arm-none-eabi-5_4-2016q2/bin/../lib/gcc/arm-none-eabi/5.4.1/../../../../arm-none-eabi/lib/armv7e-m/libc.a(lib_a-mprec.o): In function `_Balloc':\r\nmprec.c:(.text._Balloc+0x22): undefined reference to `__wrap__calloc_r'\r\nmprec.c:(.text._Balloc+0x3e): undefined reference to `__wrap__calloc_r'\r\ncollect2: error: ld returned 1 exit status\r\n[ERROR] /home/user/.programs/gcc-arm-none-eabi-5_4-2016q2/bin/../lib/gcc/arm-none-eabi/5.4.1/../../../../arm-none-eabi/bin/ld: Warning: alignment 1 of symbol `__uvisor_ps' in ./mbed-os/features/FEATURE_UVISOR/targets/TARGET_UVISOR_SUPPORTED/TARGET_MCU_K64F/TARGET_RELEASE/TARGET_M4/libconfiguration_kinetis_m4_0x1fff0000.a(uvisor-output.o) is smaller than 4 in ./mbed-os/features/FEATURE_UVISOR/targets/TARGET_UVISOR_SUPPORTED/TARGET_MCU_K64F/TARGET_RELEASE/TARGET_M4/libconfiguration_kinetis_m4_0x1fff0000.a(disabled.o)\r\n/home/user/.programs/gcc-arm-none-eabi-5_4-2016q2/bin/../lib/gcc/arm-none-eabi/5.4.1/../../../../arm-none-eabi/lib/armv7e-m/libc.a(lib_a-mprec.o): In function `_Balloc':\r\nmprec.c:(.text._Balloc+0x22): undefined reference to `__wrap__calloc_r'\r\nmprec.c:(.text._Balloc+0x3e): undefined reference to `__wrap__calloc_r'\r\ncollect2: error: ld returned 1 exit status\r\n\r\n> [mbed] ERROR: \"python\" returned error code 1.\r\n[mbed] ERROR: Command \"python -u /home/user/Desktop/code/uvisor-example/mbed-os/tools/make.py -t GCC_ARM -m K64F --source . --build ./.build/K64F/GCC_ARM\" in \"/home/user/Desktop/code/uvisor-example\"\r\n\r\n\r\nThe appropriate source appears to be present\r\n> $ grep -rn \"__wrap__calloc_r\" .\r\n./mbed-os/hal/common/retarget.cpp:589:void* __wrap__calloc_r(struct ... \r\n\r\nSorry for the poor formatting. I apologize if this turns out to be configuration problem on my end, but nearly a day's worth of research has gotten be no where with this. "},"comment":{"url":"https://api.github.com/repos/ARMmbed/uvisor/issues/comments/242039126","html_url":"https://github.com/ARMmbed/uvisor/issues/312#issuecomment-242039126","issue_url":"https://api.github.com/repos/ARMmbed/uvisor/issues/312","id":242039126,"user":{"login":"sherrellbc","id":8580880,"avatar_url":"https://avatars.githubusercontent.com/u/8580880?v=3","gravatar_id":"","url":"https://api.github.com/users/sherrellbc","html_url":"https://github.com/sherrellbc","followers_url":"https://api.github.com/users/sherrellbc/followers","following_url":"https://api.github.com/users/sherrellbc/following{/other_user}","gists_url":"https://api.github.com/users/sherrellbc/gists{/gist_id}","starred_url":"https://api.github.com/users/sherrellbc/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/sherrellbc/subscriptions","organizations_url":"https://api.github.com/users/sherrellbc/orgs","repos_url":"https://api.github.com/users/sherrellbc/repos","events_url":"https://api.github.com/users/sherrellbc/events{/privacy}","received_events_url":"https://api.github.com/users/sherrellbc/received_events","type":"User","site_admin":false},"created_at":"2016-08-24T12:02:43Z","updated_at":"2016-08-24T12:02:43Z","body":"Hello,\r\n\r\nAs for your first request, your statement was correct; `mbed new` seems to pull the latest revision. As of now that revision is: \r\n\r\n`22acfbf Merge pull request #2461 from svastm/serial_asynch_f3`\r\n\r\nYour suggestion to manually check out at a stable release seems to work -- or at least the source is now compiling. This makes a great deal of sense considering that [This](https://github.com/ARMmbed/mbed-os-example-uvisor) example always compiled successfully for me. The mbed-os.lib file in that example points to the same revision that you suggested to be used above. \r\n\r\nHowever, although it seems to compile, it does not actually _work_. I can push the binary to the device (which is the FRDM K64F in my case) but nothing happens. This is the case if I follow the QuickStart guide or use the example code (linked above). \r\n"}}
{"actor":{"display_login":"sherrellbc"}}