Home » How to install CAL++ in Kali Linux?

How to install CAL++ in Kali Linux?

by blackMOREOps
81 comments

How to install CAL++ in Kali Linux - blackMORE Ops

This guide (How to install CAL++ in Kali Linux) is part of a series that guides readers on How to install FGLRX, AMD APP SDK, CAL++ and Pyrit in Kali Linux. The idea is to install correct drivers in Kali Linux for your GPU and use CPU+GPU combination with Pyrit to make raw data crunching faster. An example would be to utilize this combined processing power to crunch though WPA/WPA2 capture file to find Wifi password.

Readers, please follow this series in the following order:

  1. Install AMD ATI Driver (fglrx) in Kali Linux 1.x
  2. How to install AMD APP SDK in Kali Linux?
  3. How to install CAL++ in Kali Linux?
  4. How to install Pyrit in Kali Linux?

Credits:

A big thanks goes to hexed6 from Kali Forums for his original post.

Thanks to for his project in Sourceforge.

Check FGLRX Installation

First check if fglrx module is installed:

lsmod | grep fglrx

You should get a response similar to:

fglrx 2635205 82
button 12945 1 fglrx

If not installed follow this guide to install it.

Install AMD ATI Driver (fglrx) in Kali Linux 1.x

Check AMD APP SDK Installation

Check if AMD APP SDK is installed. If not installed follow this guide to install it.

How to install AMD APP SDK in Kali Linux?

Installing CAL++

CAL++ is a simple library to allow writing ATI CAL kernels directly in C++. The syntax is very similar to OpenCL. Also C++ wrapper for CAL is included.

This project was registered on SourceForge.net on Feb 19, 2010.

Install prerequisites:

apt-get install cmake libboost-all-dev

Download CAL++

Download calpp 0.90 from: SourceForge CAL++ Website

Install CAL++

tar -xvf calpp-0.90.tar.gz
cd calpp-0.90/

Edit CMakeLists.txt:

Find the lines starting with FIND_LIBRARY and FIND_PATH and replace them with this:

FIND_LIBRARY( LIB_ATICALCL aticalcl PATHS "$ENV{ATISTREAMSDKROOT}" )
FIND_LIBRARY( LIB_ATICALRT aticalrt PATHS "$ENV{ATISTREAMSDKROOT}" )
FIND_PATH( LIB_ATICAL_INCLUDE NAMES cal.h calcl.h PATHS "$ENV{ATISTREAMSDKROOT}/include/CAL" )

Save and quit,

Make and Install CAL++

Issue the following commands:

cmake .
make
make install

You may also like

81 comments

Prokash Sarkar December 9, 2013 - 10:46 am

I’ve successfully installed AMD APP SDK by following your previous tutorial, now I’m trying to install CAL++ but having some errors while using the cmake command!

CMake Error: The following variables are used in this project, but they are set to NOTFOUND.
Please set them or make sure they are set and tested correctly in the CMake files:
LIB_ATICAL_INCLUDE
used as include directory in directory /root/Desktop/calpp-0.90/examples
used as include directory in directory /root/Desktop/calpp-0.90/examples
used as include directory in directory /root/Desktop/calpp-0.90/examples
used as include directory in directory /root/Desktop/calpp-0.90/examples
used as include directory in directory /root/Desktop/calpp-0.90/examples
used as include directory in directory /root/Desktop/calpp-0.90/examples
used as include directory in directory /root/Desktop/calpp-0.90/examples
used as include directory in directory /root/Desktop/calpp-0.90/examples
used as include directory in directory /root/Desktop/calpp-0.90/examples
used as include directory in directory /root/Desktop/calpp-0.90/regression
used as include directory in directory /root/Desktop/calpp-0.90/regression
– Configuring incomplete, errors occurred!

I’ve also added these paths here /root/.bashrc

export AMDAPPSDKROOT=/opt/AMDAPP
export AMDAPPSDKSAMPLESROOT=/opt/AMDAPP/
export LD_LIBRARY_PATH=${AMDAPPSDKROOT}lib/x86_64:${LD_LIBRARY_PATH}
export ATISTREAMSDKROOT=$AMDAPPSDKROOT
Reply
admin December 9, 2013 - 9:05 pm

Hi Prokash, thanks for your query. You need to reinstall Pyrit. (Pyrit got a new version).

Follow these 3 posts..

1. http://www.blackmoreops.com/2013/11/22/install-am…
2. http://www.blackmoreops.com/2013/11/22/install-ca…
3. http://www.blackmoreops.com/2013/11/22/install-py…
Google seems to be dumbfounded pretty much nothing. Only related post is 2 years old:

http://www.backtrack-linux.org/forums/showthread….

Let me know the updates and how you managed to fix it. Thanks.
Reply
Prokash December 10, 2013 - 5:51 am

Finally found the solution.We are including the cal.h and calcl.h from /opt/AMDAPP/include/CAL directory in the CMakeLists.txt file

FIND_PATH( LIB_ATICAL_INCLUDE NAMES cal.h calcl.h PATHS "$ENV{ATISTREAMSDKROOT}/include/CAL" )

But by default AMD APP SDK v2.8 or maybe v2.7 (I’ve tested in v2.8 only) doesn’t includes the CAL folder and its necessary files inside the AMDAPP directory! So I downloaded the necessary files for CAL++ from https://github.com/clockfort/amd-app-sdk-fixes and pasted it in /opt/AMDAPP/include directory then tried again! Now everything is working properly! Thanks for your previous posts which helped me to figure out rest of the things! :)

Reply
admin December 10, 2013 - 11:13 am

Good to know everything worked out. Also thanks for taking your time to post the solution here. Like I said, Google didn't find too many results on that specific problem, so this post might help someone along the line. I'd be interested to see how your Pyrit Benchmark.

Reply
twoup July 5, 2014 - 7:18 pm

For anyone using the latest AMDSDK (2.9), the include path has changed again.

FIND_PATH( LIB_ATICAL_INCLUDE NAMES cal.h calcl.h PATHS “$ENV{ATISTREAMSDKROOT}/include/CAL” )

becomes

FIND_PATH( LIB_ATICAL_INCLUDE NAMES cal.h calcl.h PATHS “$ENV{ATISTREAMSDKROOT}/include/CL” )

You still need to download the cal.h and calcl.h files as noted by Prokash.

Reply
twoup July 5, 2014 - 8:24 pm

Ignore my post above. Use AMDAPPSDK 2.7! Then read the comments threads by searching for the errors you encounter as you go along. It does work!

Computed 125521.30 PMKs/s total.
#1: ‘CAL++ Device #1 ‘AMD GPU DEVICE”: 128082.0 PMKs/s (RTT 1.0)
#2: ‘CPU-Core (SSE2/AES)’: 650.1 PMKs/s (RTT 3.0)
#3: ‘CPU-Core (SSE2/AES)’: 693.8 PMKs/s (RTT 2.9)
#4: ‘CPU-Core (SSE2/AES)’: 673.1 PMKs/s (RTT 3.0)
#5: ‘CPU-Core (SSE2/AES)’: 680.0 PMKs/s (RTT 3.0)
#6: ‘CPU-Core (SSE2/AES)’: 660.0 PMKs/s (RTT 2.9)
#7: ‘CPU-Core (SSE2/AES)’: 670.2 PMKs/s (RTT 3.1)
#8: ‘CPU-Core (SSE2/AES)’: 684.0 PMKs/s (RTT 3.0)

Now to test some hashes! Thanks, Blackmoreops!

Reply
Prokash December 10, 2013 - 11:58 am

I’m using ATI Radeon HD-7770. Here is my Pyrit Benchmark,

Computed 39329.78 PMKs/s total.
#1: 'CAL++ Device #1 'AMD GPU DEVICE'': 39300.7 PMKs/s (RTT 1.0)
#2: 'CPU-Core (SSE2/AES)': 498.0 PMKs/s (RTT 3.0)
#3: 'CPU-Core (SSE2/AES)': 542.8 PMKs/s (RTT 3.1)
#4: 'CPU-Core (SSE2/AES)': 537.7 PMKs/s (RTT 2.9)

I must say without your instructions it was impossible to figure out all these things :) Please make a new post if there is any update for latest display driver!
Thanks!

Reply
admin December 19, 2013 - 4:46 am

My laptop, Radeon 7500 HD Series

root@kali:~# pyrit benchmark
Pyrit 0.4.1-dev (svn r308) (C) 2008-2011 Lukas Lueg http://pyrit.googlecode.com
This code is distributed under the GNU General Public License v3+
Calibrating…
Running benchmark (14940.2 PMKs/s)… –
Computed 14940.23 PMKs/s total.
#1: 'CAL++ Device #1 'AMD GPU DEVICE'': 14685.7 PMKs/s (RTT 1.6)
#2: 'CPU-Core (SSE2/AES)': 297.0 PMKs/s (RTT 3.1)
#3: 'CPU-Core (SSE2/AES)': 317.9 PMKs/s (RTT 3.0)
#4: 'CPU-Core (SSE2/AES)': 298.6 PMKs/s (RTT 3.1)
Reply
twoup July 5, 2014 - 7:28 pm

Please ignore above comment by me. It’s a little wrong. Seems SDK 2.9 is missing other required files. Search for a post further down, about “oalescingtest”. It recommends using SDK2.7.

Reply
Gilly December 20, 2013 - 11:52 pm

Is there a way to verify Cal++ installed correctly before proceeding?

Reply
admin December 21, 2013 - 1:25 am

Not that except it creates a cal folder in /usr/local/include/cal and dumps .hpp files in there. I was wondering the same thing when I installed CAL++, didn’t see anything in http://sourceforge.net/projects/calpp/ project page.

Reply
Kaotic December 27, 2013 - 10:53 am

I'm getting same errors as Prokash Sarkar when building CAL++. Cmake will not work.

Reply
admin December 27, 2013 - 9:01 pm

Did you try similar solution as Prokash? Here’s where I found cal.hpp file in my installation.

root@kali:~# find / -name cal.hpp
/usr/local/include/cal/cal.hpp
/opt/AMDAPP/include/cal/cal.hpp
/opt/AMDAPP/include/CAL/cal.hpp
/opt/AMDAPP/include/cal.hpp
/opt/AMDAPP/include/CL/cal.hpp
/root/calpp-0.90/include/cal/cal.hpp

Files can be downloaded from here: https://github.com/clockfort/amd-app-sdk-fixes
Hope this helps.
ps. I used v2.7 AMDAPP SDK when I tested mine.

Reply
youssef.senpai February 6, 2014 - 1:10 pm

hey there first of all thans sooo much for the work youve done blackmore ur awsome (y) and Porkash thanks very much im having the same probleme here and i just copied the files from cal and put it in "opt/amdapp/include" and yes the command " cmake ." passed perfectly but i get errors when i try to do "make" help me please .

and sorry for my english im from morocco :)

Reply
admin February 6, 2014 - 7:12 pm

Hi Youssef,
Thanks for your kind words. Appreciate it. Yes, Prokash been really thorough when he followed and implemented my guide.
Can you please let us know about the errors you’re getting? Without knowing the error, it’s hard to troubleshoot. Also, show us your cat /proc/version output. This guide was written when we had Kernel 3.7, I am still using that in my system as Kernel 3.12-6 seems problematic for AMD Drivers. Thanks.

Reply
youssefsenpai February 6, 2014 - 10:20 pm

first sorry because i mssed in spelling Prokash's name ans seconde i didnt see its only works on kernel 3.7 because i was using kali 1.6 64bit and it kept overheating then i got mad and removed it so if i may ask what can i do now ? shoud i install the Kali 1.0 and do the tutorials then upgrade the kernel and distro after that ? but i saw that before doing the installation of amd driver u need to do an update and upgrade !! isnt that gonna miss everything ? i am again sorry for the bother and thanks for ur time admin .

Reply
admin February 6, 2014 - 10:58 pm

You could try removing new Kernel (and thereby booting back to 3.7). However, this gets tricky as as Kali removed 3.7 kernel headers from Repo. So, don't re-install yet as that won't do any good without the correct headers.

Reply
M February 13, 2014 - 1:22 am

Thanks very much for you time putting this walk through together fellas. This is the only phase i had any issues with was this one.

In my case, it was needed to run:

sudo apt-get update

before the initial command

apt-get install cmake libboost-all-dev

Verified working on HP Elitebook 8460P with ATI HD6400M.

Reply
blackMORE Ops February 13, 2014 - 2:10 am

Hi M, thanks for your comment and I'm glad it worked for you as well. Don't forget to follow us on Facebook/Twitter and share this post with friends !!! ;)

Reply
Bob March 7, 2014 - 6:59 am

Hi Admin, I like Prokash Sarkar, have been following your very good tutorial's, and up to installing CAL++ I was not having any real problems. But now I’m trying to install CAL++ but having the some errors as Prokash while using the cmake command! I am not new to Linux but I am differently not any sort of expert, as i am self taught using the internet. My issue is that I don't understand how to apply Prokash's fix. Can you or someone else please give a more detailed explanation, or if you know if there is such a detailed explanation posted somewhere on the net.

Reply
Bob March 7, 2014 - 2:42 pm

Hi Admin, Since I was having trouble-getting CAL++ to install correctly. And the trouble seems to be with versions of AMD-APP-SDK newer then 2.7 (I was trying to install V2.9) because you did not seem to have a problem with it. I got a copy of v2.7 from the AMD download page and put in a fresh install of kali linux and used that 2.7 version with no problems. Should I try to update to the new 2.9 version? Or should I leave well enough alone and not try to break it now that I have it. LOL Thanks again for your great postings, I find they are being a great help to me.

My benchmark with my cheep Toshiba laptop using an AMD E-300 APU with Radeon HD 6310 chip.

root@AA:~# pyrit benchmark

Pyrit 0.4.1-dev (svn r308) (C) 2008-2011 Lukas Lueg http://pyrit.googlecode.com
This code is distributed under the GNU General Public License v3+

Computed 1971.79 PMKs/s total.

#1: 'CAL++ Device #1 'AMD WRESTLER'': 2039.9 PMKs/s (RTT 2.7)

#2: 'CPU-Core (SSE2)': 120.2 PMKs/s (RTT 3.0)

Reply
blackMORE Ops March 7, 2014 - 8:55 pm

Hi Bob,

Installing v2.9 was already tried and succeeded. See youssef.senpai's comment http://www.blackmoreops.com/2013/11/22/install-py… from this other post How to install Pyrit in Kali Linux?

I'm not too sure about your benchmark, it's too low. It might because of and old Graphics card, but you could try to reinstall Pyrit and Cpyrit manually. I found at least one of my installation where cpyrit didn't pick up my cards properly. Note that cpyrit and pyrit was last developed on 2011…. I haven't seen any new developments since then. By next year, GPU processing/cracking will be too old, people are already moving towards specialized ASIC hardware's.

However, Good Luck and congratulations on your successful installation of CAL++.

Reply
Sketch May 28, 2014 - 7:45 pm

I haven’t been able to find much in the way of asic’s for password cracking. Have you seen any good info?

Reply
blackMORE Ops May 28, 2014 - 8:43 pm

Nothing at all. . Which is suspicious. .

Keron May 2, 2014 - 2:00 am

Bob, l got the same pyrit benchmark

Did reinstalling pyrit and cpyrit work to pick up more video cards?

Reply
amo March 11, 2014 - 10:27 pm

I'm getting an error with make:

http://pastebin.com/8FFSbVqD

Please help me out…

Linux version 3.12-kali1-amd64 ([email protected]) (gcc version 4.7.2 (Debian 4.7.2-5) ) #1 SMP Debian 3.12.6-2kali1 (2014-01-06)

This is my second fresh install.

Reply
blackMORE Ops March 11, 2014 - 11:23 pm

Hi amo,

Did you install AMD APP SDK v2.9 by any chance? If you did, remove the folders for AMDAPP SDK v2.9 and install 2.7 and retry CAL++.

The above instructions are for 2.7 SDK that worked for me (I did a fresh install just last week).

Only error I received was resolved by the work around mentioned below … (see Prokash's comments).

Reply
Zulu March 13, 2014 - 1:50 am

Im getting the same error. I've double checked to make sure the SDK was 2.7, but it still gives me the error.

Reply
blackMORE Ops March 13, 2014 - 2:04 am

This seems like a bug. Things to check:

GCC version,

Ensuring you've installed latest cmake and libboost-all-dev package

FGLRX is working and installed.

AMDAPPSDK v2.7 (the one I've tried) is installed.

Apart from that, ensure you're only using Kali Linux repo and everything is up to date.

There's only 2 hits in Google for this type of errors with a possible solution:

http://stackoverflow.com/questions/5395578/cmake-http://stackoverflow.com/questions/1796353/cmake-

Good luck.

Reply
Zulu March 13, 2014 - 7:00 pm

gcc (Debian 4.7.3-11) 4.7.3

cmake and libboost-all-dev are all up to date.

i've installed AMDAPPSDK 2.7 (anyway to formally check if its installed correctly?)

and it still doesnt work (the make command)

Zulu March 13, 2014 - 7:49 pm

would it make sense just to reinstall kali linux with 1.05? or would that not solve the issue?

blackMORE Ops March 13, 2014 - 8:29 pm

Hi Zulu,
Yes, of course you could install Kali 1.0.5, but note that this guide worked for me and everyone else you see in the comment section since Kali v1.0.0. However, my personal opinion would be for you to ask the question to the wider community of Kali Linux forum. Someone else other than we 2 might've had better luck and asking in community always helps as in that way you leave a trace of the issue along with a solution for the next person to find. Hope this all makes sense. Thanks and good luck.

Martin March 12, 2014 - 11:05 am

Hello,
can you help me with this problem:

root@kali:~# cmake .
-- The C compiler identification is GNU 4.7.2 
-- The CXX compiler identification is GNU 4.7.2
-- Check for working C compiler: /usr/bin/gcc
-- Check for working C compiler: /usr/bin/gcc -- works
-- Detecting C compiler ABI info
-- Detecting C compiler ABI info - done
-- Check for working CXX compiler: /usr/bin/c++
-- Check for working CXX compiler: /usr/bin/c++ -- works
-- Detecting CXX compiler ABI info
-- Detecting CXX compiler ABI info - done
-- Boost version: 1.49.0
-- Found the following Boost libraries:
--   date_time
-- ===========================================================
-- ATI CAL include directory LIB_ATICAL_INCLUDE-NOTFOUND
-- ATI CAL cl library directory /usr/lib/x86_64-linux-gnu
-- ATI CAL rt library directory /usr/lib/x86_64-linux-gnu
-- Boost version 1_49
-- ===========================================================
CMake Error at CMakeLists.txt:38 (ADD_SUBDIRECTORY):
  add_subdirectory given source "examples" which is not an existing directory.

CMake Error at CMakeLists.txt:39 (ADD_SUBDIRECTORY): 
  add_subdirectory given source "regression" which is not an existing directory.
-- Configuring incomplete, errors occurred!

Thank you!!!

Reply
blackMORE Ops March 12, 2014 - 11:24 am

Check line 38 and 39 in cmakelists file. Solution also in comments section.

Reply
Martin March 12, 2014 - 11:31 am

Thanks. Will try and report back!

Reply
Martin March 16, 2014 - 6:59 pm

ADD_SUBDIRECTORY(examples)

ADD_SUBDIRECTORY(regression)

this is what I have in line 38 and 39. where do I go wrong?

Reply
Martin March 16, 2014 - 10:33 pm

Just solved the problem by deleting it and cmake . worked and installed everything. next step – Pyrit. so far doing everything correctly, pyrit changed to 0.4.1 but still can't see the video card…

Reply
lemniscate March 26, 2014 - 6:33 pm

got this error when issuing make command. newbie on kali linux thanks!

root@kali:~/calpp-0.90# make
Scanning dependencies of target coalescingtest
[ 6%] Building CXX object examples/CMakeFiles/coalescingtest.dir/coalescingtest.cpp.o
/root/calpp-0.90/examples/coalescingtest.cpp: In function ‘void show_result(int, int)’:
/root/calpp-0.90/examples/coalescingtest.cpp:224:5: error: reference to ‘int64_t’ is ambiguous
In file included from /usr/include/stdlib.h:314:0,
from /usr/include/c++/4.7/cstdlib:66,
from /usr/include/boost/config/platform/linux.hpp:15,
from /usr/include/boost/config.hpp:53,
from /usr/include/boost/detail/workaround.hpp:41,
from /usr/include/boost/format.hpp:19,
from /root/calpp-0.90/examples/coalescingtest.cpp:25:
/usr/include/x86_64-linux-gnu/sys/types.h:197:1: error: candidates are: typedef long int int64_t
In file included from /usr/include/boost/date_time/compiler_config.hpp:54:0,
from /usr/include/boost/date_time/posix_time/posix_time.hpp:14,
from /root/calpp-0.90/examples/coalescingtest.cpp:26:
/usr/include/boost/cstdint.hpp:308:50: error: typedef boost::long_long_type boost::int64_t
/root/calpp-0.90/examples/coalescingtest.cpp:224:13: error: expected ‘;’ before ‘bytes’
/root/calpp-0.90/examples/coalescingtest.cpp:225:29: error: ‘bytes’ was not declared in this scope
make[2]: *** [examples/CMakeFiles/coalescingtest.dir/coalescingtest.cpp.o] Error 1
make[1]: *** [examples/CMakeFiles/coalescingtest.dir/all] Error 2
make: *** [all] Error 2

Reply
blackMORE Ops March 26, 2014 - 6:36 pm

Looks like you installed amdappsdk 2.9.. use 2.7 and retry.

Reply
lemniscate March 26, 2014 - 11:29 pm

downloaded (AMD-APP-SDK-v2.7-lnx64) still no luck. im using (Linux_AMD_Catalyst_14.3_Beta_V1.0_B22_March12_2014.zip) ati drivers

Reply
lemniscate March 26, 2014 - 11:32 pm

btw sorry for the double post. i always got an error during my first post and i dont know why :D really bad luck today

Reply
blackMORE Ops March 27, 2014 - 12:00 am

Site is slow cause too many people online now. You need to install fglrx driver 1st, there’s a guide on that on my site. Find the most recent one. Then install sdk v2.7. Then install pyrit+cpyrit and finally install cal++. Take a break. . Then start over. Good luck.

Reply
lemniscate March 29, 2014 - 8:06 am

hello! thank you very much. reinstalled everything from scratch and now its working!
here’s my benchmark

Computed 81114.56 PMKs/s total.
#1: ‘CAL++ Device #1 ‘AMD GPU DEVICE”: 82963.1 PMKs/s (RTT 1.1)
#2: ‘CPU-Core (SSE2/AES)’: 1105.8 PMKs/s (RTT 3.0)
#3: ‘CPU-Core (SSE2/AES)’: 1113.8 PMKs/s (RTT 2.9)
#4: ‘CPU-Core (SSE2/AES)’: 1102.0 PMKs/s (RTT 2.9)

THANKS!!

blackMORE Ops March 30, 2014 - 2:30 pm

wow man, that’s a great benchmark. Congratulations.

yamicaitsith March 27, 2014 - 3:51 pm

root@kali:/home/user1/calpp-0.90# make install
[ 6%] Building CXX object examples/CMakeFiles/coalescingtest.dir/coalescingtest.cpp.o
/home/user1/calpp-0.90/examples/coalescingtest.cpp: In function ‘void show_result(int, int)’:
/home/user1/calpp-0.90/examples/coalescingtest.cpp:224:5: error: reference to ‘int64_t’ is ambiguous
In file included from /usr/include/stdlib.h:314:0,
from /usr/include/c++/4.7/cstdlib:66,
from /usr/include/boost/config/platform/linux.hpp:15,
from /usr/include/boost/config.hpp:53,
from /usr/include/boost/detail/workaround.hpp:41,
from /usr/include/boost/format.hpp:19,
from /home/user1/calpp-0.90/examples/coalescingtest.cpp:25:
/usr/include/x86_64-linux-gnu/sys/types.h:197:1: error: candidates are: typedef long int int64_t
In file included from /usr/include/boost/date_time/compiler_config.hpp:54:0,
from /usr/include/boost/date_time/posix_time/posix_time.hpp:14,
from /home/user1/calpp-0.90/examples/coalescingtest.cpp:26:
/usr/include/boost/cstdint.hpp:308:50: error: typedef boost::long_long_type boost::int64_t
/home/user1/calpp-0.90/examples/coalescingtest.cpp:224:13: error: expected ‘;’ before ‘bytes’
/home/user1/calpp-0.90/examples/coalescingtest.cpp:225:29: error: ‘bytes’ was not declared in this scope
make[2]: *** [examples/CMakeFiles/coalescingtest.dir/coalescingtest.cpp.o] Error 1
make[1]: *** [examples/CMakeFiles/coalescingtest.dir/all] Error 2
make: *** [all] Error 2

i’m having this same issue,any suggestions on how to fix this?
pyrit benchmark is working, but this issue worries me…

Reply
blackMORE Ops March 27, 2014 - 4:26 pm

Mate, just read the comments section. It’s already been covered multiple times. You need to install
fglrx driver 1st, there’s a guide on that on my site. Find the most recent one.
Then install sdk v2.7.
Then install pyrit+cpyrit and
finally install cal++
Good luck.

Reply
Pedro April 15, 2014 - 11:54 pm

Hello There!!
I need some help with calpp…
the last step :

./setup.py build install — ends wit errors…

–> cc1plus: warning: command line option ‘-Wstrict-prototypes’ is valid for C/ObjC but not for C++ [enabled by default]
_cpyrit_calpp.cpp:38:23: fatal error: cal/cal.hpp: No such file or directory
compilation terminated.
error: command ‘gcc’ failed with exit status 1

The Error will be that the “cal/cal.hpp” isn’t found where it should be, so where to copy that file/carpet into??

Thanks for your reply, I’m trying it over one week…

Pedro

Reply
blackMORE Ops April 15, 2014 - 11:56 pm

Hi Pedro,
The answer was given by Prokash back in December.

Finally found the solution.We are including the cal.h and calcl.h from /opt/AMDAPP/include/CAL directory in the CMakeLists.txt file

FIND_PATH( LIB_ATICAL_INCLUDE NAMES cal.h calcl.h PATHS "$ENV{ATISTREAMSDKROOT}/include/CAL" )
But by default AMD APP SDK v2.8 or maybe v2.7 (I’ve tested in v2.8 only) doesn’t includes the CAL folder and its necessary files inside the AMDAPP directory! So I downloaded the necessary files for CAL++ from https://github.com/clockfort/amd-app-sdk-fixes and pasted it in /opt/AMDAPP/include directory then tried again! Now everything is working properly! Thanks for your previous posts which helped me to figure out rest of the things!
Reply
Keron April 29, 2014 - 4:42 am

How do l get to the CAL++ Directory? to use cmake . make make install

Reply
diosthenes May 7, 2014 - 9:07 am

Hi! Great guide/s! I successfully got: fglrx driver ,then sdk v2.7, and pyrit+cpyrit installed (with a good benchmark).

I have tried doing a reinstall of both the fglrx driver and sdk with reboots in-between. Somehow, I still cannot get Cal++ to install. “Cmake .” runs successfully, but “make” crashes. If anyone has an idea what might be going wrong, I would appreciate it! Been trying for a couple of days, and still stuck.

Cmake .
[code]
— The C compiler identification is GNU 4.7.2
— The CXX compiler identification is GNU 4.7.2
— Check for working C compiler: /usr/bin/gcc
— Check for working C compiler: /usr/bin/gcc — works
— Detecting C compiler ABI info
— Detecting C compiler ABI info – done
— Check for working CXX compiler: /usr/bin/c++
— Check for working CXX compiler: /usr/bin/c++ — works
— Detecting CXX compiler ABI info
— Detecting CXX compiler ABI info – done
— Boost version: 1.49.0
— Found the following Boost libraries:
— date_time
— ===========================================================
— ATI CAL include directory /opt/AMDAPP/include/CAL
— ATI CAL cl library directory /usr/lib/x86_64-linux-gnu
— ATI CAL rt library directory /usr/lib/x86_64-linux-gnu
— Boost version 1_49
— ===========================================================
— Configuring done
— Generating done
— Build files have been written to: /root/Downloads/calpp-0.90
[/code]

Make
[code]
[ 6%] Building CXX object examples/CMakeFiles/coalescingtest.dir/coalescingtest.cpp.o
/root/Downloads/calpp-0.90/examples/coalescingtest.cpp: In function ‘void show_result(int, int)’:
/root/Downloads/calpp-0.90/examples/coalescingtest.cpp:224:5: error: reference to ‘int64_t’ is ambiguous
In file included from /usr/include/stdlib.h:314:0,
from /usr/include/c++/4.7/cstdlib:66,
from /usr/include/boost/config/platform/linux.hpp:15,
from /usr/include/boost/config.hpp:53,
from /usr/include/boost/detail/workaround.hpp:41,
from /usr/include/boost/format.hpp:19,
from /root/Downloads/calpp-0.90/examples/coalescingtest.cpp:25:
/usr/include/x86_64-linux-gnu/sys/types.h:197:1: error: candidates are: typedef long int int64_t
In file included from /usr/include/boost/date_time/compiler_config.hpp:54:0,
from /usr/include/boost/date_time/posix_time/posix_time.hpp:14,
from /root/Downloads/calpp-0.90/examples/coalescingtest.cpp:26:
/usr/include/boost/cstdint.hpp:308:50: error: typedef boost::long_long_type boost::int64_t
/root/Downloads/calpp-0.90/examples/coalescingtest.cpp:224:13: error: expected ‘;’ before ‘bytes’
/root/Downloads/calpp-0.90/examples/coalescingtest.cpp:225:29: error: ‘bytes’ was not declared in this scope
make[2]: *** [examples/CMakeFiles/coalescingtest.dir/coalescingtest.cpp.o] Error 1
make[1]: *** [examples/CMakeFiles/coalescingtest.dir/all] Error 2
make: *** [all] Error 2
[/code]

Reply
blackMORE Ops May 7, 2014 - 9:25 am

Hi diosthenes,

Apparently someone solved it here. https://groups.google.com/forum/#!msg/pyrit/n0FjSi4SNXs/ZPS-i0mve1wJ

When searching for solution, search for these two lines
make[2]: *** [examples/CMakeFiles/coalescingtest.dir/coalescingtest.cpp.o] Error 1
and
make[1]: *** [examples/CMakeFiles/coalescingtest.dir/all] Error 2
(Google been really unhelpful regarding this error, not many people had it and those who had it, never posted a clear solution)
Good Luck.
-BMO

Reply
Gonia May 24, 2014 - 9:44 pm

Scanning dependencies of target coalescingtest
[ 6%] Building CXX object examples/CMakeFiles/coalescingtest.dir/coalescingtest.cpp.o
/root/calpp-0.90/examples/coalescingtest.cpp: In function ‘void show_result(int, int)’:
/root/calpp-0.90/examples/coalescingtest.cpp:224:5: error: reference to ‘int64_t’ is ambiguous
In file included from /usr/include/stdlib.h:314:0,
from /usr/include/c++/4.7/cstdlib:66,
from /usr/include/boost/config/platform/linux.hpp:15,
from /usr/include/boost/config.hpp:53,
from /usr/include/boost/detail/workaround.hpp:41,
from /usr/include/boost/format.hpp:19,
from /root/calpp-0.90/examples/coalescingtest.cpp:25:
/usr/include/x86_64-linux-gnu/sys/types.h:197:1: error: candidates are: typedef long int int64_t
In file included from /usr/include/boost/date_time/compiler_config.hpp:54:0,
from /usr/include/boost/date_time/posix_time/posix_time.hpp:14,
from /root/calpp-0.90/examples/coalescingtest.cpp:26:
/usr/include/boost/cstdint.hpp:308:50: error: typedef boost::long_long_type boost::int64_t
/root/calpp-0.90/examples/coalescingtest.cpp:224:13: error: expected ‘;’ before ‘bytes’
/root/calpp-0.90/examples/coalescingtest.cpp:225:29: error: ‘bytes’ was not declared in this scope
make[2]: *** [examples/CMakeFiles/coalescingtest.dir/coalescingtest.cpp.o] Error 1
make[1]: *** [examples/CMakeFiles/coalescingtest.dir/all] Error 2
make: *** [all] Error 2

Reply
blackMORE Ops May 24, 2014 - 9:54 pm

Read comments above. It’s solved in there.

Reply
Rott May 28, 2014 - 5:48 am

root@kali:/calpp-0.90# cmake .
— Boost version: 1.49.0
— Found the following Boost libraries:
— date_time
— ===========================================================
— ATI CAL include directory LIB_ATICAL_INCLUDE-NOTFOUND
— ATI CAL cl library directory /usr/lib/x86_64-linux-gnu
— ATI CAL rt library directory /usr/lib/x86_64-linux-gnu
— Boost version 1_49
— ===========================================================
CMake Error: The following variables are used in this project, but they are set to NOTFOUND.
Please set them or make sure they are set and tested correctly in the CMake files:
LIB_ATICAL_INCLUDE
used as include directory in directory /calpp-0.90/examples
used as include directory in directory /calpp-0.90/examples
used as include directory in directory /calpp-0.90/examples
used as include directory in directory /calpp-0.90/examples
used as include directory in directory /calpp-0.90/examples
used as include directory in directory /calpp-0.90/examples
used as include directory in directory /calpp-0.90/examples
used as include directory in directory /calpp-0.90/examples
used as include directory in directory /calpp-0.90/examples
used as include directory in directory /calpp-0.90/regression
used as include directory in directory /calpp-0.90/regression

— Configuring incomplete, errors occurred!

HELP !!!!!!!!!!

Reply
woups June 22, 2014 - 7:14 pm

#make
Scanning dependencies of target coalescingtest
[ 6%] Building CXX object examples/CMakeFiles/coalescingtest.dir/coalescingtest.cpp.o
In file included from /root/calpp-0.90/examples/coalescingtest.cpp:27:0:
/root/calpp-0.90/include/cal/cal.hpp:27:19: fatal error: calcl.h: No such file or directory
compilation terminated.
make[2]: *** [examples/CMakeFiles/coalescingtest.dir/coalescingtest.cpp.o] Error 1
make[1]: *** [examples/CMakeFiles/coalescingtest.dir/all] Error 2
make: *** [all] Error 2

Reply
blackMORE Ops June 22, 2014 - 11:31 pm

woups, this is an old issue that came up many many times. Read the comments for solution.

Reply
shahbaz June 28, 2014 - 2:31 am

thanks blackmoreops for posting such amazing tutorials and also thanks to prokash for his solution.

i got the following error when issues make command while installing cal++.

################### ERROR ##########################
root@kali:~/calpp-0.90# make
Scanning dependencies of target coalescingtest
[ 6%] Building CXX object examples/CMakeFiles/coalescingtest.dir/coalescingtest.cpp.o
/root/calpp-0.90/examples/coalescingtest.cpp: In function ‘void show_result(int, int)’:
/root/calpp-0.90/examples/coalescingtest.cpp:224:5: error: reference to ‘int64_t’ is ambiguous
In file included from /usr/include/stdlib.h:314:0,
from /usr/include/c++/4.7/cstdlib:66,
from /usr/include/boost/config/platform/linux.hpp:15,
from /usr/include/boost/config.hpp:53,
from /usr/include/boost/detail/workaround.hpp:41,
from /usr/include/boost/format.hpp:19,
from /root/calpp-0.90/examples/coalescingtest.cpp:25:
/usr/include/x86_64-linux-gnu/sys/types.h:197:1: error: candidates are: typedef long int int64_t
In file included from /usr/include/boost/date_time/compiler_config.hpp:54:0,
from /usr/include/boost/date_time/posix_time/posix_time.hpp:14,
from /root/calpp-0.90/examples/coalescingtest.cpp:26:
/usr/include/boost/cstdint.hpp:308:50: error: typedef boost::long_long_type boost::int64_t
/root/calpp-0.90/examples/coalescingtest.cpp:224:13: error: expected ‘;’ before ‘bytes’
/root/calpp-0.90/examples/coalescingtest.cpp:225:29: error: ‘bytes’ was not declared in this scope
make[2]: *** [examples/CMakeFiles/coalescingtest.dir/coalescingtest.cpp.o] Error 1
make[1]: *** [examples/CMakeFiles/coalescingtest.dir/all] Error 2
make: *** [all] Error 2
##############################################################

REASON OF ERROR :
int64_t is defined at more than one places differently.
in it was defined as typedef long int int64_t;
and in /usr/include/boost/cstdint.hpp it was defined as typedef ::boost::long_long_type int64_t;

this resulted in ambiguos declaration error and prevented make command completing successfully.

SOLUTION:

I solved this by changing following changes in the file “/usr/include/boost/cstdint.hpp”

1. comment the line : typedef ::boost::long_long_type int64_t;
and write typedef long int int64_t;

2. comment the line : typedef ::boost::ulong_long_type uint64_t;
and write typedef long unsigned int uint64_t;

thats all .

hope this helps someone.

Reply
Kracking4fun September 20, 2014 - 9:03 pm

Thank you so much for writing your solution, I was able to do make and make install after editing those few lines in cstdint.hpp.
Tried every other solution but this was IT!

I had no problems the first time i installed CAL++, Pyrit or AMD APP SDK on Kali 1.0.9 install using kali’s repository AMD Radeon drivers. (v 14.10.xxxxx)

But the second time on my other machine I had this problem, the only differencebetween these 2 installs is that the second time I temporary added Debian Unstable repository to sources.list to be able to install AMD ATI driver 14.6b for use with oclHashcat 1.30.

Now Ive got everything up and running and heres a bench from pyrit using 14.10.xxx driver.

Pyrit 0.4.1-dev (svn r308) (C) 2008-2011 Lukas Lueg http://pyrit.googlecode.com
This code is distributed under the GNU General Public License v3+

Running benchmark (114147.9 PMKs/s)… \

Computed 114147.92 PMKs/s total.
#1: ‘CAL++ Device #1 ‘AMD GPU DEVICE”: 118467.8 PMKs/s (RTT 1.0)
#2: ‘CPU-Core (SSE2)’: 607.7 PMKs/s (RTT 3.0)
#3: ‘CPU-Core (SSE2)’: 629.2 PMKs/s (RTT 3.0)
#4: ‘CPU-Core (SSE2)’: 627.7 PMKs/s (RTT 3.0)

Im hoping i will see a performance increase with the ATI’s 14.6b driver

Reply
1 2

Leave your solution or comment to help others. Comment don't need registration or real email, so feel free.

This site uses Akismet to reduce spam. Learn how your comment data is processed.

About Us

blackMORE Ops - touch-icon-72x72

blackMORE Ops” does not promote, encourages and excite hackers, its purpose is to make people aware that what is going around. Know Hacking but No Hacking!

Feature Posts

Newsletter