linux下面安裝dnw

來源:互聯網
上載者:User

標籤:linux   dnw   

[[email protected] secbulk]# make -C /lib/modules/`uname -r`/build M=`pwd` modules
make: *** /lib/modules/2.6.32-71.el6.i686/build: 沒有那個檔案或目錄。 停止。
[[email protected] secbulk]# make -C /lib/modules/`uname-r`/build M=`pwd` modules
bash: uname-r: command not found

make: *** /lib/modules//build: 沒有那個檔案或目錄。 停止。


這時需要安裝kernel-devel

[[email protected] dnw]# sudo yum install kernel-devel
Loaded plugins: refresh-packagekit, rhnplugin
This system is not registered with RHN.
RHN support will be disabled.
Setting up Install Process
Resolving Dependencies
--> Running transaction check
---> Package kernel-devel.i686 0:2.6.32-71.el6 set to be installed
--> Finished Dependency Resolution


Dependencies Resolved


================================================================================
 Package               Arch          Version                Repository     Size
================================================================================
Installing:
 kernel-devel          i686          2.6.32-71.el6          base          6.4 M


Transaction Summary
================================================================================
Install       1 Package(s)
Upgrade       0 Package(s)


Total download size: 6.4 M
Installed size: 22 M
Is this ok [y/N]: y
Downloading Packages:
Running rpm_check_debug
Running Transaction Test
Transaction Test Succeeded
Running Transaction
Warning: RPMDB altered outside of yum.
  Installing     : kernel-devel-2.6.32-71.el6.i686                          1/1 


Installed:
  kernel-devel.i686 0:2.6.32-71.el6                                             


Complete!


然後使用

[[email protected] secbulk]# make -C /lib/modules/`uname -r`/build M=`pwd` modules
make: Entering directory `/usr/src/kernels/2.6.32-71.el6.i686‘
  CC [M]  /arm11/dnw_linux/secbulk/secbulk.o
/arm11/dnw_linux/secbulk/secbulk.c: 在函數‘secbulk_write’中:
/arm11/dnw_linux/secbulk/secbulk.c:58: 警告:比較不相關的指標時缺少類型轉換
  Building modules, stage 2.
  MODPOST 1 modules
  CC      /arm11/dnw_linux/secbulk/secbulk.mod.o
  LD [M]  /arm11/dnw_linux/secbulk/secbulk.ko.unsigned
  NO SIGN [M] /arm11/dnw_linux/secbulk/secbulk.ko
make: Leaving directory `/usr/src/kernels/2.6.32-71.el6.i686‘

[[email protected] secbulk]# ls
Makefile       Module.symvers  secbulk.ko           secbulk.mod.c  secbulk.o
modules.order  secbulk.c       secbulk.ko.unsigned  secbulk.mod.o

[[email protected] secbulk]# insmod ./sec

[[email protected] secbulk]# dmesgbulk.ko

usb 2-2.2: new full speed USB device using uhci_hcd and address 8
usb 2-2.2: New USB device found, idVendor=1a86, idProduct=7523
usb 2-2.2: New USB device strings: Mfr=0, Product=2, SerialNumber=0
usb 2-2.2: Product: USB2.0-Ser!
usb 2-2.2: configuration #1 chosen from 1 choice
ch341 2-2.2:1.0: ch341-uart converter detected
usb 2-2.2: ch341-uart converter now attached to ttyUSB0
hrtimer: interrupt took 12195662 ns
usb 2-2.2: USB disconnect, address 8
ch341-uart ttyUSB0: ch341-uart converter now disconnected from ttyUSB0
ch341 2-2.2:1.0: device disconnected
usb 2-2.2: new full speed USB device using uhci_hcd and address 9
usb 2-2.2: New USB device found, idVendor=1a86, idProduct=7523
usb 2-2.2: New USB device strings: Mfr=0, Product=2, SerialNumber=0
usb 2-2.2: Product: USB2.0-Ser!
usb 2-2.2: configuration #1 chosen from 1 choice
ch341 2-2.2:1.0: ch341-uart converter detected
usb 2-2.2: ch341-uart converter now attached to ttyUSB0
secbulk: disagrees about version of symbol module_layout
secbulk:secbulk loaded
usbcore: registered new interface driver secbulk

聯繫我們

該頁面正文內容均來源於網絡整理,並不代表阿里雲官方的觀點,該頁面所提到的產品和服務也與阿里云無關,如果該頁面內容對您造成了困擾,歡迎寫郵件給我們,收到郵件我們將在5個工作日內處理。

如果您發現本社區中有涉嫌抄襲的內容,歡迎發送郵件至: info-contact@alibabacloud.com 進行舉報並提供相關證據,工作人員會在 5 個工作天內聯絡您,一經查實,本站將立刻刪除涉嫌侵權內容。

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.