19 if stdenv.isLinux then "linux"
20 else if stdenv.isDarwin then "macosx"
21 else if stdenv.hostPlatform.isMinGW then "mingw"
22 else if stdenv.isFreeBSD then "freebsd"
23 else if stdenv.isSunOS then "solaris"
24 else if stdenv.hostPlatform.isBSD then "bsd"
25 else if stdenv.hostPlatform.isUnix then "posix"
28 binding stdenv.mkDerivation fromRepoOrCz
32 "INSTALL_TOP=${placeholder "out"}"
33 "INSTALL_MAN=${placeholder "out"}/share/man/man1"
36 "CC=${stdenv.cc.targetPrefix}cc"
37 "RANLIB=${stdenv.cc.targetPrefix}ranlib"
41 makeFlagsArray+=( TO_BIN='lua' )
42 makeFlagsArray+=( AR='${stdenv.cc.targetPrefix}ar rcu' )
43 makeFlagsArray+=( CFLAGS='-O2 -fPIC $("MYCFLAGS")' )
44 installFlagsArray=( INSTALL_DATA='cp -d' )