[SOLVED] aircrack-ng installation error: undefined reference to 'cpuinfo' please help...
Linux - SoftwareThis forum is for Software issues.
Having a problem installing a new program? Want to know which application is best for the job? Post your question in this forum.
Notices
Welcome to LinuxQuestions.org, a friendly and active Linux Community.
You are currently viewing LQ as a guest. By joining our community you will have the ability to post topics, receive our newsletter, use the advanced search, subscribe to threads and access many other special features. Registration is quick, simple and absolutely free. Join our community today!
Note that registered members see fewer ads, and ContentLink is completely disabled once you log in.
If you have any problems with the registration process or your account login, please contact us. If you need to reset your password, click here.
Having a problem logging in? Please visit this page to clear all LQ-related cookies.
Get a virtual cloud desktop with the Linux distro that you want in less than five minutes with Shells! With over 10 pre-installed distros to choose from, the worry-free installation life is here! Whether you are a digital nomad or just looking for flexibility, Shells can put your Linux machine on the device that you want to use.
Exclusive for LQ members, get up to 45% off per month. Click here for more info.
aircrack-ng installation error: undefined reference to 'cpuinfo' please help...
I am using Fedora 27, I want to compile aircrack-ng-1.2-rc4 from the source since the yum and dnf installation has some bugs specially on airodump and airbase.
below are the output and errors when I enter make command...
[root@fedora aircrack-ng-1.2-rc4]# make
make -C src all
make[1]: Entering directory '/home/aircrack-ng-1.2-rc4/src'
gcc -g -w -Wall -O3 -pthread -D_FILE_OFFSET_BITS=64 -D_REVISION=0 -DCONFIG_LIBNL30 -DCONFIG_LIBNL -I/usr/include/libnl3 -fstack-protector-strong -Wno-unused-but-set-variable -Wno-array-bounds -Iinclude crypto.o common.o uniqueiv.o aircrack-ptw-lib.o memory.o simd-intrinsics.o aircrack-ng-core.o wpapsk-simd.o sha1-sse2.S -o aircrack-ng-simd -lpthread -lssl -lcrypto -lstdc++ liblinecount.a
aircrack-ng-core.o: In function `crack_wpa_thread':
/home/toshi82/aircrack-ng-1.2-rc4/src/aircrack-ng.c:4038: undefined reference to `cpuid_simdsize'
/home/toshi82/aircrack-ng-1.2-rc4/src/aircrack-ng.c:4038: undefined reference to `cpuinfo'
/home/toshi82/aircrack-ng-1.2-rc4/src/aircrack-ng.c:4088: undefined reference to `cpuinfo'
/home/toshi82/aircrack-ng-1.2-rc4/src/aircrack-ng.c:4088: undefined reference to `cpuinfo'
/home/toshi82/aircrack-ng-1.2-rc4/src/aircrack-ng.c:4128: undefined reference to `cpuinfo'
/home/toshi82/aircrack-ng-1.2-rc4/src/aircrack-ng.c:4131: undefined reference to `cpuinfo'
aircrack-ng-core.o:/home/toshi82/aircrack-ng-1.2-rc4/src/aircrack-ng.c:4221: more undefined references to `cpuinfo' follow
aircrack-ng-core.o: In function `main':
/home/toshi82/aircrack-ng-1.2-rc4/src/aircrack-ng.c:5217: undefined reference to `cpuid_getinfo'
wpapsk-simd.o: In function `init_wpapsk':
/home/toshi82/aircrack-ng-1.2-rc4/src/wpapsk.c:518: undefined reference to `cpuinfo'
wpapsk-simd.o: In function `wpapsk_sse':
/home/toshi82/aircrack-ng-1.2-rc4/src/wpapsk.c:218: undefined reference to `cpuinfo'
collect2: error: ld returned 1 exit status
make[1]: *** [Makefile:186: aircrack-ng-simd] Error 1
make[1]: Leaving directory '/home/aircrack-ng-1.2-rc4/src'
make: *** [Makefile:25: all] Error 2
[root@fedora aircrack-ng-1.2-rc4]# make
make -C src all
make[1]: Entering directory '/home/aircrack-ng-1.2-rc4/src'
gcc -g -w -Wall -O3 -pthread -D_FILE_OFFSET_BITS=64 -D_REVISION=0 -DCONFIG_LIBNL30 -DCONFIG_LIBNL -I/usr/include/libnl3 -fstack-protector-strong -Wno-unused-but-set-variable -Wno-array-bounds -Iinclude crypto.o common.o uniqueiv.o aircrack-ptw-lib.o memory.o simd-intrinsics.o aircrack-ng-core.o wpapsk-simd.o sha1-sse2.S -o aircrack-ng-simd -lpthread -lssl -lcrypto -lstdc++ liblinecount.a
aircrack-ng-core.o: In function `crack_wpa_thread':
/home/toshi82/aircrack-ng-1.2-rc4/src/aircrack-ng.c:4038: undefined reference to `cpuid_simdsize'
/home/toshi82/aircrack-ng-1.2-rc4/src/aircrack-ng.c:4038: undefined reference to `cpuinfo'
/home/toshi82/aircrack-ng-1.2-rc4/src/aircrack-ng.c:4088: undefined reference to `cpuinfo'
/home/toshi82/aircrack-ng-1.2-rc4/src/aircrack-ng.c:4088: undefined reference to `cpuinfo'
/home/toshi82/aircrack-ng-1.2-rc4/src/aircrack-ng.c:4128: undefined reference to `cpuinfo'
/home/toshi82/aircrack-ng-1.2-rc4/src/aircrack-ng.c:4131: undefined reference to `cpuinfo'
aircrack-ng-core.o:/home/toshi82/aircrack-ng-1.2-rc4/src/aircrack-ng.c:4221: more undefined references to `cpuinfo' follow
aircrack-ng-core.o: In function `main':
/home/toshi82/aircrack-ng-1.2-rc4/src/aircrack-ng.c:5217: undefined reference to `cpuid_getinfo'
wpapsk-simd.o: In function `init_wpapsk':
/home/toshi82/aircrack-ng-1.2-rc4/src/wpapsk.c:518: undefined reference to `cpuinfo'
wpapsk-simd.o: In function `wpapsk_sse':
/home/toshi82/aircrack-ng-1.2-rc4/src/wpapsk.c:218: undefined reference to `cpuinfo'
collect2: error: ld returned 1 exit status
make[1]: *** [Makefile:186: aircrack-ng-simd] Error 1
make[1]: Leaving directory '/home/aircrack-ng-1.2-rc4/src'
make: *** [Makefile:25: all] Error 2
Read the "Question Guidelines" link in my posting signature; without details, no one can help you.
You say nothing about version/distro of Linux, which is important, since the missing package name will vary by distro. Further, the software you're trying to compile is probably already available as a package...which we can't tell you how to find/install because we know nothing about your setup. Also, doing basic research first is a good thing, since the very error you mention has been filed as a bug-report: https://github.com/aircrack-ng/aircrack-ng/issues/155
I am using Fedora 27, I want to compile aircrack-ng-1.2-rc4 from the source since the yum and dnf installation has some bugs specially on airodump and airbase.
Yes I am new with Linux so I need your guidance about this problem. Thanks.
I have a lot of questions here, you have a lot going on.
FC27 is pretty new. Usually when you get a new distro you also have to put in a lot of development support. A default install usually won't let you build from source. Do you have some web site or tutorial that tells you how to set up a build environment?
Most likely line 4038 in file /home/toshi82/aircrack-ng-1.2-rc4/src/aircrack-ng.c
Have you checked out with geany for example what that line does?
--
I have a reason why I use gentoo, It ships with a working toolchain. I wanted to do the same with ubuntu many years ago and ditched that for obvious reasons.
And some stuff does not compile from git and other stuff. I usually only build from git or use gentoo based packages, or gentoo overlay packages. IF I do not find it there it is usually some git stuff. And that only sometimes build. some stuff needs a lot of patches or is not proplery coded. happened several times.
--
Have you reported back to your distro, so they may fix your issue?
#if defined(__i386__) || defined(__x86_64__)
// Set SIMD size to match what we can support, 1/4/8 (MMX/SSE2/AVX2)
cpuinfo.simdsize = cpuid_simdsize(0);
However, I cannot solved the problem on the following error lines
Quote:
aircrack-ng-core.o: In function `crack_wpa_thread':
/home/aircrack-ng-1.2-rc4/src/aircrack-ng.c:4039: undefined reference to `cpuid_simdsize'
aircrack-ng-core.o: In function `main':
/home/aircrack-ng-1.2-rc4/src/aircrack-ng.c:5218: undefined reference to `cpuid_getinfo'
I am using Fedora 27, I want to compile aircrack-ng-1.2-rc4 from the source since the yum and dnf installation has some bugs specially on airodump and airbase.
below are the output and errors when I enter make command...
[root@fedora aircrack-ng-1.2-rc4]# make
make -C src all
make[1]: Entering directory '/home/aircrack-ng-1.2-rc4/src'
gcc -g -w -Wall -O3 -pthread -D_FILE_OFFSET_BITS=64 -D_REVISION=0 -DCONFIG_LIBNL30 -DCONFIG_LIBNL -I/usr/include/libnl3 -fstack-protector-strong -Wno-unused-but-set-variable -Wno-array-bounds -Iinclude crypto.o common.o uniqueiv.o aircrack-ptw-lib.o memory.o simd-intrinsics.o aircrack-ng-core.o wpapsk-simd.o sha1-sse2.S -o aircrack-ng-simd -lpthread -lssl -lcrypto -lstdc++ liblinecount.a
aircrack-ng-core.o: In function `crack_wpa_thread':
/home/toshi82/aircrack-ng-1.2-rc4/src/aircrack-ng.c:4038: undefined reference to `cpuid_simdsize'
/home/toshi82/aircrack-ng-1.2-rc4/src/aircrack-ng.c:4038: undefined reference to `cpuinfo'
/home/toshi82/aircrack-ng-1.2-rc4/src/aircrack-ng.c:4088: undefined reference to `cpuinfo'
/home/toshi82/aircrack-ng-1.2-rc4/src/aircrack-ng.c:4088: undefined reference to `cpuinfo'
/home/toshi82/aircrack-ng-1.2-rc4/src/aircrack-ng.c:4128: undefined reference to `cpuinfo'
/home/toshi82/aircrack-ng-1.2-rc4/src/aircrack-ng.c:4131: undefined reference to `cpuinfo'
aircrack-ng-core.o:/home/toshi82/aircrack-ng-1.2-rc4/src/aircrack-ng.c:4221: more undefined references to `cpuinfo' follow
aircrack-ng-core.o: In function `main':
/home/toshi82/aircrack-ng-1.2-rc4/src/aircrack-ng.c:5217: undefined reference to `cpuid_getinfo'
wpapsk-simd.o: In function `init_wpapsk':
/home/toshi82/aircrack-ng-1.2-rc4/src/wpapsk.c:518: undefined reference to `cpuinfo'
wpapsk-simd.o: In function `wpapsk_sse':
/home/toshi82/aircrack-ng-1.2-rc4/src/wpapsk.c:218: undefined reference to `cpuinfo'
collect2: error: ld returned 1 exit status
make[1]: *** [Makefile:186: aircrack-ng-simd] Error 1
make[1]: Leaving directory '/home/aircrack-ng-1.2-rc4/src'
make: *** [Makefile:25: all] Error 2
I just downloaded aircrack-ng-1.2-rc4 and it compiled ok on
my linuxfromscratch system here. Did you edit the make file
before you ran make? I'm asking because your compile attempt
seems to be missing a step. On my first attempt make ran
"autocfg" while your output shows yours did not. Here's mine:
Code:
terry [ /sources/blfs/sources/xc/aircrack-ng-1.2-rc4 ]$ make
make -C src all
make[1]: Entering directory '/sources/blfs/sources/xc/aircrack-ng-1.2-rc4/src'
sh ../autocfg gcc ..
gcc -g -W -Wall -O3 -mavx -DJOHN_AVX -pthread -D_FILE_OFFSET_BITS=64 -D_REVISION=0 -DCONFIG_LIBNL30 -DCONFIG_LIBNL -I/usr/include/libnl3 -fstack-protector-strong -Wno-unused-but-set-variable -Wno-array-bounds -Iinclude -DSIMD_CORE -c -o aircrack-ng.o aircrack-ng.c
....more stuff here
Notice the "sh ../autocfg gcc .."
I don't know if that's part of your problem but I thought
I'd point it out to you. By the way, I did a make clean
and reran make and the autocfg did not get run the 2nd
time so it only happens at the first make.
I edited the MULTIBIN in the common.mak and change the value to "true" as suggested in https://aircrack-ng.blogspot.com/201...rovements.html for non-AVX unit. However, changing the MULTIBIN value into "true" will result to the error presented above. So, changing the vlaue of MULTIBIN is not a good idea IMO.
LinuxQuestions.org is looking for people interested in writing
Editorials, Articles, Reviews, and more. If you'd like to contribute
content, let us know.