Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 624722 - dev-util/cmake-3.8.2 - CMake Error at CMakeLists.txt:309 (message): CMAKE_USE_SYSTEM_LIBRHASH is ON but LibRHash is not found!
Summary: dev-util/cmake-3.8.2 - CMake Error at CMakeLists.txt:309 (message): CMAKE_U...
Status: RESOLVED FIXED
Alias: None
Product: Gentoo/Alt
Classification: Unclassified
Component: Prefix Support (show other bugs)
Hardware: x86 OS X
: Normal normal (vote)
Assignee: Gentoo Prefix
URL:
Whiteboard:
Keywords:
: 626262 (view as bug list)
Depends on:
Blocks:
 
Reported: 2017-07-12 16:45 UTC by bashow
Modified: 2018-09-13 21:39 UTC (History)
4 users (show)

See Also:
Package list:
Runtime testing required: ---


Attachments
Error : cmake (CMakeOutput.log,79.40 KB, text/plain)
2017-07-12 16:45 UTC, bashow
Details
build.log of emerging cmake (build.log,90.11 KB, text/plain)
2017-07-19 12:45 UTC, Too Anuchit
Details
Configuring incomplete, errors occurred (stage3.log,957.02 KB, text/plain)
2017-07-21 06:56 UTC, bashow
Details
Unclean script to fix cmake building failed (bootstrap-prefix.sh,86.63 KB, application/x-shellscript)
2017-07-21 07:04 UTC, Too Anuchit
Details

Note You need to log in before you can comment on or make changes to this bug.
Description bashow 2017-07-12 16:45:52 UTC
Created attachment 483374 [details]
Error : cmake

Install gentoo prefix stage2 in MacOS Sierra 

* ERROR: dev-util/cmake-3.8.2::gentoo_prefix failed (configure phase):
 *   cmake failed
 * 
 * Call stack:
 *     ebuild.sh, line  115:  Called src_configure
 *   environment, line 3434:  Called cmake-utils_src_configure
 *   environment, line  971:  Called die
 * The specific snippet of code:
 *       "${CMAKE_BINARY}" "${cmakeargs[@]}" "${CMAKE_USE_DIR}" || die "cmake failed";
 * 
 * If you need support, post the output of `emerge --info '=dev-util/cmake-3.8.2::gentoo_prefix'`,
 * the complete build log and the output of `emerge -pqv '=dev-util/cmake-3.8.2::gentoo_prefix'`.
 * The complete build log is located at '/Users/bashow/gentoo/tmp/var/tmp/portage/dev-util/cmake-3.8.2/temp/build.log'.
 * The ebuild environment file is located at '/Users/bashow/gentoo/tmp/var/tmp/portage/dev-util/cmake-3.8.2/temp/environment'.
 * Working directory: '/Users/bashow/gentoo/tmp/var/tmp/portage/dev-util/cmake-3.8.2/work/cmake-3.8.2_build'
 * S: '/Users/bashow/gentoo/tmp/var/tmp/portage/dev-util/cmake-3.8.2/work/cmake-3.8.2'
Comment 1 Too Anuchit 2017-07-19 12:45:21 UTC
Created attachment 485654 [details]
build.log of emerging cmake

/bin/bash ./bootstrap-prefix.sh "/Users/too/Gentoo" stage2 failed. Details as build.log
Comment 2 Too Anuchit 2017-07-20 03:33:05 UTC
(In reply to Too Anuchit from comment #1)
> Created attachment 485654 [details]
> build.log of emerging cmake
> 
> /bin/bash ./bootstrap-prefix.sh "/Users/too/Gentoo" stage2 failed. Details
> as build.log

To fix this error, I added a line for the missing CMake rdepend "app-crypt/rhash" to bootstrap-prefix.sh.

-------
# Build a basic compiler and portage dependencies in $ROOT/tmp.
        pkgs=(  
                app-portage/elt-patches 
                $([[ ${CHOST} == *-aix* ]] && echo dev-libs/libiconv ) # bash dependency
                $([[ ${CHOST} == *-cygwin* ]] && echo dev-libs/libiconv ) # bash dependency               
                sys-libs/ncurses
                sys-libs/readline
                app-shells/bash
                app-arch/xz-utils
                sys-apps/sed
                sys-apps/gentoo-functions
                sys-apps/baselayout-prefix
                dev-libs/libffi
                sys-devel/m4
                sys-devel/flex
                sys-apps/diffutils # needed by bison-3 build system
                sys-devel/bison
                sys-devel/patch
                sys-devel/binutils-config
                app-crypt/rhash  # needed by CMake-3.8.2 <===
        ) 
-----
Comment 3 bashow 2017-07-21 06:56:40 UTC
Created attachment 486250 [details]
Configuring incomplete, errors occurred

stage3 error...
Comment 4 Too Anuchit 2017-07-21 07:03:56 UTC
(In reply to bashow from comment #3)
> Created attachment 486250 [details]
> Configuring incomplete, errors occurred
> 
> stage3 error...

Yep. I had to add that line for stage3 as well. 
Look at the line 1642 as the attached script.
Comment 5 Too Anuchit 2017-07-21 07:04:58 UTC
Created attachment 486252 [details]
Unclean script to fix cmake building failed
Comment 6 Benda Xu gentoo-dev 2018-03-19 23:15:42 UTC
This newer versions of cmake ebuild has rhash as dependency, is this bug resolved?
Comment 7 Benda Xu gentoo-dev 2018-03-19 23:16:19 UTC
*** Bug 626262 has been marked as a duplicate of this bug. ***
Comment 8 Samuel Bernardo 2018-03-20 00:36:53 UTC
Same problem here with cmake-3.10.3, but I've rhash-1.3.6 installed.

-- Could NOT find LibRHash (missing: LibRHash_INCLUDE_DIR) 
CMake Error at CMakeLists.txt:350 (message):
  CMAKE_USE_SYSTEM_LIBRHASH is ON but LibRHash is not found!
Call Stack (most recent call first):
  CMakeLists.txt:662 (CMAKE_BUILD_UTILITIES)
Comment 9 Fabian Groffen gentoo-dev 2018-03-20 08:06:15 UTC
yeah, you need librhash-1.3.6-r1, the headers weren't installed in the previous version
Comment 10 Preston Crow 2018-03-20 14:21:42 UTC
It's not just that you need rhash, you need the latest version.

I had app-crypt/rhash-1.3.6 installed, and I was hitting this bug.  I see today that app-crypt/rash-1.3.6-r1 is now available, and upgrading allows the new cmake to build cleanly.

So the correct ebuild fix is going to require >=app-crypt/rash-1.3.6-r1 unless I'm missing something.
Comment 11 James Le Cuirot gentoo-dev 2018-03-20 14:35:10 UTC
(In reply to Preston Crow from comment #10)
> It's not just that you need rhash, you need the latest version.
> 
> I had app-crypt/rhash-1.3.6 installed, and I was hitting this bug.  I see
> today that app-crypt/rash-1.3.6-r1 is now available, and upgrading allows
> the new cmake to build cleanly.
> 
> So the correct ebuild fix is going to require >=app-crypt/rash-1.3.6-r1
> unless I'm missing something.

Sometimes broken packages make it into the tree for a short time, about 15 hours in this case. It was just bad luck that you happened to sync during that time. It would be overkill to amend all reverse dependencies for blips like this. Users are generally expected to resync and check for newer versions first when encountering breakages like this, especially for non-stable packages.
Comment 12 James Le Cuirot gentoo-dev 2018-09-13 21:39:16 UTC
1.3.6-r1 is stable now and all older versions have been dropped. Closing.