tangled
alpha
login
or
join now
pyrox.dev
/
nixpkgs
lol
0
fork
atom
overview
issues
pulls
pipelines
vpcs: fix build with glibc 2.26
Tracking issue: #31696
Orivej Desh
8 years ago
41e0d4b6
23182233
+20
-5
2 changed files
expand all
collapse all
unified
split
pkgs
applications
virtualization
vpcs
default.nix
vpcs-0.8-glibc-2.26.patch
+6
-5
pkgs/applications/virtualization/vpcs/default.nix
···
6
6
version = "0.8";
7
7
8
8
src = fetchurl {
9
9
+
name = "${name}.tar.bz2";
9
10
url = "mirror://sourceforge/project/${pname}/${version}/${name}-src.tbz";
10
11
sha256 = "14y9nflcyq486vvw0na0fkfmg5dac004qb332v4m5a0vaz8059nw";
11
12
};
12
13
13
13
-
unpackCmd = "tar -xjf $src";
14
14
+
patches = [ ./vpcs-0.8-glibc-2.26.patch ];
14
15
15
16
buildInputs = [ glibc.static ];
16
17
17
17
-
buildPhase = ''
18
18
+
buildPhase = ''(
18
19
cd src
19
20
./mk.sh ${buildPlatform.platform.kernelArch}
20
20
-
'';
21
21
+
)'';
21
22
22
23
installPhase = ''
23
23
-
cd ..
24
24
-
25
24
install -D -m555 src/vpcs $out/bin/vpcs;
26
25
install -D -m444 man/vpcs.1 $out/share/man/man1/vpcs.1;
27
26
'';
27
27
+
28
28
+
enableParallelBuilding = true;
28
29
29
30
meta = with stdenv.lib; {
30
31
description = "Virtual PC simulator";
+14
pkgs/applications/virtualization/vpcs/vpcs-0.8-glibc-2.26.patch
···
1
1
+
diff --git a/src/getopt.h b/src/getopt.h
2
2
+
index 4394aa2..bf59e10 100644
3
3
+
--- a/src/getopt.h
4
4
+
+++ b/src/getopt.h
5
5
+
@@ -49,9 +49,6 @@ extern int optind;
6
6
+
extern int opterr;
7
7
+
extern int optopt;
8
8
+
9
9
+
-#ifndef FreeBSD
10
10
+
-int getopt(int argc, char** argv, char* optstr);
11
11
+
-#endif
12
12
+
int arg_to_int(const char* arg, int min, int max, int defalt);
13
13
+
14
14
+
#ifdef __cplusplus