]> git.pld-linux.org Git - packages/rpm.git/blob - python-internal-build.patch
- fix building python bindings (force librarries from build tree)
[packages/rpm.git] / python-internal-build.patch
1 --- rpm-4.15.1/python/setup.py.in.orig  2019-06-26 23:17:31.000000000 +0900
2 +++ rpm-4.15.1/python/setup.py.in       2020-01-01 01:58:28.121517896 +0900
3 @@ -12,17 +12,8 @@
4          out.append(token[2:])
5      return out
6  
7 -cflags = ['-std=c99', '-Wno-strict-aliasing']
8 -additional_link_args = []
9 -
10 -# See if we're building in-tree
11 -if os.access('Makefile.am', os.F_OK):
12 -    cflags.append('-I../include')
13 -    additional_link_args.extend(['-Wl,-L../rpmio/.libs',
14 -                                 '-Wl,-L../lib/.libs',
15 -                                 '-Wl,-L../build/.libs',
16 -                                 '-Wl,-L../sign/.libs'])
17 -    os.environ['PKG_CONFIG_PATH'] = '..'
18 +cflags = ['-std=c99', '-Wno-strict-aliasing', '-I../include']
19 +os.environ['PKG_CONFIG_PATH'] = '..'
20  
21  rpmmod = Extension('rpm._rpm',
22                     sources = ['header-py.c', 'rpmds-py.c', 'rpmfd-py.c',
23 @@ -33,11 +24,9 @@
24                                'rpmte-py.c', 'rpmts-py.c',
25                                'spec-py.c',
26                                'rpmmodule.c'],
27 -                   include_dirs = pkgconfig('--cflags'),
28 -                   library_dirs = pkgconfig('--libs-only-L'),
29 +                   library_dirs = ['../rpmio/.libs', '../lib/.libs', '../build/.libs', '../sign/.libs'],
30                     libraries = pkgconfig('--libs-only-l') + ['rpmbuild', 'rpmsign'],
31                     extra_compile_args = cflags,
32 -                   extra_link_args = additional_link_args
33                    )
34  
35  setup(name='@PACKAGE_NAME@',
This page took 0.060059 seconds and 3 git commands to generate.