~vonfry/omnetpp-nix

e9e618f0483c3b9e99127f124a71c04900d039d4 — Vonfry 11 months ago 46ed12b
omnetpp: update to 5.7
2 files changed, 16 insertions(+), 12 deletions(-)

M default.nix
M patch.omnetpp
M default.nix => default.nix +10 -6
@@ 39,7 39,7 @@ stdenv.mkDerivation rec {

  src = fetchurl {
    url = "https://github.com/omnetpp/omnetpp/releases/download/${pname}-${version}/${pname}-${version}-linux-x86_64.tgz";
    sha256 = "";
    sha256 = "sha256-BNx7NzG1vVY44fRu8h+virlVLY2rShS9Iil0EeJXM5k=";
  };

  outputs = [ "out" ];


@@ 90,15 90,17 @@ stdenv.mkDerivation rec {
                   ++ optional preferSqlite "PREFER_SQLITE_RESULT_FILES=yes";

  preConfigure = ''
    omnetpp_root=`pwd`
    export PATH=$omnetpp_root/bin:$PATH
    export HOSTNAME
    export HOST
    export __omnetpp_root_dir=`pwd`
    export PATH=$__omnetpp_root_dir/bin:$PATH
    export OMNETPP_RELEASE=$(cat $__omnetpp_root_dir/Version)
    export HOSTNAME=
    export HOST=
    export QT_SELECT=5 # on systems with qtchooser, switch to Qt5
    export QT_LOGGING_RULES='*.debug=false;qt.qpa.*=false'
    # use patch instead, becasue of configure script has a problem with space
    # split between ~isystem~ and ~path~.
    export AR="ar cr"
    '';
  '';

  enableParallelBuilding = true;



@@ 175,6 177,8 @@ stdenv.mkDerivation rec {
          --set GTK_THEME Awaita
    '';

  dontPatchShebangs = false;

  meta = with lib; {
    homepage= "https://omnetpp.org";
    description = "OMNeT++ is an extensible, modular, component-based C++ simulation library and framework, primarily for building network simulators.";

M patch.omnetpp => patch.omnetpp +6 -6
@@ 1,18 1,18 @@
diff --git a/src/utils/omnetpp b/src/utils/omnetpp
index 1f808e4535..ebc8fa9c5f 100755
index a0a5488..c34d84d 100755
--- a/src/utils/omnetpp
+++ b/src/utils/omnetpp
@@ -5,6 +5,8 @@
 IDEDIR=`dirname $0`/../ide
 PLATFORM=`uname -sm`
 LAUNCHER=omnetpp
+TMPDIR=/tmp/omnetpp
+TMPDIR=/tmp
+mkdir -p $TMPDIR
 

 echo Starting the OMNeT++ IDE...
 
@@ -28,16 +30,16 @@ DEFAULT_WORKSPACE_ARGS="-vmargs -Dosgi.instance.area.default=$IDEDIR/../samples"
 

@@ -20,16 +22,16 @@ DEFAULT_WORKSPACE_ARGS="-vmargs -Dosgi.instance.area.default=$IDEDIR/../samples"

 case $PLATFORM in
 *MINGW*)
-	$IDEDIR/${LAUNCHER}.exe "$@" $DEFAULT_WORKSPACE_ARGS 2>$IDEDIR/error.log &