Skip to content

Support external find for gpgme.#18594

Merged
adamjstewart merged 1 commit intospack:developfrom
paulbry:gpgme-external-find
Sep 9, 2020
Merged

Support external find for gpgme.#18594
adamjstewart merged 1 commit intospack:developfrom
paulbry:gpgme-external-find

Conversation

@paulbry
Copy link
Copy Markdown
Contributor

@paulbry paulbry commented Sep 9, 2020

Adding support for external find command to the gpgme package:

$ spack external find gpgme
==> The following specs have been detected on this system and added to /root/.spack/packages.yaml
[email protected]
$ cat ~/.spack/packages.yaml 
packages:
  gpgme:
    externals:
    - spec: [email protected]
      prefix: /usr

Comment on lines +27 to +29
output = Executable(exe)('--version', output=str, error=str)
match = re.search(r'(\S+)', output)
return match.group(1) if match else None
Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
output = Executable(exe)('--version', output=str, error=str)
match = re.search(r'(\S+)', output)
return match.group(1) if match else None
return Executable(exe)('--version', output=str, error=str).rstrip()

This is how I do it in the GDAL package.

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks, that is much easier.

@paulbry paulbry force-pushed the gpgme-external-find branch from 9295b5d to acf1696 Compare September 9, 2020 22:01
@adamjstewart adamjstewart merged commit 9eac1ed into spack:develop Sep 9, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants