In /lib/modules/xx.xx.xx-xx there is supposed to be two soft links one called source and one called build. The source one is there and its fine but the build one is missing and I have no idea where it is supposed to point to and I need to install a driver for my video card. Is there any way to find out where that is supposed to point if so how and where. I know there are a lot of other questions out there but not of them actually discribe where they are supposed to be pointing in the end.
Updated the link and now it is having build errors that I can't fix because I can't even find the struct its talking about
make -C /lib/modules/3.16.0-4-amd64/build M=/home/gibsont/gpuTempDriver modules
make[1]: Entering directory '/usr/src/linux-headers-3.16.0-4-amd64'
Makefile:10: *** mixed implicit and normal rules: deprecated syntax
make[1]: Entering directory `/usr/src/linux-headers-3.16.0-4-amd64'
CC [M] /home/gibsont/gpuTempDriver/base.o
/home/gibsont/gpuTempDriver/base.c: In function ‘_rtl_init_mac80211’:
/home/gibsont/gpuTempDriver/base.c:319:6: error: ‘IEEE80211_HW_BEACON_FILTER’ undeclared (first use in this function)
IEEE80211_HW_BEACON_FILTER |
^
/home/gibsont/gpuTempDriver/base.c:319:6: note: each undeclared identifier is reported only once for each function it appears in
/home/gibsont/gpuTempDriver/base.c:349:4: error: ‘struct ieee80211_hw’ has no member named ‘channel_change_time’
hw->channel_change_time = 100;
^
/home/gibsont/gpuTempDriver/base.c: In function ‘rtl_action_proc’:
/home/gibsont/gpuTempDriver/base.c:858:32: error: ‘struct ieee80211_conf’ has no member named ‘channel’
rx_status.freq = hw->conf.channel->center_freq;
^
/home/gibsont/gpuTempDriver/base.c:859:32: error: ‘struct ieee80211_conf’ has no member named ‘channel’
rx_status.band = hw->conf.channel->band;
^
/home/gibsont/gpuTempDriver/base.c:861:25: error: ‘RX_FLAG_MACTIME_MPDU’ undeclared (first use in this function)
rx_status.flag |= RX_FLAG_MACTIME_MPDU;
^
/home/gibsont/gpuTempDriver/base.c: In function ‘rtl_beacon_statistic’:
/home/gibsont/gpuTempDriver/base.c:1132:2: error: implicit declaration of function ‘compare_ether_addr’ [-Werror=implicit-function-declaration]
if (compare_ether_addr(hdr->addr3, rtlpriv->mac80211.bssid))
^
/home/gibsont/gpuTempDriver/base.c: In function ‘rtl_send_smps_action’:
/home/gibsont/gpuTempDriver/base.c:1414:16: error: ‘struct <anonymous>’ has no member named ‘sta’
info->control.sta = sta;
^
/home/gibsont/gpuTempDriver/base.c:1415:24: error: ‘struct ieee80211_conf’ has no member named ‘channel’
info->band = hw->conf.channel->band;
^
cc1: some warnings being treated as errors
/usr/src/linux-headers-3.16.0-4-common/scripts/Makefile.build:262: recipe for target '/home/gibsont/gpuTempDriver/base.o' failed
make[4]: *** [/home/gibsont/gpuTempDriver/base.o] Error 1
/usr/src/linux-headers-3.16.0-4-common/Makefile:1350: recipe for target '_module_/home/gibsont/gpuTempDriver' failed
make[3]: *** [_module_/home/gibsont/gpuTempDriver] Error 2
Makefile:181: recipe for target 'sub-make' failed
make[2]: *** [sub-make] Error 2
Makefile:8: recipe for target 'all' failed
make[1]: *** [all] Error 2
make[1]: Leaving directory '/usr/src/linux-headers-3.16.0-4-amd64'
Makefile:27: recipe for target 'all' failed
make: *** [all] Error 2
I copied it from the disk because it was a read only and placed it into my home directory.
I feel like this has become a whole new issues or possibly the link is wrong and is causing this issue.
this is mine:
2509142 lrwxrwxrwx 1 root root 37 Apr 24 15:02 build -> /usr/src/linux-headers-3.16.0-4-amd64
actually it's managed by package manager. I install linux headers using apt-get. I think you should do the same, unless you are advanced kernel developer.
Related
During these days, I have tried to install riscv environment in Ubuntu System. According to the page, https://github.com/riscv/riscv-tools, I installed the toolchain successfully.
Then I tried to build the Linux Kernel, using this way:
$ cd $TOP
$ git clone https://github.com/riscv/riscv-linux.git linux-3.14.33
$ curl -L https://www.kernel.org/pub/linux/kernel/v3.x/linux-3.14.33.tar.xz | tar -xJkf -
When I execute this line, tar exists with failure, like this:
tar: linux-3.14.33/virt/kvm/arm/vgic.c: Cannot open: File exists
tar: linux-3.14.33/virt/kvm/assigned-dev.c: Cannot open: File exists
tar: linux-3.14.33/virt/kvm/async_pf.c: Cannot open: File exists
tar: linux-3.14.33/virt/kvm/async_pf.h: Cannot open: File exists
tar: linux-3.14.33/virt/kvm/coalesced_mmio.c: Cannot open: File exists
tar: linux-3.14.33/virt/kvm/coalesced_mmio.h: Cannot open: File exists
tar: linux-3.14.33/virt/kvm/eventfd.c: Cannot open: File exists
tar: linux-3.14.33/virt/kvm/ioapic.c: Cannot open: File exists
tar: linux-3.14.33/virt/kvm/ioapic.h: Cannot open: File exists
tar: linux-3.14.33/virt/kvm/iodev.h: Cannot open: File exists
tar: linux-3.14.33/virt/kvm/iommu.c: Cannot open: File exists
tar: linux-3.14.33/virt/kvm/irq_comm.c: Cannot open: File exists
tar: linux-3.14.33/virt/kvm/irqchip.c: Cannot open: File exists
tar: linux-3.14.33/virt/kvm/kvm_main.c: Cannot open: File exists
tar: linux-3.14.33/virt/kvm/vfio.c: Cannot open: File exists
tar: Exiting with failure status due to previous errors
I ignored this failure, and executed this:
$ cd linux-3.14.33
$ make ARCH=riscv defconfig
$ make ARCH=riscv menuconfig
$ make -j8 ARCH=riscv CROSS_COMPILE=riscv64-unknown-linux-gnu-
Then, some errors appeared:
crypto/kpp.c: In function 'crypto_kpp_report':
crypto/kpp.c:31:27: error: storage size of 'rkpp' isn't known
struct crypto_report_kpp rkpp;
^~~~
crypto/kpp.c:35:19: error: 'CRYPTOCFGA_REPORT_KPP' undeclared (first use in this function); did you mean 'CRYPTOCFGA_REPORT_RNG'?
if (nla_put(skb, CRYPTOCFGA_REPORT_KPP,
^~~~~~~~~~~~~~~~~~~~~
CRYPTOCFGA_REPORT_RNG
crypto/kpp.c:35:19: note: each undeclared identifier is reported only once for each function it appears in
crypto/kpp.c:36:14: error: invalid application of 'sizeof' to incomplete type 'struct crypto_report_kpp'
sizeof(struct crypto_report_kpp), &rkpp))
^~~~~~
crypto/kpp.c:31:27: warning: unused variable 'rkpp' [-Wunused-variable]
struct crypto_report_kpp rkpp;
^~~~
crypto/akcipher.c: In function 'crypto_akcipher_report':
crypto/akcipher.c:31:32: error: storage size of 'rakcipher' isn't known
struct crypto_report_akcipher rakcipher;
^~~~~~~~~
crypto/akcipher.c:35:19: error: 'CRYPTOCFGA_REPORT_AKCIPHER' undeclared (first use in this function); did you mean 'CRYPTOCFGA_REPORT_CIPHER'?
if (nla_put(skb, CRYPTOCFGA_REPORT_AKCIPHER,
^~~~~~~~~~~~~~~~~~~~~~~~~~
CRYPTOCFGA_REPORT_CIPHER
crypto/akcipher.c:35:19: note: each undeclared identifier is reported only once for each function it appears in
crypto/akcipher.c:36:14: error: invalid application of 'sizeof' to incomplete type 'struct crypto_report_akcipher'
sizeof(struct crypto_report_akcipher), &rakcipher))
^~~~~~
crypto/akcipher.c:31:32: warning: unused variable 'rakcipher' [-Wunused-variable]
struct crypto_report_akcipher rakcipher;
^~~~~~~~~
scripts/Makefile.build:302: recipe for target 'crypto/kpp.o' failed
make[1]: *** [crypto/kpp.o] Error 1
make[1]: *** Waiting for unfinished jobs....
scripts/Makefile.build:302: recipe for target 'crypto/akcipher.o' failed
make[1]: *** [crypto/akcipher.o] Error 1
crypto/acompress.c: In function 'crypto_acomp_report':
crypto/acompress.c:34:29: error: storage size of 'racomp' isn't known
struct crypto_report_acomp racomp;
^~~~~~
crypto/acompress.c:38:19: error: 'CRYPTOCFGA_REPORT_ACOMP' undeclared (first use in this function); did you mean 'CRYPTOCFGA_REPORT_AEAD'?
if (nla_put(skb, CRYPTOCFGA_REPORT_ACOMP,
^~~~~~~~~~~~~~~~~~~~~~~
CRYPTOCFGA_REPORT_AEAD
crypto/acompress.c:38:19: note: each undeclared identifier is reported only once for each function it appears in
crypto/acompress.c:39:14: error: invalid application of 'sizeof' to incomplete type 'struct crypto_report_acomp'
sizeof(struct crypto_report_acomp), &racomp))
^~~~~~
crypto/acompress.c:34:29: warning: unused variable 'racomp' [-Wunused-variable]
struct crypto_report_acomp racomp;
^~~~~~
scripts/Makefile.build:302: recipe for target 'crypto/acompress.o' failed
Thanks for your attention, and looking forward to your reply.
As we known, the repository of rocket-chip employs a specific version of riscv-tools, which is another repository. And in the homepage for the specific version of riscv-tools, there will be the version of the Linux kernel needed.
Actually, the tool-chain is tightly related to the hardware implementation. Therefore, we must use the only version specified in rocket-chip.
Use git to update the riscv-tools in rocket-chip.
git submodule update --init --recursive
I am attempting to run bitbake on a recipe with a non-yocto custom source. Using a linux-yocto source works fine, but when I attempt to use the linux-yocto-custom skeleton file provided by the yocto project files, I run into problems.
My file structure looks a little like this:
meta-test
|
.
.
.
+--recipes-kernel/
|
+--linux/
|
+--linux-yocto-custom_3.16.bb
+--linux-yocto-custom/
|
+--defconfig
Here's my modified skeleton file (linux-yocto-custom_3.16.bb):
inherit kernel
require recipes-kernel/linux/linux-yocto.inc
SRC_URI = "git://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git;protocol=git;nocheckout=1;name=machine"
SRC_URI += "file://defconfig"
LINUX_VERSION ?= "3.16"
LINUX_VERSION_EXTENSION_append = "-custom"
SRCREV_test="19583ca584d6f574384e17fe7613dfaeadcdc4a6"
PV = "${LINUX_VERSION}+git${SRCPV}"
COMPATIBLE_MACHINE = "test"
Here's the error log:
DEBUG: Executing shell function do_compile
NOTE: make -j 4 bzImage CC=i586-poky-linux-gcc -fuse-ld=bfd LD=i586-poky-linux-ld.bfd
make[1]: Entering directory `/home/me/poky/build/tmp/work/test-poky-linux/linux-yocto-custom/3.16+gitAUTOINC+19583ca584-r0/linux-test-standard-build'
GEN ./Makefile
scripts/kconfig/conf --silentoldconfig Kconfig
SYSTBL arch/x86/syscalls/../include/generated/asm/syscalls_32.h
SYSHDR arch/x86/syscalls/../include/generated/uapi/asm/unistd_32.h
CHK include/config/kernel.release
SYSHDR arch/x86/syscalls/../include/generated/uapi/asm/unistd_64.h
UPD include/config/kernel.release
SYSHDR arch/x86/syscalls/../include/generated/uapi/asm/unistd_x32.h
GEN ./Makefile
WRAP arch/x86/include/generated/asm/clkdev.h
WRAP arch/x86/include/generated/asm/early_ioremap.h
WRAP arch/x86/include/generated/asm/cputime.h
WRAP arch/x86/include/generated/asm/mcs_spinlock.h
CHK include/generated/uapi/linux/version.h
UPD include/generated/uapi/linux/version.h
CHK include/generated/utsrelease.h
UPD include/generated/utsrelease.h
HOSTCC scripts/kallsyms
HOSTCC scripts/pnmtologo
CC scripts/mod/empty.o
HOSTCC scripts/mod/mk_elfconfig
CC scripts/mod/devicetable-offsets.s
In file included from /home/me/poky/build/tmp/work-shared/test/kernel-source/include/linux/compiler.h:54:0,
from /home/me/poky/build/tmp/work-shared/test/kernel-source/include/uapi/linux/stddef.h:1,
from /home/me/poky/build/tmp/work-shared/test/kernel-source/include/linux/stddef.h:4,
from /home/me/poky/build/tmp/work-shared/test/kernel-source/include/uapi/linux/posix_types.h:4,
from /home/me/poky/build/tmp/work-shared/test/kernel-source/include/uapi/linux/types.h:13,
from /home/me/poky/build/tmp/work-shared/test/kernel-source/include/linux/types.h:5,
from /home/me/poky/build/tmp/work-shared/test/kernel-source/include/linux/mod_devicetable.h:11,
from /home/me/poky/build/tmp/work-shared/test/kernel-source/scripts/mod/devicetable-offsets.c:2:
/home/me/poky/build/tmp/work-shared/test/kernel-source/include/linux/compiler-gcc.h:106:30: fatal error: linux/compiler-gcc5.h: No such file or directory
compilation terminated.
make[4]: *** [scripts/mod/devicetable-offsets.s] Error 1
make[3]: *** [scripts/mod] Error 2
make[3]: *** Waiting for unfinished jobs....
make[2]: *** [scripts] Error 2
make[2]: *** Waiting for unfinished jobs....
make[1]: *** [sub-make] Error 2
make: *** [__sub-make] Error 2
WARNING: /home/me/poky/build/tmp/work/test-poky-linux/linux-yocto-custom/3.16+gitAUTOINC+19583ca584-r0/temp/run.do_compile.32722:1 exit 1 from
exit 1
ERROR: oe_runmake failed
ERROR: Function failed: do_compile (log file is located at /home/me/poky/build/tmp/work/test-poky-linux/linux-yocto-custom/3.16+gitAUTOINC+19583ca584-r0/temp/log.do_compile.32722)
I believe the most relevant portion is this part of the above log:
compiler-gcc.h:106:30: fatal error: linux/compiler-gcc5.h: No such file or directory
I'm really stumped because a file is generated during the build 'compiler-gcc5.h' at location build/tmp/work/test-poky-linux/core-image-test/1.0-r0/rootfs/usr/src/kernel/include/linux/compiler-gcc5.h. What's going on here? It seems to me that this header file's being requested before being fetched but I don't know how to fix that.
As you're fetching the kernel directly from Linus' tree, the 3.16 version does not support building with gcc5.
If you change to instead fetch from git://git.kernel.org/pub/scm/linux/kernel/git/stable/linux-stable.git, i.e. the stable tree, and change to v3.16.7:
SRC_URI = "git://git.kernel.org/pub/scm/linux/kernel/git/stable/linux-stable.git;protocol=git;nocheckout=1;name=machine;branch=linux-3.16.y"
SRCREV_test = "d0335e4feea0d3f7a8af3116c5dc166239da7521"
then you should be able to build the kernel without any issue.
I am compiling a stackable filesystem wrapfs and i got an error regardign missing member i_blksize in struct inode datastructure ? I looked up and found that after kernel version 2.6 it has been modified significantly and i_blksize has been removed. What is the replacement for that member ?
kunal#Baweja:~/Documents/wrapfs$ make
make -C /lib/modules/3.13.0-40-generic/build SUBDIRS=/home/kunal/Documents/wrapfs modules
make[1]: Entering directory `/usr/src/linux-headers-3.13.0-40-generic'
CC [M] /home/kunal/Documents/wrapfs/fist_wrapfs.o
In file included from /home/kunal/Documents/wrapfs/fist_wrapfs.c:15:0:
/home/kunal/Documents/wrapfs/wrapfs.h: In function ‘fist_copy_attr_all’:
/home/kunal/Documents/wrapfs/wrapfs.h:203:6: error: ‘inode_t’ has no member named ‘i_blksize’
dest->i_blksize = src->i_blksize;
^
/home/kunal/Documents/wrapfs/wrapfs.h:203:23: error: ‘inode_t’ has no member named ‘i_blksize’
dest->i_blksize = src->i_blksize;
^
make[2]: *** [/home/kunal/Documents/wrapfs/fist_wrapfs.o] Error 1
make[1]: *** [_module_/home/kunal/Documents/wrapfs] Error 2
make[1]: Leaving directory `/usr/src/linux-headers-3.13.0-40-generic'
make: *** [all] Error 2
Looks like it was an unnecessary duplicate
inode->i_blksize == (1 << inode->i_blkbits)
Check-out this mailing thread
I tried to use MySQL ODBC driver but that resulted in an error when I compile. MySQL ODBC driver is fine with Mariadb 5.5 but not Mariadb 10. So is there ODBC driver for Mariadb 10?
I installed MySQL Connector ODBC Driver source code version.
The follow is error messages:
* MySQL Connector ODBC Driver 5.3.4
Scanning dependencies of target myodbc5a
[ 6%] Building C object driver/CMakeFiles/myodbc5a.dir/catalog.c.o
[ 7%] Building C object driver/CMakeFiles/myodbc5a.dir/catalog_no_i_s.c.o
/myodbc/mysql-connector-odbc-5.3.4-src/driver/catalog_no_i_s.c:1096:69: error: macro "my_init_dynamic_array" requires 5 arguments, but only 4 given
/myodbc/mysql-connector-odbc-5.3.4-src/driver/catalog_no_i_s.c: In function 'foreign_keys_no_i_s':
/myodbc/mysql-connector-odbc-5.3.4-src/driver/catalog_no_i_s.c:1096: error: 'my_init_dynamic_array' undeclared (first use in this function)
/myodbc/mysql-connector-odbc-5.3.4-src/driver/catalog_no_i_s.c:1096: error: (Each undeclared identifier is reported only once
/myodbc/mysql-connector-odbc-5.3.4-src/driver/catalog_no_i_s.c:1096: error: for each function it appears in.)
make[2]: *** [driver/CMakeFiles/myodbc5a.dir/catalog_no_i_s.c.o] 오류 1
make[1]: *** [driver/CMakeFiles/myodbc5a.dir/all] 오류 2
make: *** [all] 오류 2
* MySQL Conncector ODBC Driver 5.2.7
[ 5%] Built target myodbc-util
Scanning dependencies of target myodbc5a
[ 6%] Building C object driver/CMakeFiles/myodbc5a.dir/catalog.c.o
[ 8%] Building C object driver/CMakeFiles/myodbc5a.dir/catalog_no_i_s.c.o
/myodbc/mysql-connector-odbc-5.2.7-src/driver/catalog_no_i_s.c:1096:69: error: macro "my_init_dynamic_array" requires 5 arguments, but only 4 given
/myodbc/mysql-connector-odbc-5.2.7-src/driver/catalog_no_i_s.c: In function 'foreign_keys_no_i_s':
/myodbc/mysql-connector-odbc-5.2.7-src/driver/catalog_no_i_s.c:1096: error: 'my_init_dynamic_array' undeclared (first use in this function)
/myodbc/mysql-connector-odbc-5.2.7-src/driver/catalog_no_i_s.c:1096: error: (Each undeclared identifier is reported only once
/myodbc/mysql-connector-odbc-5.2.7-src/driver/catalog_no_i_s.c:1096: error: for each function it appears in.)
make[2]: *** [driver/CMakeFiles/myodbc5a.dir/catalog_no_i_s.c.o] 오류 1
make[1]: *** [driver/CMakeFiles/myodbc5a.dir/all] 오류 2
make: *** [all] 오류 2
* MySQL Conncector ODBC Driver 5.1.13
[ 9%] Building C object driver/CMakeFiles/myodbc5.dir/ansi.c.o
[ 11%] Building C object driver/CMakeFiles/myodbc5.dir/catalog.c.o
[ 12%] Building C object driver/CMakeFiles/myodbc5.dir/catalog_no_i_s.c.o
[ 14%] Building C object driver/CMakeFiles/myodbc5.dir/connect.c.o
[ 16%] Building C object driver/CMakeFiles/myodbc5.dir/cursor.c.o
[ 18%] Building C object driver/CMakeFiles/myodbc5.dir/desc.c.o
/myodbc/mysql-connector-odbc-5.1.13-src/driver/desc.c:66:66: error: macro "my_init_dynamic_array" requires 5 arguments, but only 4 given
/myodbc/mysql-connector-odbc-5.1.13-src/driver/desc.c: In function 'desc_alloc':
/myodbc/mysql-connector-odbc-5.1.13-src/driver/desc.c:66: error: 'my_init_dynamic_array' undeclared (first use in this function)
/myodbc/mysql-connector-odbc-5.1.13-src/driver/desc.c:66: error: (Each undeclared identifier is reported only once
/myodbc/mysql-connector-odbc-5.1.13-src/driver/desc.c:66: error: for each function it appears in.)
/myodbc/mysql-connector-odbc-5.1.13-src/driver/desc.c: In function 'MySQLSetDescField':
/myodbc/mysql-connector-odbc-5.1.13-src/driver/desc.c:778: warning: cast from pointer to integer of different size
/myodbc/mysql-connector-odbc-5.1.13-src/driver/desc.c:786: warning: cast from pointer to integer of different size
/myodbc/mysql-connector-odbc-5.1.13-src/driver/desc.c:895:57: error: macro "my_init_dynamic_array" requires 5 arguments, but only 4 given
/myodbc/mysql-connector-odbc-5.1.13-src/driver/desc.c: In function 'MySQLCopyDesc':
/myodbc/mysql-connector-odbc-5.1.13-src/driver/desc.c:893: error: 'my_init_dynamic_array' undeclared (first use in this function)
make[2]: *** [driver/CMakeFiles/myodbc5.dir/desc.c.o] 오류 1
make[1]: *** [driver/CMakeFiles/myodbc5.dir/all] 오류 2
make: *** [all] 오류 2
Gentoo seems to have a patch for this:
http://sources.gentoo.org/cgi-bin/viewvc.cgi/gentoo-x86/dev-db/myodbc/files/5.2.7-mariadb-dynamic-array.patch?view=markup
The problem was introduced with the addition of per-thread memory usage statistics ( https://mariadb.atlassian.net/browse/MDEV-4011 ) which required the addition of an additional parameter to the my_init_dynamic_array() macro. This macro isn't defined as part of the public client API, but is exposed in the my_sys.h header file nonetheless and is used by MySQL ODBC, so this change broke the ODBC code when compiled against recent MariaDB versions.
Alternatives are applying above patch, or switching to the MariaDB ODBC driver (which is still in beta though):
https://mariadb.com/kb/en/mariadb/client-libraries/mariadb-odbc-driver/
I try to install BusyBox 1.20.2 on a embedded system with PowerPc. At first I want to try it with the default config.
So this are the commands
make defconfig
make
And this is the result:
ma-bash-3.2# make
CC miscutils/ubi_tools.o
miscutils/ubi_tools.c: In function 'ubi_tools_main':
miscutils/ubi_tools.c:137: error: 'UBI_DEV_NUM_AUTO' undeclared (first use in this function)
miscutils/ubi_tools.c:137: error: (Each undeclared identifier is reported only once
miscutils/ubi_tools.c:137: error: for each function it appears in.)
miscutils/ubi_tools.c:157: error: storage size of 'req' isn't known
miscutils/ubi_tools.c:165: error: 'UBI_IOCATT' undeclared (first use in this function)
miscutils/ubi_tools.c:157: warning: unused variable 'req'
miscutils/ubi_tools.c:171: error: 'UBI_IOCDET' undeclared (first use in this function)
make[1]: *** [miscutils/ubi_tools.o] Error 1
make: *** [miscutils] Error 2
How is it possible to solve that Error?
Can I disable this ubi_tool ? What effects will that have and how to do that?
Remove these lines in .config:
CONFIG_UBIATTACH=y
CONFIG_UBIDETACH=y
CONFIG_UBIMKVOL=y
CONFIG_UBIRMVOL=y
CONFIG_UBIRSVOL=y
CONFIG_UBIUPDATEVOL=y
you won't have support for ubifs.