source: trunk/dports/sysutils/bash-completion/Portfile

Last change on this file was 151408, checked in by raimue@…, 15 months ago

sysutils/bash-completion:
Update to version 2.4,
remove patch for issue resolved upstream.

  • Property svn:eol-style set to native
  • Property svn:keywords set to Id
File size: 2.2 KB
Line 
1# $Id: Portfile 151408 2016-08-15 14:29:03Z ryandesign@macports.org $
2
3PortSystem      1.0
4PortGroup       github 1.0
5
6github.setup    scop bash-completion 2.4
7epoch           1
8conflicts       bash-completion-devel
9categories      sysutils
10platforms       darwin
11supported_archs noarch
12license         GPL-2+
13maintainers     raimue
14description     Programmable bash completions
15long_description \
16    Programmable completion library for bash. This port requires bash >=4.1 and \
17    is meant to be used together with the bash port.
18
19github.tarball_from releases
20use_xz yes
21
22checksums       rmd160  a560b9b7242d09b775843990c42d34dcd2473e48 \
23                sha256  c0f76b5202fec9ef8ffba82f5605025ca003f27cfd7a85115f838ba5136890f6
24
25depends_run     port:bash
26
27patchfiles      patch-vpnc.diff \
28                patch-fix-quote-readline-by-ref.diff \
29                patch-remove-pkgutil.diff
30
31post-patch {
32    reinplace "s:/etc/bash_completion:${prefix}/etc/bash_completion:g" \
33        ${worksrcpath}/bash_completion
34    reinplace "s:readlink -f:readlink:g" \
35        ${worksrcpath}/bash_completion
36
37    # Fix vpnc config location, #29281
38    reinplace "s:@@PREFIX@@:${prefix}:g" \
39        ${worksrcpath}/completions/vpnc
40}
41
42use_autoreconf yes
43
44post-destroot {
45    xinstall -m 644 -W ${filespath} port launchctl \
46        ${destroot}${prefix}/share/bash-completion/completions/
47
48    # Add a link for compatibility with versions <2.0 of this port
49    ln -s ${prefix}/etc/profile.d/bash_completion.sh ${destroot}${prefix}/etc/bash_completion
50}
51
52notes "
53To use bash_completion, add the following lines at the end of your .bash_profile:
54  if \[ -f ${prefix}/etc/profile.d/bash_completion.sh ]; then
55      . ${prefix}/etc/profile.d/bash_completion.sh
56  fi
57"
58
59if {${os.platform} eq "darwin" && ${os.subplatform} eq "macosx"} {
60    # Insert an empty line into the notes
61    notes-append ""
62    notes-append "
63        The port bash-completion >=2.0 requires bash >=4.1; please make sure
64        you are using ${prefix}/bin/bash by changing the preferences of your
65        terminal accordingly. If your version of bash is too old, the script
66        above will not modify your shell environment and no extended completion
67        will be available.
68    "
69}
70
71subport bash-completion-devel {
72    epoch 0
73    conflicts bash-completion
74
75    # nothing special at the moment
76}
Note: See TracBrowser for help on using the repository browser.