{"action":"opened","issue":{"url":"https://api.github.com/repos/opencv/opencv/issues/9637","repository_url":"https://api.github.com/repos/opencv/opencv","labels_url":"https://api.github.com/repos/opencv/opencv/issues/9637/labels{/name}","comments_url":"https://api.github.com/repos/opencv/opencv/issues/9637/comments","events_url":"https://api.github.com/repos/opencv/opencv/issues/9637/events","html_url":"https://github.com/opencv/opencv/issues/9637","id":258074546,"number":9637,"title":"Unable to find a javac compiler","user":{"login":"orange-jacky","id":461594,"avatar_url":"https://avatars2.githubusercontent.com/u/461594?v=4","gravatar_id":"","url":"https://api.github.com/users/orange-jacky","html_url":"https://github.com/orange-jacky","followers_url":"https://api.github.com/users/orange-jacky/followers","following_url":"https://api.github.com/users/orange-jacky/following{/other_user}","gists_url":"https://api.github.com/users/orange-jacky/gists{/gist_id}","starred_url":"https://api.github.com/users/orange-jacky/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/orange-jacky/subscriptions","organizations_url":"https://api.github.com/users/orange-jacky/orgs","repos_url":"https://api.github.com/users/orange-jacky/repos","events_url":"https://api.github.com/users/orange-jacky/events{/privacy}","received_events_url":"https://api.github.com/users/orange-jacky/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"assignees":[],"milestone":null,"comments":0,"created_at":"2017-09-15T15:14:14Z","updated_at":"2017-09-15T15:14:14Z","closed_at":null,"author_association":"NONE","body":"[root@iz2zec6q1zmdj7w594xa50z build]# lsb_release -a\r\nLSB Version:    :core-4.1-amd64:core-4.1-noarch\r\nDistributor ID: CentOS\r\nDescription:    CentOS Linux release 7.3.1611 (Core) \r\nRelease:        7.3.1611\r\nCodename:       Core\r\n\r\ngit clone https://github.com/opencv/opencv.git\r\ncmake -D CMAKE_BUILD_TYPE=Release -D CMAKE_INSTALL_PREFIX=/usr/local ..\r\n\r\n\r\n[root@iz2zec6q1zmdj7w594xa50z build]# make\r\n[  0%] Generate opencv.pc\r\n[  0%] Built target gen-pkgconfig\r\n[  9%] Built target libwebp\r\n[ 14%] Built target IlmImf\r\n[ 14%] Built target ittnotify\r\n[ 19%] Built target libprotobuf\r\n[ 19%] Built target opencv_core_pch_dephelp\r\n[ 19%] Built target pch_Generate_opencv_core\r\n[ 24%] Built target opencv_core\r\n[ 24%] Built target opencv_ts_pch_dephelp\r\n[ 24%] Built target pch_Generate_opencv_ts\r\n[ 24%] Built target opencv_imgproc_pch_dephelp\r\n[ 24%] Built target pch_Generate_opencv_imgproc\r\n[ 29%] Built target opencv_imgproc\r\n[ 29%] Built target opencv_imgcodecs_pch_dephelp\r\n[ 29%] Built target pch_Generate_opencv_imgcodecs\r\n[ 30%] Built target opencv_imgcodecs\r\n[ 30%] Built target opencv_videoio_pch_dephelp\r\n[ 30%] Built target pch_Generate_opencv_videoio\r\n[ 31%] Built target opencv_videoio\r\n[ 31%] Built target opencv_highgui_pch_dephelp\r\n[ 31%] Built target pch_Generate_opencv_highgui\r\n[ 32%] Built target opencv_highgui\r\n[ 33%] Built target opencv_ts\r\n[ 33%] Built target opencv_perf_core_pch_dephelp\r\n[ 33%] Built target pch_Generate_opencv_perf_core\r\n[ 36%] Built target opencv_perf_core\r\n[ 36%] Built target opencv_test_core_pch_dephelp\r\n[ 36%] Built target pch_Generate_opencv_test_core\r\n[ 39%] Built target opencv_test_core\r\n[ 39%] Built target opencv_flann_pch_dephelp\r\n[ 39%] Built target pch_Generate_opencv_flann\r\n[ 39%] Built target opencv_flann\r\n[ 39%] Built target opencv_test_flann_pch_dephelp\r\n[ 39%] Built target pch_Generate_opencv_test_flann\r\n[ 39%] Built target opencv_test_flann\r\n[ 39%] Built target opencv_perf_imgproc_pch_dephelp\r\n[ 39%] Built target pch_Generate_opencv_perf_imgproc\r\n[ 41%] Built target opencv_perf_imgproc\r\n[ 41%] Built target opencv_test_imgproc_pch_dephelp\r\n[ 41%] Built target pch_Generate_opencv_test_imgproc\r\n[ 44%] Built target opencv_test_imgproc\r\n[ 44%] Built target opencv_ml_pch_dephelp\r\n[ 44%] Built target pch_Generate_opencv_ml\r\n[ 45%] Built target opencv_ml\r\n[ 45%] Built target opencv_test_ml_pch_dephelp\r\n[ 45%] Built target pch_Generate_opencv_test_ml\r\n[ 46%] Built target opencv_test_ml\r\n[ 46%] Built target opencv_objdetect_pch_dephelp\r\n[ 47%] Built target pch_Generate_opencv_objdetect\r\n[ 48%] Built target opencv_objdetect\r\n[ 48%] Built target opencv_perf_objdetect_pch_dephelp\r\n[ 49%] Built target pch_Generate_opencv_perf_objdetect\r\n[ 50%] Built target opencv_perf_objdetect\r\n[ 50%] Built target opencv_test_objdetect_pch_dephelp\r\n[ 51%] Built target pch_Generate_opencv_test_objdetect\r\n[ 51%] Built target opencv_test_objdetect\r\n[ 51%] Built target opencv_photo_pch_dephelp\r\n[ 52%] Built target pch_Generate_opencv_photo\r\n[ 53%] Built target opencv_photo\r\n[ 53%] Built target opencv_perf_photo_pch_dephelp\r\n[ 53%] Built target pch_Generate_opencv_perf_photo\r\n[ 53%] Built target opencv_perf_photo\r\n[ 53%] Built target opencv_test_photo_pch_dephelp\r\n[ 53%] Built target pch_Generate_opencv_test_photo\r\n[ 54%] Built target opencv_test_photo\r\n[ 54%] Built target opencv_video_pch_dephelp\r\n[ 54%] Built target pch_Generate_opencv_video\r\n[ 55%] Built target opencv_video\r\n[ 55%] Built target opencv_perf_video_pch_dephelp\r\n[ 55%] Built target pch_Generate_opencv_perf_video\r\n[ 56%] Built target opencv_perf_video\r\n[ 56%] Built target opencv_test_video_pch_dephelp\r\n[ 56%] Built target pch_Generate_opencv_test_video\r\n[ 57%] Built target opencv_test_video\r\n[ 57%] Built target opencv_viz_pch_dephelp\r\n[ 58%] Built target pch_Generate_opencv_viz\r\n[ 59%] Built target opencv_viz\r\n[ 59%] Built target opencv_test_viz_pch_dephelp\r\n[ 59%] Built target pch_Generate_opencv_test_viz\r\n[ 59%] Built target opencv_test_viz\r\n[ 59%] Built target opencv_dnn_pch_dephelp\r\n[ 59%] Built target pch_Generate_opencv_dnn\r\n[ 63%] Built target opencv_dnn\r\n[ 63%] Built target opencv_perf_dnn_pch_dephelp\r\n[ 63%] Built target pch_Generate_opencv_perf_dnn\r\n[ 63%] Built target opencv_perf_dnn\r\n[ 63%] Built target opencv_test_dnn_pch_dephelp\r\n[ 63%] Built target pch_Generate_opencv_test_dnn\r\n[ 63%] Built target opencv_test_dnn\r\n[ 64%] Built target opencv_perf_imgcodecs_pch_dephelp\r\n[ 64%] Built target pch_Generate_opencv_perf_imgcodecs\r\n[ 64%] Built target opencv_perf_imgcodecs\r\n[ 64%] Built target opencv_test_imgcodecs_pch_dephelp\r\n[ 64%] Built target pch_Generate_opencv_test_imgcodecs\r\n[ 65%] Built target opencv_test_imgcodecs\r\n[ 65%] Built target opencv_shape_pch_dephelp\r\n[ 65%] Built target pch_Generate_opencv_shape\r\n[ 65%] Built target opencv_shape\r\n[ 66%] Built target opencv_test_shape_pch_dephelp\r\n[ 66%] Built target pch_Generate_opencv_test_shape\r\n[ 66%] Built target opencv_test_shape\r\n[ 66%] Built target opencv_perf_videoio_pch_dephelp\r\n[ 66%] Built target pch_Generate_opencv_perf_videoio\r\n[ 66%] Built target opencv_perf_videoio\r\n[ 66%] Built target opencv_test_videoio_pch_dephelp\r\n[ 66%] Built target pch_Generate_opencv_test_videoio\r\n[ 67%] Built target opencv_test_videoio\r\n[ 67%] Built target opencv_test_highgui_pch_dephelp\r\n[ 67%] Built target pch_Generate_opencv_test_highgui\r\n[ 67%] Built target opencv_test_highgui\r\n[ 67%] Built target opencv_superres_pch_dephelp\r\n[ 67%] Built target pch_Generate_opencv_superres\r\n[ 68%] Built target opencv_superres\r\n[ 68%] Built target opencv_perf_superres_pch_dephelp\r\n[ 68%] Built target pch_Generate_opencv_perf_superres\r\n[ 68%] Built target opencv_perf_superres\r\n[ 68%] Built target opencv_test_superres_pch_dephelp\r\n[ 68%] Built target pch_Generate_opencv_test_superres\r\n[ 68%] Built target opencv_test_superres\r\n[ 68%] Built target opencv_features2d_pch_dephelp\r\n[ 69%] Built target pch_Generate_opencv_features2d\r\n[ 71%] Built target opencv_features2d\r\n[ 71%] Built target opencv_perf_features2d_pch_dephelp\r\n[ 71%] Built target pch_Generate_opencv_perf_features2d\r\n[ 71%] Built target opencv_perf_features2d\r\n[ 71%] Built target opencv_test_features2d_pch_dephelp\r\n[ 72%] Built target pch_Generate_opencv_test_features2d\r\n[ 74%] Built target opencv_test_features2d\r\n[ 74%] Built target opencv_calib3d_pch_dephelp\r\n[ 74%] Built target pch_Generate_opencv_calib3d\r\n[ 76%] Built target opencv_calib3d\r\n[ 76%] Built target opencv_perf_calib3d_pch_dephelp\r\n[ 76%] Built target pch_Generate_opencv_perf_calib3d\r\n[ 76%] Built target opencv_perf_calib3d\r\n[ 76%] Built target opencv_test_calib3d_pch_dephelp\r\n[ 76%] Built target pch_Generate_opencv_test_calib3d\r\n[ 78%] Built target opencv_test_calib3d\r\n[ 78%] Generating opencv-330.jar\r\nTarget 'jar' failed with message 'Unable to find a javac compiler;\r\ncom.sun.tools.javac.Main is not on the classpath.\r\nPerhaps JAVA_HOME does not point to the JDK.\r\nIt is currently set to \"/usr/lib/jvm/java-1.8.0-openjdk-1.8.0.141-1.b16.el7_3.x86_64/jre\"'.\r\n\r\nBUILD FAILED\r\n/root/workspace/opencv/build/build.xml:10: Unable to find a javac compiler;\r\ncom.sun.tools.javac.Main is not on the classpath.\r\nPerhaps JAVA_HOME does not point to the JDK.\r\nIt is currently set to \"/usr/lib/jvm/java-1.8.0-openjdk-1.8.0.141-1.b16.el7_3.x86_64/jre\"\r\n\r\nTotal time: 7 seconds\r\nmake[2]: *** [bin/opencv-330.jar] Error 1\r\nmake[1]: *** [modules/java/CMakeFiles/opencv_java.dir/all] Error 2\r\nmake: *** [all] Error 2\r\n\r\n\r\nhow to fix it?\r\n"}}
{"actor":{"display_login":"orange-jacky"}}