aboutsummaryrefslogtreecommitdiff
blob: 58b839fec1d7defa45461e2790b8f048ec44e9ad (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
https://bugs.gentoo.org/show_bug.cgi?id=281968
http://bugs.python.org/issue6731

--- setup.py
+++ setup.py
@@ -43,6 +43,8 @@
 else:
     disable_ssl = 0
 
+exit_status = 0
+
 def add_dir_to_list(dirlist, dir):
     """Add the directory 'dir' to the list 'dirlist' (after any relative
     directories) if:
@@ -277,6 +279,8 @@
             print()
 
         if self.failed:
+            global exit_status
+            exit_status = 1
             failed = self.failed[:]
             print()
             print("Failed to build these modules:")
@@ -2213,6 +2217,7 @@
           scripts = ["Tools/scripts/pydoc3", "Tools/scripts/idle3",
                      "Tools/scripts/2to3", "Tools/scripts/pyvenv"]
         )
+    sys.exit(exit_status)
 
 # --install-platlib
 if __name__ == '__main__':