cmake: Fix build and setup hook

I screwed this up in 330ca731e88ec015181c43d92ae8f7c77cf0226a. I'm
sorry.
This commit is contained in:
John Ericson 2018-05-15 15:24:22 -04:00
parent 330ca731e8
commit 0ff650a392
2 changed files with 6 additions and 5 deletions

@ -82,6 +82,10 @@ stdenv.mkDerivation rec {
configureFlags = [
"--docdir=share/doc/${name}"
] ++ (if useSharedLibraries then [ "--no-system-jsoncpp" "--system-libs" ] else [ "--no-system-libs" ]) # FIXME: cleanup
++ optional (useQt4 || withQt5) "--qt-gui"
++ [
"--"
# We should set the proper `CMAKE_SYSTEM_NAME`.
# http://www.cmake.org/Wiki/CMake_Cross_Compiling
#
@ -93,10 +97,7 @@ stdenv.mkDerivation rec {
"-DCMAKE_AR=${getBin stdenv.cc.bintools.bintools}/bin/${stdenv.cc.targetPrefix}ar"
"-DCMAKE_RANLIB=${getBin stdenv.cc.bintools.bintools}/bin/${stdenv.cc.targetPrefix}ranlib"
"-DCMAKE_STRIP=${getBin stdenv.cc.bintools.bintools}/bin/${stdenv.cc.targetPrefix}strip"
] ++ (if useSharedLibraries then [ "--no-system-jsoncpp" "--system-libs" ] else [ "--no-system-libs" ]) # FIXME: cleanup
++ optional (useQt4 || withQt5) "--qt-gui"
++ ["--"]
++ optionals (!useNcurses) [ "-DBUILD_CursesDialog=OFF" ];
] ++ optionals (!useNcurses) [ "-DBUILD_CursesDialog=OFF" ];
dontUseCmakeConfigure = true;
enableParallelBuilding = true;

@ -38,7 +38,7 @@ cmakeConfigurePhase() {
cmakeFlags="-DCMAKE_CXX_COMPILER=$CXX $cmakeFlags"
cmakeFlags="-DCMAKE_C_COMPILER=$CC $cmakeFlags"
cmakeFlags="-DCMAKE_AR=$(command -v $AR) $cmakeFlags"
cmakeFlags="-DCMAKE_RANLIB=$(command -v $RANLAB) $cmakeFlags"
cmakeFlags="-DCMAKE_RANLIB=$(command -v $RANLIB) $cmakeFlags"
cmakeFlags="-DCMAKE_STRIP=$(command -v $STRIP) $cmakeFlags"
# This installs shared libraries with a fully-specified install