Magellan Linux

Contents of /trunk/samba/patches/samba-3.0.20b-python-setup.patch

Parent Directory Parent Directory | Revision Log Revision Log


Revision 153 - (show annotations) (download)
Tue May 8 20:52:56 2007 UTC (17 years ago) by niro
File size: 1283 byte(s)
-import

1 --- source/python/setup.py 2005-10-06 11:38:42.000000000 +0200
2 +++ source/python/setup.py.new 2005-10-06 11:43:52.000000000 +0200
3 @@ -52,21 +52,33 @@
4 libraries = []
5 library_dirs = []
6
7 +next_is_path = 0
8 +next_is_flag = 0
9 for lib in string.split(samba_libs):
10 - if lib[0:2] == "-l":
11 - libraries.append(lib[2:])
12 + if next_is_path <> 0:
13 + library_dirs.append(lib);
14 + next_is_path = 0;
15 + continue
16 + elif next_is_flag <> 0:
17 + next_is_flag = 0;
18 + continue
19 + elif lib == "-Wl,-rpath":
20 + next_is_path = 1;
21 continue
22 - if lib[0:8] == "-pthread":
23 + elif lib[0:2] in ("-l","-pthread"):
24 libraries.append(lib[2:])
25 continue
26 - if lib[0:2] == "-L":
27 + elif lib[0:2] == "-L":
28 library_dirs.append(lib[2:])
29 continue
30 - if lib[0:2] == "-W":
31 - # Skip linker flags
32 + elif lib[0:2] in ("-W","-s"):
33 + continue # Skip linker flags
34 + elif lib[0:2] == "-z":
35 + next_is_flag = 1 # Skip linker flags
36 continue
37 - print "Unknown entry '%s' in $LIBS variable passed to setup.py" % lib
38 - sys.exit(1)
39 + else:
40 + print "Unknown entry '%s' in $LIBS variable passed to setup.py" % lib
41 + sys.exit(1)
42
43 flags_list = string.split(samba_cflags)
44