This repository has been archived by the owner on Aug 9, 2022. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 0
/
plan.sh
67 lines (61 loc) · 1.84 KB
/
plan.sh
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
pkg_name=pcre
pkg_origin=core
pkg_version=8.45
pkg_maintainer="The Habitat Maintainers <humans@habitat.sh>"
pkg_description="\
The PCRE library is a set of functions that implement regular expression \
pattern matching using the same syntax and semantics as Perl 5. PCRE has its \
own native API, as well as a set of wrapper functions that correspond to the \
POSIX regular expression API. The PCRE library is free, even for building \
proprietary software.\
"
pkg_upstream_url="http://www.pcre.org/"
pkg_license=('bsd')
pkg_source="https://sourceforge.net/projects/${pkg_name}/files/${pkg_name}-${pkg_version}.tar.bz2"
pkg_shasum="4dae6fdcd2bb0bb6c37b5f97c33c2be954da743985369cddac3546e3218bffb8"
pkg_deps=(
core/glibc
core/gcc-libs
)
pkg_build_deps=(
core/coreutils
core/diffutils
core/patch
core/make
core/gcc
)
pkg_bin_dirs=(bin)
pkg_include_dirs=(include)
pkg_lib_dirs=(lib)
pkg_pconfig_dirs=(lib/pkgconfig)
do_build() {
./configure \
--prefix="$pkg_prefix" \
--enable-unicode-properties \
--enable-utf \
--enable-pcre16 \
--enable-pcre32 \
--enable-jit
make -j"$(nproc)"
}
do_check() {
make check
}
do_install() {
do_default_install
# Install license file
install -Dm644 LICENCE "$pkg_prefix/share/licenses/LICENSE"
}
# ----------------------------------------------------------------------------
# **NOTICE:** What follows are implementation details required for building a
# first-pass, "stage1" toolchain and environment. It is only used when running
# in a "stage1" Studio and can be safely ignored by almost everyone. Having
# said that, it performs a vital bootstrapping process and cannot be removed or
# significantly altered. Thank you!
# ----------------------------------------------------------------------------
if [[ "$STUDIO_TYPE" = "stage1" ]]; then
pkg_build_deps=(
core/gcc
core/coreutils
)
fi