{"action":"created","issue":{"url":"https://api.github.com/repos/ARMmbed/mbedtls/issues/390","labels_url":"https://api.github.com/repos/ARMmbed/mbedtls/issues/390/labels{/name}","comments_url":"https://api.github.com/repos/ARMmbed/mbedtls/issues/390/comments","events_url":"https://api.github.com/repos/ARMmbed/mbedtls/issues/390/events","html_url":"https://github.com/ARMmbed/mbedtls/issues/390","id":125854479,"number":390,"title":"Regression: MBEDTLS_THREADING_ALT defined, but not all prerequisites","user":{"login":"robert-scheck","id":10982488,"avatar_url":"https://avatars.githubusercontent.com/u/10982488?v=3","gravatar_id":"","url":"https://api.github.com/users/robert-scheck","html_url":"https://github.com/robert-scheck","followers_url":"https://api.github.com/users/robert-scheck/followers","following_url":"https://api.github.com/users/robert-scheck/following{/other_user}","gists_url":"https://api.github.com/users/robert-scheck/gists{/gist_id}","starred_url":"https://api.github.com/users/robert-scheck/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/robert-scheck/subscriptions","organizations_url":"https://api.github.com/users/robert-scheck/orgs","repos_url":"https://api.github.com/users/robert-scheck/repos","events_url":"https://api.github.com/users/robert-scheck/events{/privacy}","received_events_url":"https://api.github.com/users/robert-scheck/received_events","type":"User","site_admin":false},"labels":[{"url":"https://api.github.com/repos/ARMmbed/mbedtls/labels/mirrored","name":"mirrored","color":"ededed"}],"state":"open","locked":false,"assignee":null,"milestone":null,"comments":4,"created_at":"2016-01-10T23:56:51Z","updated_at":"2016-01-11T14:32:37Z","closed_at":null,"body":"Since mbedtls 2.2.1, building fails on RHEL 7, 6 and 5 like this (all architectures):\r\n\r\n    cd /builddir/build/BUILD/mbedtls-2.2.1/library && /usr/bin/gcc  -Dmbedcrypto_EXPORTS -O2 -g -pipe -Wall -Wp,-D_FORTIFY_SOURCE=2 -fexceptions -fstack-protector --param=ssp-buffer-size=4 -m64 -mtune=generic  -Wall -Wextra -W -Wdeclaration-after-statement -Wwrite-strings -Wmissing-declarations -Wmissing-prototypes -O2 -fPIC -I/builddir/build/BUILD/mbedtls-2.2.1/include   -o CMakeFiles/mbedcrypto.dir/aes.c.o   -c /builddir/build/BUILD/mbedtls-2.2.1/library/aes.c\r\n    In file included from /builddir/build/BUILD/mbedtls-2.2.1/include/mbedtls/config.h:2509,\r\n                     from /builddir/build/BUILD/mbedtls-2.2.1/library/aes.c:29:\r\n    /builddir/build/BUILD/mbedtls-2.2.1/include/mbedtls/check_config.h:487:2: error: #error \"MBEDTLS_THREADING_ALT defined, but not all prerequisites\"\r\n    In file included from /builddir/build/BUILD/mbedtls-2.2.1/include/mbedtls/config.h:2509,\r\n                     from /builddir/build/BUILD/mbedtls-2.2.1/library/aes.c:29:\r\n    /builddir/build/BUILD/mbedtls-2.2.1/include/mbedtls/check_config.h:487:2: error: #error \"MBEDTLS_THREADING_ALT defined, but not all prerequisites\"\r\n    In file included from /builddir/build/BUILD/mbedtls-2.2.1/library/aes.c:38:\r\n    /builddir/build/BUILD/mbedtls-2.2.1/include/mbedtls/aes.h:279:21: error: aes_alt.h: No such file or directory\r\n    In file included from /builddir/build/BUILD/mbedtls-2.2.1/library/aes.c:43:\r\n    /builddir/build/BUILD/mbedtls-2.2.1/include/mbedtls/aesni.h:63: error: expected ')' before '*' token\r\n    In file included from /builddir/build/BUILD/mbedtls-2.2.1/include/mbedtls/config.h:2509,\r\n                     from /builddir/build/BUILD/mbedtls-2.2.1/library/aesni.c:28:\r\n    /builddir/build/BUILD/mbedtls-2.2.1/include/mbedtls/check_config.h:487:2: error: #error \"MBEDTLS_THREADING_ALT defined, but not all prerequisites\"\r\n    In file included from /builddir/build/BUILD/mbedtls-2.2.1/include/mbedtls/aesni.h:26,\r\n                     from /builddir/build/BUILD/mbedtls-2.2.1/library/aesni.c:35In file included from /builddir/build/BUILD/mbedtls-2.2.1/library/aes.c:38:\r\n    /builddir/build/BUILD/mbedtls-2.2.1/include/mbedtls/aes.h:279:21: error: aes_alt.h: No such file or directory\r\n    In file included from /builddir/build/BUILD/mbedtls-2.2.1/library/aes.c:43:\r\n    /builddir/build/BUILD/mbedtls-2.2.1/include/mbedtls/aesni.h:63: error: expected ')' before '*' token\r\n    :\r\n    /builddir/build/BUILD/mbedtls-2.2.1/include/mbedtls/aes.h:279:21: error: aes_alt.h: No such file or directory\r\n    In file included from /builddir/build/BUILD/mbedtls-2.2.1/library/aesni.c:35:\r\n    /builddir/build/BUILD/mbedtls-2.2.1/include/mbedtls/aesni.h:63: error: expected ')' before '*' token\r\n    /builddir/build/BUILD/mbedtls-2.2.1/library/aes.c: In function 'mbedtls_aes_self_test':\r\n    /builddir/build/BUILD/mbedtls-2.2.1/library/aes.c:1237: error: 'mbedtls_aes_context' undeclared (first use in this function)\r\n    /builddir/build/BUILD/mbedtls-2.2.1/library/aes.c:1237: error: (Each undeclared identifier is reported only once\r\n    /builddir/build/BUILD/mbedtls-2.2.1/library/aes.c:1237: error: for each function it appears in.)\r\n    /builddir/build/BUILD/mbedtls-2.2.1/library/aes.c:1237: error: expected ';' before 'ctx'\r\n    /builddir/build/BUILD/mbedtls-2.2.1/library/aes.c:1240: warning: implicit declaration of function 'mbedtls_aes_init'\r\n    /builddir/build/BUILD/mbedtls-2.2.1/library/aes.c:1240: error: 'ctx' undeclared (first use in this function)\r\n    /builddir/build/BUILD/mbedtls-2.2.1/library/aes.c:1258: warning: implicit declaration of function 'mbedtls_aes_setkey_dec'\r\n    /builddir/build/BUILD/mbedtls-2.2.1/library/aes.c:1261: warning: implicit declaration of function 'mbedtls_aes_crypt_ecb'\r\n    /builddir/build/BUILD/mbedtls-2.2.1/library/aes.c:1274: warning: implicit declaration of function 'mbedtls_aes_setkey_enc'\r\n    /builddir/build/BUILD/mbedtls-2.2.1/library/aes.c:1318: warning: implicit declaration of function 'mbedtls_aes_crypt_cbc'\r\n    /builddir/build/BUILD/mbedtls-2.2.1/library/aes.c:1384: warning: implicit declaration of function 'mbedtls_aes_crypt_cfb128'\r\n    /builddir/build/BUILD/mbedtls-2.2.1/library/aes.c:1442: warning: implicit declaration of function 'mbedtls_aes_crypt_ctr'\r\n    /builddir/build/BUILD/mbedtls-2.2.1/library/aes.c:1483: warning: implicit declaration of function 'mbedtls_aes_free'\r\n    make[2]: *** [library/CMakeFiles/mbedcrypto_static.dir/aes.c.o] Error 1\r\n    make[2]: Leaving directory `/builddir/build/BUILD/mbedtls-2.2.1'\r\n    /usr/bin/cmake -E cmake_progress_report /builddir/build/BUILD/mbedtls-2.2.1/CMakeFiles \r\n    make[1]: *** [library/CMakeFiles/mbedcrypto_static.dir/all] Error 2\r\n    make[1]: *** Waiting for unfinished jobs....\r\n    /builddir/build/BUILD/mbedtls-2.2.1/library/aes.c: In function 'mbedtls_aes_self_test':\r\n    /builddir/build/BUILD/mbedtls-2.2.1/library/aes.c:1237: error: 'mbedtls_aes_context' undeclared (first use in this function)\r\n    /builddir/build/BUILD/mbedtls-2.2.1/library/aes.c:1237: error: (Each undeclared identifier is reported only once\r\n    /builddir/build/BUILD/mbedtls-2.2.1/library/aes.c:1237: error: for each function it appears in.)\r\n    /builddir/build/BUILD/mbedtls-2.2.1/library/aes.c:1237: error: expected ';' before 'ctx'\r\n    /builddir/build/BUILD/mbedtls-2.2.1/library/aes.c:1240: warning: implicit declaration of function 'mbedtls_aes_init'\r\n    /builddir/build/BUILD/mbedtls-2.2.1/library/aes.c:1240: error: 'ctx' undeclared (first use in this function)\r\n    /builddir/build/BUILD/mbedtls-2.2.1/library/aes.c:1258: warning: implicit declaration of function 'mbedtls_aes_setkey_dec'\r\n    /builddir/build/BUILD/mbedtls-2.2.1/library/aes.c:1261: warning: implicit declaration of function 'mbedtls_aes_crypt_ecb'\r\n    /builddir/build/BUILD/mbedtls-2.2.1/library/aes.c:1274: warning: implicit declaration of function 'mbedtls_aes_setkey_enc'\r\n    /builddir/build/BUILD/mbedtls-2.2.1/library/aes.c:1318: warning: implicit declaration of function 'mbedtls_aes_crypt_cbc'\r\n    /builddir/build/BUILD/mbedtls-2.2.1/library/aes.c:1384: warning: implicit declaration of function 'mbedtls_aes_crypt_cfb128'\r\n    /builddir/build/BUILD/mbedtls-2.2.1/library/aes.c:1442: warning: implicit declaration of function 'mbedtls_aes_crypt_ctr'\r\n    /builddir/build/BUILD/mbedtls-2.2.1/library/aes.c:1483: warning: implicit declaration of function 'mbedtls_aes_free'\r\n    /builddir/build/BUILD/mbedtls-2.2.1/library/aesni.c:95: error: expected ')' before '*' token\r\n    make[2]: *** [library/CMakeFiles/mbedcrypto.dir/aes.c.o] Error 1\r\n    make[2]: *** Waiting for unfinished jobs....\r\n\r\nNote that mbedtls 2.2.0 was building fine on RHEL 7, 6 and 5 on all architectures."},"comment":{"url":"https://api.github.com/repos/ARMmbed/mbedtls/issues/comments/170568601","html_url":"https://github.com/ARMmbed/mbedtls/issues/390#issuecomment-170568601","issue_url":"https://api.github.com/repos/ARMmbed/mbedtls/issues/390","id":170568601,"user":{"login":"mpg","id":60640,"avatar_url":"https://avatars.githubusercontent.com/u/60640?v=3","gravatar_id":"","url":"https://api.github.com/users/mpg","html_url":"https://github.com/mpg","followers_url":"https://api.github.com/users/mpg/followers","following_url":"https://api.github.com/users/mpg/following{/other_user}","gists_url":"https://api.github.com/users/mpg/gists{/gist_id}","starred_url":"https://api.github.com/users/mpg/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/mpg/subscriptions","organizations_url":"https://api.github.com/users/mpg/orgs","repos_url":"https://api.github.com/users/mpg/repos","events_url":"https://api.github.com/users/mpg/events{/privacy}","received_events_url":"https://api.github.com/users/mpg/received_events","type":"User","site_admin":false},"created_at":"2016-01-11T14:32:37Z","updated_at":"2016-01-11T14:32:37Z","body":"Ok, the issue is you can't use `-j` if one of your targets is `apidoc`. If you replace that with `make -j4 all && make apidoc` that should work."}}