-
Notifications
You must be signed in to change notification settings - Fork 0
/
alienfile
58 lines (46 loc) · 1.32 KB
/
alienfile
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
use alienfile;
use Env qw(@PKG_CONFIG_PATH @ACLOCAL_PATH);
plugin PkgConfig => 'hdt';
share {
# NOTE Disable using Alien::Autotools and
# '%{autoreconf} -vfi',
# for now.
#requires 'Alien::Autotools';
requires 'Alien::Serd';
requires 'Alien::zlib';
# https://github.com/rdfhdt/hdt-cpp
# https://www.rdfhdt.org/
start_url 'https://github.com/rdfhdt/hdt-cpp/archive/d9ae092bb37d9fe85558dfb3edfe0bb6ddddf41a.tar.gz';
plugin Download => ();
plugin Extract => 'tar.gz';
plugin 'Build::Autoconf';
my $patch = [
'%{patch} -p4 -d libhdt/src/util < %{.install.patch}/gh-pr-273.patch'
];
patch $patch;
eval {
eval "require Alien::Serd;" or die "Could not load Alien::Serd";
push @PKG_CONFIG_PATH, Alien::Serd->pkg_config_path;
} or warn "Unable to add to \$PKG_CONFIG_PATH (@PKG_CONFIG_PATH): $@";
if( exists $ENV{MSYSTEM} ) {
# Need for call to `autoreconf` in `./autogen.sh`.
push @ACLOCAL_PATH,
(
'm4',
"/@{[ lc $ENV{MSYSTEM} ]}/share/aclocal"
);
}
build [
# shared
'sh ./autogen.sh',
'%{configure} --disable-static --enable-shared',
'%{make}',
'%{make} install',
# static
'sh ./autogen.sh',
'%{configure} --enable-static --disable-shared',
'%{make}',
'%{make} install',
];
plugin 'Gather::IsolateDynamic';
}