- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Hello,
I just downloaded the latest SDK for OpenCL Applications 2014 Beta for Ubuntu, but I'm experiencing an issue that is not allowing me to successfully complete installation of the software. My environment is as follows:
CPU: Intel Core i7-3612QM (Ivy Bridge)
OS: Ubuntu 14.04 (LTS) x64
OpenCL 2014 Beta SDK: 4.0.1.17537 x64
After unpacking the tgz, I successfully installed the first two packages from the install-cpu.sh file: opencl-1.2-base-4.0.1.17537-1.x86_64.deb and opencl-1.2-devel-4.0.1.17537-1.x86_64.deb. However, the third package (opencl-1.2-intel-cpu-4.0.1.17537-1.x86_64.deb) fails to install with an error message that doesn't provide much insight into what went wrong. Below is the exact command line and output:
sudo dpkg -i opencl-1.2-intel-cpu-4.0.1.17537-1.x86_64.deb
(Reading database ... 208132 files and directories currently installed.)
Preparing to unpack opencl-1.2-intel-cpu-4.0.1.17537-1.x86_64.deb ...
/var/lib/dpkg/info/opencl-intel-cpu.prerm: 1: /var/lib/dpkg/info/opencl-intel-cpu.prerm: /usr/sbin/update-alternatives: not found
Unpacking opencl-intel-cpu (1.2-4.0.1.17537) over (1.2-4.0.1.17537) ...
Setting up opencl-intel-cpu (1.2-4.0.1.17537) ...
/var/lib/dpkg/info/opencl-intel-cpu.postinst: 2: /var/lib/dpkg/info/opencl-intel-cpu.postinst: [[: not found
/var/lib/dpkg/info/opencl-intel-cpu.postinst: 18: /var/lib/dpkg/info/opencl-intel-cpu.postinst: /usr/sbin/update-alternatives: not found
dpkg: error processing package opencl-intel-cpu (--install):
subprocess installed post-installation script returned error exit status 127
Errors were encountered while processing:
opencl-intel-cpu
Any help would be most appreciated!
Thanks,
Brandon
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
I had a chance over the weekend to revisit my issue and as it turns out resolve it myself. After having a closer look at the dpkg output, I noticed that one of those lines was complaining about the post install script not being able to find /usr/sbin/update-alternatives, which on my system is located at /usr/bin/update-alternatives and I had no symbolic link in /usr/sbin to it. Simply adding the appropriate symbolic link in /usr/sbin fixed my issue and all seems to be running fine.
However, I don't believe this is a fix to John I's issue - as I didn't see any dpkg output indicating an issue with finding update-alternatives.
Regards,
Brandon
Link Copied
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
I'm getting a similar problem on an Elitebook 2540p running LXDE wheezy
Error
In case of failure, refer to release notes at https://software.intel.com/en-us/vcsource/tools/opencl-sdk
Selecting previously unselected package opencl-base.
(Reading database ... 177420 files and directories currently installed.)
Unpacking opencl-base (from opencl-1.2-base-4.4.0.117-1.x86_64.deb) ...
Selecting previously unselected package opencl-intel-cpu.
Unpacking opencl-intel-cpu (from opencl-1.2-intel-cpu-4.4.0.117-1.x86_64.deb) ...
Selecting previously unselected package opencl-devel.
Unpacking opencl-devel (from opencl-1.2-devel-4.4.0.117-1.x86_64.deb) ...
Selecting previously unselected package opencl-intel-devel.
Unpacking opencl-intel-devel (from opencl-1.2-intel-devel-4.4.0.117-1.x86_64.deb) ...
Selecting previously unselected package opencl-intel-devel-android.
Unpacking opencl-intel-devel-android (from opencl-1.2-intel-devel-android-4.4.0.117-1.x86_64.deb) ...
Setting up opencl-base (1.2-4.4.0.117) ...
/var/lib/dpkg/info/opencl-base.postinst: 2: /var/lib/dpkg/info/opencl-base.postinst: [[: not found
update-alternatives: warning: priority is out of range: -2147489036 clamped to -2147483648
update-alternatives: using /opt/intel/opencl-1.2-4.4.0.117/lib64/libOpenCL.so to provide /usr/lib/x86_64-linux-gnu/libOpenCL.so (opencl-libOpenCL.so) in auto mode
update-alternatives: error: error creating symbolic link `/usr/lib/x86_64-linux-gnu/libOpenCL.so.dpkg-tmp': No such file or directory
dpkg: error processing opencl-base (--install):
subprocess installed post-installation script returned error exit status 2
dpkg: dependency problems prevent configuration of opencl-intel-cpu:
opencl-intel-cpu depends on opencl-base (>= 1.2-4.4.0.117); however:
Package opencl-base is not configured yet.
dpkg: error processing opencl-intel-cpu (--install):
dependency problems - leaving unconfigured
dpkg: dependency problems prevent configuration of opencl-devel:
opencl-devel depends on opencl-base (>= 1.2-4.4.0.117); however:
Package opencl-base is not configured yet.
dpkg: error processing opencl-devel (--install):
dependency problems - leaving unconfigured
dpkg: dependency problems prevent configuration of opencl-intel-devel:
opencl-intel-devel depends on opencl-base (>= 1.2-4.4.0.117); however:
Package opencl-base is not configured yet.
opencl-intel-devel depends on opencl-intel-cpu (>= 1.2-4.4.0.117); however:
Package opencl-intel-cpu is not configured yet.
dpkg: error processing opencl-intel-devel (--install):
dependency problems - leaving unconfigured
dpkg: dependency problems prevent configuration of opencl-intel-devel-android:
opencl-intel-devel-android depends on opencl-base (>= 1.2-4.4.0.117); however:
Package opencl-base is not configured yet.
opencl-intel-devel-android depends on opencl-intel-cpu (>= 1.2-4.4.0.117); however:
Package opencl-intel-cpu is not configured yet.
dpkg: error processing opencl-intel-devel-android (--install):
dependency problems - leaving unconfigured
Errors were encountered while processing:
opencl-base
opencl-intel-cpu
opencl-devel
opencl-intel-devel
opencl-intel-devel-android
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
I had a chance over the weekend to revisit my issue and as it turns out resolve it myself. After having a closer look at the dpkg output, I noticed that one of those lines was complaining about the post install script not being able to find /usr/sbin/update-alternatives, which on my system is located at /usr/bin/update-alternatives and I had no symbolic link in /usr/sbin to it. Simply adding the appropriate symbolic link in /usr/sbin fixed my issue and all seems to be running fine.
However, I don't believe this is a fix to John I's issue - as I didn't see any dpkg output indicating an issue with finding update-alternatives.
Regards,
Brandon
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
I have the exact same problem as John. The same error... At this time, I cannot afford to do a clean system install also.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
This appears to be a bug in the .deb installation scripts. Specifically, if I look into the extracted file /var/lib/dpkg/info/opencl-base.postinst, I see this line:
update-alternatives \
--install "/usr/lib/x86_64-linux-gnu/libOpenCL.so" opencl-libOpenCL.so "/opt/intel/opencl-1.2-4.4.0.117/lib64/libOpenCL.so" -2147489036 \
--slave "/usr/lib/x86_64-linux-gnu/libOpenCL.so.1" opencl-libOpenCL.so.1 "/opt/intel/opencl-1.2-4.4.0.117/lib64/libOpenCL.so.1" \
--slave "/usr/lib/x86_64-linux-gnu/libOpenCL.so.1.2" opencl-libOpenCL.so.1.2 "/opt/intel/opencl-1.2-4.4.0.117/lib64/libOpenCL.so.1.2"
Just as the error message says, that priority (-2147489036) is out of range. Changing it to -1147489036 seems to avoid the error (though I don't know how to make that change int he .deb file in order to complete the installation :( )
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Hello Intel staff and fellow users,
I wish to express my feedback regarding Ubuntu packages for OpenCL SDK 2014, which we are using targeting Xeon Phi.
Long story short, they are BROKEN. Seems they were just ported using "alien" from RPM packages, but there are couple of caveats:
- On Ubuntu path for update-alternatives is /usr/bin/update-alternatives while your DEB postinst and postrm scripts refer to /usr/sbin/update-alternatives which is Fedora/RedHat specific, I presume you may just refer w/o full path as /usr/bin and /usr/sbin will be in PATH for these scripts anyway, this will make scripts portable.
- All calls to update-alternatives use priority of -2147489036 while minimum allowed for Ubuntu is INT_MIN = -2147483648. Frankly I dunno where -2147489036 came from :>
- Ubuntu uses Dash for non-interactive scripts which does not support several "bashisms" (https://wiki.ubuntu.com/DashAsBinSh#A.5B.5B) used in your DEB scripts, i.e.:
- opencl-1.2-base-4.4.0.117-1.x86_64.deb/DEBIAN/postinst
[[ -e etc/OpenCL/ ]] & chmod -R 755 /etc/OpenCL
should become:[ -e etc/OpenCL/ ] && chmod -R 755 /etc/OpenCL
Please note single & which is also obvious error in script. - opencl-1.2-intel-cpu-4.4.0.117-1.x86_64.deb/DEBIAN/postinst
if [[ "/opt/intel/opencl-1.2-4.4.0.117" != "/opt/intel/opencl-1.2-4.4.0.117" ]]; then
This is "bashism" and it is always FALSE! This if clause should be completely removed as it doesn't make sense.
- opencl-1.2-base-4.4.0.117-1.x86_64.deb/DEBIAN/postinst
I would appreciate if you fix these bugs. If there is any issue tracker I would be much appreciated too.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Dear Adam,
did you manage to implement these fixes on your own Ubuntu-distro to get OpenCL working? I'm currently experiencing problems similar to the ones described in this thread. I have found several guides regarding fixes, but these all apply to the previous OpenCL-package which isn't up for download anymore.
Kind regards,
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
I have fixed some bugs and re-packaged and uploaded these debs on my [blog](http://xfanzone.me/fixing-opencl-deb.html).
Now it is working.

- Subscribe to RSS Feed
- Mark Topic as New
- Mark Topic as Read
- Float this Topic for Current User
- Bookmark
- Subscribe
- Printer Friendly Page