1 |
root |
1.1 |
use ExtUtils::MakeMaker; |
2 |
|
|
|
3 |
root |
1.7 |
print <<EOF; |
4 |
|
|
|
5 |
|
|
*** *** *** *** *** *** *** *** *** *** *** *** *** *** *** *** *** *** |
6 |
|
|
|
7 |
|
|
|
8 |
|
|
OpenCL does not have good backwards compatibility - for example, the only |
9 |
|
|
way to create a 2D image in OpenCL 1.1 is clCreateImage2D, which is not |
10 |
|
|
available anymore with OpenCL 1.2. |
11 |
|
|
|
12 |
|
|
The OpenCL module can often emulate OpenCL 1.1 functions using OpenCL 1.2 |
13 |
|
|
functions, but even though your OpenCL library might contain the OpenCL |
14 |
root |
1.8 |
1.2 functions, they might be nonfunctional and crash. |
15 |
root |
1.7 |
|
16 |
|
|
Do you want to prefer the OpenCL 1.1 API over the 1.2 API where possible? |
17 |
|
|
|
18 |
|
|
EOF |
19 |
|
|
|
20 |
|
|
my $DEFINE .= " -DPREFER_1_1=" . (0 + (prompt ("Prefer OpenCL 1.1 over 1.2 functions (y/n)?", "y") =~ /[yY]/)); |
21 |
|
|
|
22 |
root |
1.1 |
WriteMakefile( |
23 |
|
|
dist => { |
24 |
|
|
PREOP => 'pod2text OpenCL.pm | tee README >$(DISTVNAME)/README; chmod -R u=rwX,go=rX . ;', |
25 |
|
|
COMPRESS => 'gzip -9v', |
26 |
|
|
SUFFIX => '.gz', |
27 |
|
|
}, |
28 |
root |
1.3 |
PREREQ_PM => { |
29 |
root |
1.9 |
common::sense => 0, |
30 |
|
|
# Async::Interrupt => 0, |
31 |
root |
1.2 |
}, |
32 |
root |
1.4 |
DEFINE => $DEFINE, |
33 |
root |
1.1 |
NAME => "OpenCL", |
34 |
|
|
VERSION_FROM => "OpenCL.pm", |
35 |
root |
1.2 |
LIBS => ["-lOpenCL"], |
36 |
root |
1.1 |
); |
37 |
|
|
|