Commits

Anthony Tuininga committed 74237e9

Include the workaround code for Python 2.5 and up as well since some
distributions are missing this code or it does not function properly; the
inclusion of this code does not cause gcc any difficulty with the duplicated
arguments.

Comments (0)

Files changed (1)

         libraries = self.get_libraries(ext)
         extraArgs = ext.extra_link_args or []
         if sys.platform != "win32":
-            if sys.version_info[:2] < (2, 5):
-                vars = distutils.sysconfig.get_config_vars()
-                libraryDirs.append(vars["LIBPL"])
-                libraries.append("python%s.%s" % sys.version_info[:2])
-                if vars["LINKFORSHARED"]:
-                    extraArgs.extend(vars["LINKFORSHARED"].split())
-                if vars["LIBS"]:
-                    extraArgs.extend(vars["LIBS"].split())
-                if vars["LIBM"]:
-                    extraArgs.append(vars["LIBM"])
-                if vars["BASEMODLIBS"]:
-                    extraArgs.extend(vars["BASEMODLIBS"].split())
-                if vars["LOCALMODLIBS"]:
-                    extraArgs.extend(vars["LOCALMODLIBS"].split())
+            vars = distutils.sysconfig.get_config_vars()
+            libraryDirs.append(vars["LIBPL"])
+            libraries.append("python%s.%s" % sys.version_info[:2])
+            if vars["LINKFORSHARED"]:
+                extraArgs.extend(vars["LINKFORSHARED"].split())
+            if vars["LIBS"]:
+                extraArgs.extend(vars["LIBS"].split())
+            if vars["LIBM"]:
+                extraArgs.append(vars["LIBM"])
+            if vars["BASEMODLIBS"]:
+                extraArgs.extend(vars["BASEMODLIBS"].split())
+            if vars["LOCALMODLIBS"]:
+                extraArgs.extend(vars["LOCALMODLIBS"].split())
             extraArgs.append("-s")
         self.compiler.link_executable(objects, fullName,
                 libraries = libraries,