Warning: file_get_contents(/data/phpspider/zhask/data//catemap/2/linux/24.json): failed to open stream: No such file or directory in /data/phpspider/zhask/libs/function.php on line 167

Warning: Invalid argument supplied for foreach() in /data/phpspider/zhask/libs/tag.function.php on line 1116

Notice: Undefined index: in /data/phpspider/zhask/libs/function.php on line 180

Warning: array_chunk() expects parameter 1 to be array, null given in /data/phpspider/zhask/libs/function.php on line 181
缺少到linux源代码树的软链接_Linux_Kernel_Kernel Module - Fatal编程技术网

缺少到linux源代码树的软链接

缺少到linux源代码树的软链接,linux,kernel,kernel-module,Linux,Kernel,Kernel Module,在/lib/modules/xx.xx.xx-xx中,应该有两个软链接,一个叫做source,另一个叫做build。源代码在那里,它很好,但是构建版本丢失了,我不知道它应该指向哪里,我需要为我的视频卡安装一个驱动程序。有没有办法找出它应该指向哪里,如果有,如何以及在哪里。我知道还有很多其他的问题,但没有一个真正描述了他们最终应该指向哪里 更新了链接,现在它有构建错误,我无法修复,因为我甚至找不到它所说的结构 make -C /lib/modules/3.16.0-4-amd64/build M=

在/lib/modules/xx.xx.xx-xx中,应该有两个软链接,一个叫做source,另一个叫做build。源代码在那里,它很好,但是构建版本丢失了,我不知道它应该指向哪里,我需要为我的视频卡安装一个驱动程序。有没有办法找出它应该指向哪里,如果有,如何以及在哪里。我知道还有很多其他的问题,但没有一个真正描述了他们最终应该指向哪里

更新了链接,现在它有构建错误,我无法修复,因为我甚至找不到它所说的结构

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
make-C/lib/modules/3.16.0-4-amd64/build M=/home/gibsont/gputemp驱动程序模块
make[1]:输入目录“/usr/src/linux-headers-3.16.0-4-amd64”
Makefile:10:**混合隐式和常规规则:不推荐使用的语法
make[1]:输入目录“/usr/src/linux-headers-3.16.0-4-amd64”
CC[M]/home/gibsont/gpuTempDriver/base.o
/home/gibsont/gpuTempDriver/base.c:在函数“\u rtl\u init\u mac80211”中:
/home/gibsont/gpuTempDriver/base.c:319:6:错误:“IEEE80211_-HW_-BEACON_-FILTER”未声明(此函数首次使用)
IEEE80211无线信标滤波器|
^
/home/gibsont/gpuTempDriver/base.c:319:6:注意:每个未声明的标识符对于它出现在其中的每个函数只报告一次
/home/gibsont/gpuTempDriver/base.c:349:4:错误:“struct ieee80211\u hw”没有名为“channel\u change\u time”的成员
hw->channel_change_time=100;
^
/home/gibsont/gpuTempDriver/base.c:在函数“rtl\u action\u proc”中:
/home/gibsont/gpuTempDriver/base.c:858:32:错误:“struct ieee80211_conf”没有名为“channel”的成员
rx_status.freq=hw->conf.channel->center_freq;
^
/home/gibsont/gpuTempDriver/base.c:859:32:错误:“struct ieee80211_conf”没有名为“channel”的成员
rx_status.band=hw->conf.channel->band;
^
/home/gibsont/gpuTempDriver/base.c:861:25:错误:“RX\u FLAG\u MACTIME\u MPDU”未声明(此函数首次使用)
rx_status.flag |=rx_flag_MACTIME_MPDU;
^
/home/gibsont/gpuTempDriver/base.c:在函数“rtl\u beacon\u statistic”中:
/home/gibsont/gpuTempDriver/base.c:1132:2:错误:函数“compare\u ether\u addr”的隐式声明[-Werror=隐式函数声明]
如果(比较地址(hdr->addr3,rtlpriv->mac80211.bssid))
^
/home/gibsont/gpuTempDriver/base.c:在函数“rtl\u发送\u smps\u操作”中:
/home/gibsont/gpuTempDriver/base.c:1414:16:错误:“struct”没有名为“sta”的成员
info->control.sta=sta;
^
/home/gibsont/gpuTempDriver/base.c:1415:24:错误:“struct ieee80211_conf”没有名为“channel”的成员
信息->波段=hw->形态频道->波段;
^
cc1:某些警告被视为错误
/usr/src/linux-headers-3.16.0-4-common/scripts/Makefile.build:262:recipe for target'/home/gibsont/gpuTempDriver/base.o'失败
生成[4]:***[/home/gibsont/gpuTempDriver/base.o]错误1
/usr/src/linux-headers-3.16.0-4-common/Makefile:1350:目标“\u module\u/home/gibsont/gpuTempDriver”的配方失败
生成[3]:***[[U模块\主/gibsont/gpuTempDriver]错误2
生成文件:181:目标“子生成”的配方失败
make[2]:***[sub make]错误2
Makefile:8:目标“全部”的配方失败
生成[1]:***[all]错误2
make[1]:离开目录“/usr/src/linux-headers-3.16.0-4-amd64”
Makefile:27:目标“全部”的配方失败
make:**[全部]错误2
我从磁盘上复制了它,因为它是只读的,并把它放在我的主目录中

我觉得这已经成为一个全新的问题,或者可能是链接错误导致了这个问题。

这是我的:

2509142 lrwxrwxrwx  1 root root     37 Apr 24 15:02 build -> /usr/src/linux-headers-3.16.0-4-amd64

实际上它是由包管理器管理的。我使用apt-get安装linux头文件。我认为您也应该这样做,除非您是高级内核开发人员。

我安装了linux头文件,它没有更新或创建链接,但它更新了源链接。我将链接设置为与您的目录相同的目录,因为该目录与我的版本和cpu类型相同,现在我遇到了一些其他生成错误。@nonprofitgibi这表示您的生成未完成。您应该尝试重新安装标题,看看是否有一些错误消息。