diff options
Diffstat (limited to 'meta/recipes-support/gpgme/gpgme/0002-gpgme-lang-python-gpg-error-config-should-not-be-use.patch')
-rw-r--r-- | meta/recipes-support/gpgme/gpgme/0002-gpgme-lang-python-gpg-error-config-should-not-be-use.patch | 65 |
1 files changed, 65 insertions, 0 deletions
diff --git a/meta/recipes-support/gpgme/gpgme/0002-gpgme-lang-python-gpg-error-config-should-not-be-use.patch b/meta/recipes-support/gpgme/gpgme/0002-gpgme-lang-python-gpg-error-config-should-not-be-use.patch new file mode 100644 index 0000000000..f1f8c911fc --- /dev/null +++ b/meta/recipes-support/gpgme/gpgme/0002-gpgme-lang-python-gpg-error-config-should-not-be-use.patch | |||
@@ -0,0 +1,65 @@ | |||
1 | From fb165c9bd96aca8c9ee3e4509c9b6e35d238ad2e Mon Sep 17 00:00:00 2001 | ||
2 | From: Mark Hatle <mark.hatle@windriver.com> | ||
3 | Date: Wed, 16 Aug 2017 02:02:47 -0400 | ||
4 | Subject: [PATCH 2/5] gpgme/lang/python: gpg-error-config should not be used. | ||
5 | |||
6 | gpg-error-config was modified by OE to always return an error. So we want | ||
7 | to find an alternative way to retrieve whatever it is we need. It turns | ||
8 | out that the system is just trying to find the path to the gpg-error.h, which | ||
9 | we can pull in from the STAGING_INC environment. | ||
10 | |||
11 | Upstream-Status: Inappropriate [changes are specific to OE] | ||
12 | |||
13 | Signed-off-by: Mark Hatle <mark.hatle@windriver.com> | ||
14 | |||
15 | Rebase to 1.9.0 | ||
16 | |||
17 | Signed-off-by: Hongxu Jia <hongxu.jia@windriver.com> | ||
18 | --- | ||
19 | lang/python/setup.py.in | 15 ++------------- | ||
20 | 1 file changed, 2 insertions(+), 13 deletions(-) | ||
21 | |||
22 | diff --git a/lang/python/setup.py.in b/lang/python/setup.py.in | ||
23 | index bf4efa3..7c34487 100755 | ||
24 | --- a/lang/python/setup.py.in | ||
25 | +++ b/lang/python/setup.py.in | ||
26 | @@ -24,7 +24,6 @@ import glob | ||
27 | import subprocess | ||
28 | |||
29 | # Out-of-tree build of the gpg bindings. | ||
30 | -gpg_error_config = ["gpg-error-config"] | ||
31 | gpgme_config_flags = ["--thread=pthread"] | ||
32 | gpgme_config = ["gpgme-config"] + gpgme_config_flags | ||
33 | gpgme_h = "" | ||
34 | @@ -52,13 +51,6 @@ else: | ||
35 | devnull = open(os.devnull, "w") | ||
36 | |||
37 | try: | ||
38 | - subprocess.check_call(gpg_error_config + ['--version'], | ||
39 | - stdout=devnull) | ||
40 | -except: | ||
41 | - sys.exit("Could not find gpg-error-config. " + | ||
42 | - "Please install the libgpg-error development package.") | ||
43 | - | ||
44 | -try: | ||
45 | subprocess.check_call(gpgme_config + ['--version'], | ||
46 | stdout=devnull) | ||
47 | except: | ||
48 | @@ -81,12 +73,9 @@ if not (major > 1 or (major == 1 and minor >= 7)): | ||
49 | if not gpgme_h: | ||
50 | gpgme_h = os.path.join(getconfig("prefix")[0], "include", "gpgme.h") | ||
51 | |||
52 | -gpg_error_prefix = getconfig("prefix", config=gpg_error_config)[0] | ||
53 | -gpg_error_h = os.path.join(gpg_error_prefix, "include", "gpg-error.h") | ||
54 | +gpg_error_h = os.path.join(os.getenv('STAGING_INCDIR'), "gpg-error.h") | ||
55 | if not os.path.exists(gpg_error_h): | ||
56 | - gpg_error_h = \ | ||
57 | - glob.glob(os.path.join(gpg_error_prefix, "include", | ||
58 | - "*", "gpg-error.h"))[0] | ||
59 | + sys.exit("gpg_error_h not found: %s" % gpg_error_h) | ||
60 | |||
61 | print("Building python gpg module using {} and {}.".format(gpgme_h, gpg_error_h)) | ||
62 | |||
63 | -- | ||
64 | 2.8.1 | ||
65 | |||