Switch to unified view

a/src/python/recoll/setup.py.in b/src/python/recoll/setup.py.in
...
...
4
4
5
sysname = os.uname()[0]
5
sysname = os.uname()[0]
6
top = os.path.join('..', '..')
6
top = os.path.join('..', '..')
7
7
8
8
9
library_dirs = [os.path.join(top, 'lib')]
9
library_dirs = [os.path.join(top, '.libs')]
10
if "CYGWIN" in os.environ:
10
if "CYGWIN" in os.environ:
11
    libraries =  ['recoll', 'xapian', 'iconv', 'z']
11
    libraries =  ['recoll', 'xapian', 'iconv', 'z']
12
else:
12
else:
13
    libraries = ['recoll']
13
    libraries = ['recoll']
14
    
14
    
...
...
16
if 'libdir' in os.environ and os.environ['libdir'] != "":
16
if 'libdir' in os.environ and os.environ['libdir'] != "":
17
    runtime_library_dirs = [os.path.join(os.environ['libdir'], 'recoll')]
17
    runtime_library_dirs = [os.path.join(os.environ['libdir'], 'recoll')]
18
else:
18
else:
19
    runtime_library_dirs = [os.path.join('@prefix@', 'lib', 'recoll')]
19
    runtime_library_dirs = [os.path.join('@prefix@', 'lib', 'recoll')]
20
20
21
# Verify that the Recoll library was compiled with the PIC options
22
localdefs = os.path.join(top, 'mk', 'localdefs')
23
try:
24
    lines = open(localdefs, 'r').readlines()
25
except:
26
    print('You need to build recoll first. Use configure --enable-pic')
27
    sys.exit(1)
28
picok = False
29
for line in lines:
30
    if line.find('PICFLAGS') == 0:
31
        picok = True
32
        break
33
if not picok:
34
    print('You need to rebuild recoll with PIC enabled. Use configure --enable-pic and make clean')
35
    sys.exit(1)
36
37
                               
38
module1 = Extension('recoll',
21
module1 = Extension('recoll',
39
                    define_macros = [('MAJOR_VERSION', '1'),
22
                    define_macros = [('MAJOR_VERSION', '1'),
40
                                     ('MINOR_VERSION', '0'),
23
                                     ('MINOR_VERSION', '0'),
41
                                     ('UNAC_VERSION', '"1.0.7"'),
24
                                     ('UNAC_VERSION', '"1.0.7"'),
42
                                     ('RECOLL_DATADIR', '"@QTRECOLL_DATADIR@"')
25
                                     ('RECOLL_DATADIR', '"@RECOLL_DATADIR@"')
43
                                     ],
26
                                     ],
44
                    include_dirs = ['/usr/local/include',
27
                    include_dirs = ['/usr/local/include',
45
                                    os.path.join(top, 'utils'), 
28
                                    os.path.join(top, 'utils'), 
46
                                    os.path.join(top, 'common'), 
29
                                    os.path.join(top, 'common'), 
47
                                    os.path.join(top, 'rcldb'), 
30
                                    os.path.join(top, 'rcldb'), 
...
...
55
38
56
module2 = Extension('rclextract',
39
module2 = Extension('rclextract',
57
                    define_macros = [('MAJOR_VERSION', '1'),
40
                    define_macros = [('MAJOR_VERSION', '1'),
58
                                     ('MINOR_VERSION', '0'),
41
                                     ('MINOR_VERSION', '0'),
59
                                     ('UNAC_VERSION', '"1.0.7"'),
42
                                     ('UNAC_VERSION', '"1.0.7"'),
60
                                     ('RECOLL_DATADIR', '"@QTRECOLL_DATADIR@"')
43
                                     ('RECOLL_DATADIR', '"@RECOLL_DATADIR@"')
61
                                     ],
44
                                     ],
62
                    include_dirs = ['/usr/local/include',
45
                    include_dirs = ['/usr/local/include',
63
                                    os.path.join(top, 'utils'), 
46
                                    os.path.join(top, 'utils'), 
64
                                    os.path.join(top, 'common'), 
47
                                    os.path.join(top, 'common'), 
65
                                    os.path.join(top, 'internfile'), 
48
                                    os.path.join(top, 'internfile'),