Created
July 12, 2019 21:42
-
-
Save lukateras/845721fb29ef1074634825c430645381 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
with import <nixpkgs> {}; | |
stdenv.mkDerivation rec { | |
name = "cloudi-${version}"; | |
version = "1.7.5"; | |
src = fetchzip { | |
url = "https://osdn.net/dl/cloudi/${name}.tar.gz"; | |
sha256 = "0aj0rwzfyad99gnm27km705ba46nsdy1ww87qgk3cfpi0017wx86"; | |
}; | |
patches = [ ./no-mkdir-logs.diff ]; | |
preAutoreconf = "cd src"; | |
postFixup = '' | |
substituteInPlace $out/etc/cloudi/cloudi.conf --replace $out/lib/${name}/logs /tmp | |
substituteInPlace $out/lib/${name}/bin/cloudi --replace '$ROOTDIR/logs' /tmp | |
''; | |
nativeBuildInputs = [ autoreconfHook ]; | |
buildInputs = [ | |
boost | |
erlang | |
ncurses | |
systemd | |
]; | |
configureFlags = [ | |
"--enable-java-support=no" | |
"--enable-javascript-support=no" | |
"--enable-perl-support=no" | |
"--enable-php-support=no" | |
"--enable-ruby-support=no" | |
"--enable-python-support=no" | |
"--enable-python-c-support=no" | |
"--localstatedir=/var" | |
"--with-boost-libdir=${boost}/lib" # autoconf expects a different location | |
"--with-integration-tests=no" | |
]; | |
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
--- a/src/Makefile.am 2018-12-19 05:04:03.000000000 +0300 | |
+++ b/src/Makefile.am 2019-07-11 19:11:50.373137331 +0300 | |
@@ -345,7 +345,6 @@ | |
install-exec-hook: | |
$(MKDIR_P) "$(DESTDIR)$(bindir)" | |
- $(MKDIR_P) "$(DESTDIR)$(cloudi_logdir)" | |
$(MKDIR_P) "$(DESTDIR)$(cloudi_confdir)" | |
$(MKDIR_P) "$(DESTDIR)$(cloudi_bindir)" | |
$(MKDIR_P) "$(DESTDIR)$(cloudi_prefix)" | |
@@ -353,8 +352,7 @@ | |
$(MKDIR_P) "$(DESTDIR)$(cloudi_prefix)/lib" | |
$(MKDIR_P) "$(DESTDIR)$(cloudi_prefix)/releases" | |
(cd "$(DESTDIR)$(cloudi_prefix)" && \ | |
- test ! -e etc && $(LN_S) "$(cloudi_confdir)" etc || exit 0 && \ | |
- test ! -e logs && $(LN_S) "$(cloudi_logdir)" logs || exit 0) | |
+ test ! -e etc && $(LN_S) "$(cloudi_confdir)" etc || exit 0) | |
test -e "$(DESTDIR)$(cloudi_confdir)/cloudi.conf" && \ | |
mv -f "$(DESTDIR)$(cloudi_confdir)/cloudi.conf" \ | |
"$(DESTDIR)$(cloudi_confdir)/cloudi.conf.old" || exit 0 |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment