06 2019 档案

Makefile模板
摘要:Makefile模板: 1.生成可执行程序的Makefile 2.生成静态链接库的Makefile 3.生成动态链接库的Makefile 阅读全文

posted @ 2019-06-30 19:50 Alvin2012 阅读(113) 评论(0) 推荐(0) 编辑

linux下类似beyond compare的软件推荐
摘要:windows比较文件差异使用的是beyond compare, 而在linux下也有同样类似的meld sudo apt-get install meld 阅读全文

posted @ 2019-06-30 18:45 Alvin2012 阅读(728) 评论(0) 推荐(0) 编辑

运行时找不到动态链接库
摘要:运行时找不到动态链接库的4种解决方法: 1.将动态链接库放到/lib或者/usr/lib或者/usr/local/lib目录下 2.export LD_LIBRARY_PATH=$LD_LIBRARY_PATH:your_library_path 3.修改/etc/ld.so.cache中缓存的动态 阅读全文

posted @ 2019-06-30 00:13 Alvin2012 阅读(706) 评论(0) 推荐(0) 编辑

Makefile中的$
摘要:$@指目标 $^指所有依赖 $<指第一个依赖 阅读全文

posted @ 2019-06-29 21:47 Alvin2012 阅读(97) 评论(0) 推荐(0) 编辑

配置wifi的AP模式
摘要:配置wifi的AP模式: 需要busybox里面有ifconfig,udhcpd,tcpsvd,ftpd 另外有hostapd 加载wifi驱动时要设置op_mode为AP模式 作者的wifi模块是博通的,modprobe bcmdhd op_mode=2 ifconfig wlan0 uphost 阅读全文

posted @ 2019-06-28 15:45 Alvin2012 阅读(2291) 评论(0) 推荐(0) 编辑

shell根据程序名获取进程号
摘要:shell根据程序名获取进程号: ps -A | grep "cmdname" | awk '{print $1}' 阅读全文

posted @ 2019-06-27 13:40 Alvin2012 阅读(816) 评论(0) 推荐(0) 编辑

读取/dev/urandom生成固定位数的随机数
摘要:读取/dev/urandom生成固定位数的随机数: 1.纯数字 head /dev/urandom | tr -dc 0-9 | head -c n 2.小写字母+数字 head /dev/urandom | tr -dc a-z0-9 | head -c n 3.大小写字母+数字 head /de 阅读全文

posted @ 2019-06-26 09:20 Alvin2012 阅读(957) 评论(0) 推荐(0) 编辑

升级完pip后出错:Traceback (most recent call last): File "/usr/bin/pip", line 11, in <module> sys.exit(__main__.main())
摘要:今天在ubuntu上升级了pip,之后执行pip命令的时候就报错了: Traceback (most recent call last): File "/usr/bin/pip", line 11, in <module> sys.exit(__main__.main()) 解决方法: sudo v 阅读全文

posted @ 2019-06-22 14:34 Alvin2012 阅读(16242) 评论(0) 推荐(0) 编辑

openssh交叉编译
摘要:openssh交叉编译: 1.官网下载地址: https://www.mindrot.org/openssh_snap/ 2.配置: openssh需要依赖openssl和zlib 首先需要编译另两个依赖库,可以参见作者其它两篇随笔。 作者将交叉编译好的openssl和zlib放到/usr/loca 阅读全文

posted @ 2019-06-21 16:59 Alvin2012 阅读(2824) 评论(0) 推荐(0) 编辑

zlib交叉编译
摘要:zlib交叉编译: 1.mkdir __install 2.export CC=arm-linux-gnueabihf-gcc 3../configure --prefix=$(pwd)/__install 4.make 5.make install 注:zlib的configure不支持配置CC, 阅读全文

posted @ 2019-06-21 16:01 Alvin2012 阅读(480) 评论(0) 推荐(0) 编辑

C语言编译动态链接库
摘要:C语言编译动态链接库: gcc test.c -fPIC -shared -o libtest.so 阅读全文

posted @ 2019-06-21 15:16 Alvin2012 阅读(178) 评论(0) 推荐(0) 编辑

使用service命令管理linux服务
摘要:使用service命令管理linux服务: 我们来看一下service的manual: DESCRIPTION service runs a System V init script or upstart job in as predictable environment as possi‐ ble 阅读全文

posted @ 2019-06-20 12:01 Alvin2012 阅读(131) 评论(0) 推荐(0) 编辑

使用busybox配置ftp server
摘要:使用busybox配置ftp server: 1.在编译busybox时加入tcpsvd和ftpd 2.tcpsvd作用: Create TCP socket, bind to IP:PORT and listen for incoming connection. Run PROG for each 阅读全文

posted @ 2019-06-20 10:18 Alvin2012 阅读(1713) 评论(0) 推荐(0) 编辑

嵌入式linux上根文件系统中增加用户
摘要:嵌入式linux上根文件系统中增加用户: 系统启动的时候会执行login, /bin/login是一个软连接,指向busybox,login->busybox 它会解析/etc/passwd和/etc/shadow文件,可以将PC机上的用户增加到嵌入式linux上的跟文件系统中的这两个文件中来。 注 阅读全文

posted @ 2019-06-19 20:07 Alvin2012 阅读(493) 评论(0) 推荐(0) 编辑

使用vsftpd部署ftp服务器
摘要:使用vsftpd部署ftp服务器: 1.sudo mkdir /usr/share/empty 2.sudo mkdir -p /etc/vsftpd/userconf 3.sudo vi /etc/vsftpd/userconf/xxx 其中xxx为你的用户名 加入你的登录默认目录: 1 /hom 阅读全文

posted @ 2019-06-19 14:47 Alvin2012 阅读(439) 评论(0) 推荐(0) 编辑

vsftpd交叉编译
摘要:vsftpd交叉编译: 1.cd vsftpd-3.0.3 2.git df Makefile 3.make 阅读全文

posted @ 2019-06-19 14:41 Alvin2012 阅读(1327) 评论(0) 推荐(0) 编辑

vi: can't read user input
摘要:vi: can't read user input: 解决方法: 命令行输入:bash 阅读全文

posted @ 2019-06-18 17:02 Alvin2012 阅读(1166) 评论(0) 推荐(0) 编辑

wireless_tools交叉编译
摘要:wireless_tools交叉编译: 1.cd wireless_tools.29 2.mkdir __install 3.git df Makefile 4.make 5.make install 阅读全文

posted @ 2019-06-17 19:34 Alvin2012 阅读(666) 评论(0) 推荐(0) 编辑

wpa_supplicant交叉编译
摘要:wpa_supplicant交叉编译: 1.cd wpa_supplicant-0.7.3/wpa_supplicant 2.cp deconfig .config 3.vi .config 加上下面的内容: 4.make 阅读全文

posted @ 2019-06-17 09:42 Alvin2012 阅读(1431) 评论(0) 推荐(0) 编辑

.bashrc配置文件
摘要:分享一下作者的.bashrc文件 阅读全文

posted @ 2019-06-17 09:33 Alvin2012 阅读(645) 评论(0) 推荐(0) 编辑

.gitconfig配置文件
摘要:git的配置文件分为三个层级: 1.对所有用户,位于/etc/gitconfig 2.对于当前用户,位于~/.gitconfig 3.对于该git仓,位于.git/config 建议配置当前用户的.gitconfig文件 分享一下作者的配置文件: 阅读全文

posted @ 2019-06-17 09:31 Alvin2012 阅读(4210) 评论(0) 推荐(1) 编辑

git commit -F时用到的commit.log模板
摘要:分享一下作者git commit -F时的commit.log模板: 作者将commit.log放在~/目录下 阅读全文

posted @ 2019-06-16 18:16 Alvin2012 阅读(685) 评论(0) 推荐(0) 编辑

github上需要生成密钥对:ssh key
摘要:1.首先查看当前用户之前是否生成过密钥对:ls ~/.ssh 如果不存在该目录则之前未生成过,如果存在则删除该目录:rm -rf ~/.ssh 2.生成ssh key密钥对: ssh-keygen -t rsa -C “alvin@alvin.com” 双引号里面的为你的邮箱 3.执行上述命令后连按 阅读全文

posted @ 2019-06-16 10:57 Alvin2012 阅读(86) 评论(0) 推荐(0) 编辑

windows和linux字体库位置
摘要:windows字体库位置: C:\Windows\Fonts linux字体库位置: /usr/share/fonts 阅读全文

posted @ 2019-06-16 09:50 Alvin2012 阅读(687) 评论(0) 推荐(0) 编辑

.vimrc配置文件
摘要:分享一下作者的.vimrc配置文件: 阅读全文

posted @ 2019-06-15 10:53 Alvin2012 阅读(117) 评论(0) 推荐(0) 编辑

iw交叉编译
摘要:iw交叉编译: mkdir __install alvin@ubuntu:~/Documents/wifi_ap/iw-5.0$ git df Makefilediff --git a/Makefile b/Makefileindex 46d3030..95c7a01 100644 a/Makefi 阅读全文

posted @ 2019-06-14 19:31 Alvin2012 阅读(270) 评论(0) 推荐(0) 编辑

libnl和libopenssl,hostapd交叉编译
摘要:1.nl: mkdir __install ./configure CC=arm-linux-gnueabihf-gcc \ --prefix=$(pwd)/__install \ --host=arm-linux-gnueabihf \ CFLAGS=-I/usr/include make mak 阅读全文

posted @ 2019-06-14 17:55 Alvin2012 阅读(2431) 评论(0) 推荐(0) 编辑

linux中断
摘要:linux中断: 内核版本:linux-5.1.7 中断注册函数:request_irq() 位置:linux-5.1.7/include/linux/interrupt.h 内核中把这种短小的inline函数都放在了头文件中。 函数原型:static inline int __must_check 阅读全文

posted @ 2019-06-09 21:37 Alvin2012 阅读(112) 评论(0) 推荐(0) 编辑

对cmake的理解
摘要:对cmake的理解: cmake官方文档:https://cmake.org/documentation/ 我们这里只介绍一下对cmake命令行的理解: 作者在编译中主要用到了第一条命令cmake [<options>] <path-to-source> 在build tree目录下编译source 阅读全文

posted @ 2019-06-09 21:24 Alvin2012 阅读(303) 评论(0) 推荐(0) 编辑

嵌入式系统增加文件系统分区
摘要:最近工作中需要在arm架构的单板上增加一个fat格式的文件系统分区用于windows访问,就回顾了一下文件系统和linux分区。简单写几句: 单板的存储介质是eMMC,linux系统,采用交叉编译。增加分区就直接在fastboot传给kernel的参数中增加一个分区就好了,没什么要说的。 这里主要说 阅读全文

posted @ 2019-06-09 18:03 Alvin2012 阅读(1039) 评论(0) 推荐(0) 编辑

opencv源码交叉编译
摘要:环境: 主机:Linux alvin-Lenovo-V310-14ISK 4.13.0-46-generic #51-Ubuntu SMP Tue Jun 12 12:36:29 UTC 2018 x86_64 x86_64 x86_64 GNU/Linux linux下交叉编译arm平台openc 阅读全文

posted @ 2019-06-08 21:24 Alvin2012 阅读(5960) 评论(0) 推荐(0) 编辑

opencv源码编译
摘要:环境: 主机:Linux alvin-Lenovo-V310-14ISK 4.13.0-46-generic #51-Ubuntu SMP Tue Jun 12 12:36:29 UTC 2018 x86_64 x86_64 x86_64 GNU/Linux linux下编译opencv源码步骤: 阅读全文

posted @ 2019-06-08 00:16 Alvin2012 阅读(1269) 评论(0) 推荐(1) 编辑

tensorflow安装
摘要:环境: 1.主机:Linux alvin-Lenovo-V310-14ISK 4.13.0-46-generic #51-Ubuntu SMP Tue Jun 12 12:36:29 UTC 2018 x86_64 x86_64 x86_64 GNU/Linux 2.Python版本 :Python 阅读全文

posted @ 2019-06-06 23:01 Alvin2012 阅读(100) 评论(0) 推荐(0) 编辑

导航

点击右上角即可分享
微信分享提示