Merge pull request #34706 from P-E-Meunier/xjump

Xjump: init at 2.9.3

authored by Michael Raskin and committed by GitHub e46553bc 17bc189a

+49
+21
pkgs/games/xjump/darwin.patch
··· 1 + --- xjump/src/main.c 2018-02-20 09:15:15.608807657 +0100 2 + +++ xjump-patched/src/main.c 2018-02-20 09:15:34.148949100 +0100 3 + @@ -604,18 +604,6 @@ 4 + * optimistic privilege dropping function. */ 5 + setgroups(0, NULL); 6 + 7 + - if (setresgid(-1, realgid, realgid) != 0) { 8 + - perror("Could not drop setgid privileges. Aborting."); 9 + - exit(1); 10 + - } 11 + - 12 + - /* Dropping user privileges must come last. 13 + - * Otherwise we won't be able to drop group privileges anymore */ 14 + - if (setresuid(-1, realuid, realuid) != 0) { 15 + - perror("Could not drop setuid privileges. Aborting."); 16 + - exit(1); 17 + - } 18 + - 19 + /* From now on we run with regular user privileges */ 20 + 21 + static XtActionsRec a_table[] = {
+27
pkgs/games/xjump/default.nix
··· 1 + { stdenv, buildPlatform, fetchFromGitHub, autoconf, automake, libX11, libXt, libXpm, libXaw, localStateDir?null }: 2 + 3 + stdenv.mkDerivation rec { 4 + name = "xjump-${version}"; 5 + version = "2.9.3"; 6 + src = fetchFromGitHub { 7 + owner = "hugomg"; 8 + repo = "xjump"; 9 + rev = "e7f20fb8c2c456bed70abb046c1a966462192b80"; 10 + sha256 = "0hq4739cvi5a47pxdc0wwkj2lmlqbf1xigq0v85qs5bq3ixmq2f7"; 11 + }; 12 + nativeBuildInputs = [ autoconf automake ]; 13 + buildInputs = [ libX11 libXt libXpm libXaw ]; 14 + preConfigure = "autoreconf --install"; 15 + patches = if buildPlatform.isDarwin then [ ./darwin.patch ] else []; 16 + configureFlags = 17 + if localStateDir != null then 18 + ["--localstatedir=${localStateDir}"] 19 + else 20 + []; 21 + 22 + meta = with stdenv.lib; { 23 + description = "The falling tower game"; 24 + license = licenses.gpl2; 25 + maintainers = with maintainers; [ pmeunier ]; 26 + }; 27 + }
+1
pkgs/top-level/all-packages.nix
··· 19037 19037 tk = tk-8_5; 19038 19038 }; 19039 19039 19040 + xjump = callPackage ../games/xjump { }; 19040 19041 # TODO: the corresponding nix file is missing 19041 19042 # xracer = callPackage ../games/xracer { }; 19042 19043