這期內(nèi)容當(dāng)中小編將會(huì)給大家?guī)碛嘘P(guān)怎么在Linux系統(tǒng)中使用busybox中的mkfs.vfat命令,文章內(nèi)容豐富且以專業(yè)的角度為大家分析和敘述,閱讀完這篇文章希望大家可以有所收獲。
創(chuàng)新互聯(lián)網(wǎng)站建設(shè)服務(wù)商,為中小企業(yè)提供成都做網(wǎng)站、成都網(wǎng)站設(shè)計(jì)服務(wù),網(wǎng)站設(shè)計(jì),網(wǎng)站托管運(yùn)營等一站式綜合服務(wù)型公司,專業(yè)打造企業(yè)形象網(wǎng)站,讓您在眾多競爭對手中脫穎而出創(chuàng)新互聯(lián)。
思路1
重新移植busybox
1.官網(wǎng)上下載最新的busybox源碼
2.修改Makefile
ARCH =arm CROSS_COMPILE = /opt/hisi-linux-nptl/arm-hisiv100-linux/target/bin/arm-hisiv100nptl-linux-
2.make menuconfig
設(shè)置為靜態(tài)庫
3.make
出現(xiàn)錯(cuò)誤
make: *** [busybox_unstripped] Error 1 root@chenwr-pc:/home/soft/busybox-1.31.0# make LINK busybox_unstripped Your linker does not support --sort-section,alignment Your linker does not support --sort-common Static linking against glibc, can't use --gc-sections Trying libraries: crypt m resolv Failed: -Wl,--start-group -lcrypt -lm -lresolv -Wl,--end-group Output of: /opt/hisi-linux-nptl/arm-hisiv100-linux/target/bin/arm-hisiv100nptl-linux-gcc -Wall -Wshadow -Wwrite-strings -Wundef -Wstrict-prototypes -Wunused -Wunused-parameter -Wunused-function -Wunused-value -Wmissing-prototypes -Wmissing-declarations -Wno-format-security -Wdeclaration-after-statement -Wold-style-definition -fno-builtin-strlen -finline-limit=0 -fomit-frame-pointer -ffunction-sections -fdata-sections -fno-guess-branch-probability -funsigned-char -static-libgcc -falign-functions=1 -falign-jumps=1 -falign-labels=1 -falign-loops=1 -fno-unwind-tables -fno-asynchronous-unwind-tables -fno-builtin-printf -Os -static -march=armv7l -o busybox_unstripped -Wl,--start-group applets/built-in.o archival/lib.a archival/libarchive/lib.a console-tools/lib.a coreutils/lib.a coreutils/libcoreutils/lib.a debianutils/lib.a klibc-utils/lib.a e2fsprogs/lib.a editors/lib.a findutils/lib.a init/lib.a libbb/lib.a libpwdgrp/lib.a loginutils/lib.a mailutils/lib.a miscutils/lib.a modutils/lib.a networking/lib.a networking/libiproute/lib.a networking/udhcp/lib.a printutils/lib.a procps/lib.a runit/lib.a selinux/lib.a shell/lib.a sysklogd/lib.a util-linux/lib.a util-linux/volume_id/lib.a archival/built-in.o archival/libarchive/built-in.o console-tools/built-in.o coreutils/built-in.o coreutils/libcoreutils/built-in.o debianutils/built-in.o klibc-utils/built-in.o e2fsprogs/built-in.o editors/built-in.o findutils/built-in.o init/built-in.o libbb/built-in.o libpwdgrp/built-in.o loginutils/built-in.o mailutils/built-in.o miscutils/built-in.o modutils/built-in.o networking/built-in.o networking/libiproute/built-in.o networking/udhcp/built-in.o printutils/built-in.o procps/built-in.o runit/built-in.o selinux/built-in.o shell/built-in.o sysklogd/built-in.o util-linux/built-in.o util-linux/volume_id/built-in.o -Wl,--end-group -Wl,--start-group -lcrypt -lm -lresolv -Wl,--end-group ========== networking/lib.a(ipcalc.o): In function `ipcalc_main': ipcalc.c:(.text.ipcalc_main+0x24c): warning: gethostbyaddr is obsolescent, use getaddrinfo() instead. libbb/lib.a(inet_common.o): In function `INET_resolve': inet_common.c:(.text.INET_resolve+0x60): warning: gethostbyname is obsolescent, use getnameinfo() instead. coreutils/lib.a(mktemp.o): In function `mktemp_main': mktemp.c:(.text.mktemp_main+0x8c): warning: the use of `mktemp' is dangerous, better use `mkstemp' networking/lib.a(nslookup.o): In function `add_query': nslookup.c:(.text.add_query+0x70): undefined reference to `res_mkquery' networking/lib.a(nslookup.o): In function `send_queries': nslookup.c:(.text.send_queries+0x2d0): undefined reference to `__ns_initparse' nslookup.c:(.text.send_queries+0x308): undefined reference to `__ns_parserr' nslookup.c:(.text.send_queries+0x480): undefined reference to `__ns_get16' nslookup.c:(.text.send_queries+0x5cc): undefined reference to `__ns_get32' nslookup.c:(.text.send_queries+0x5e4): undefined reference to `__ns_get32' nslookup.c:(.text.send_queries+0x5fc): undefined reference to `__ns_get32' nslookup.c:(.text.send_queries+0x614): undefined reference to `__ns_get32' nslookup.c:(.text.send_queries+0x628): undefined reference to `__ns_get32' util-linux/lib.a(fallocate.o): In function `fallocate_main': fallocate.c:(.text.fallocate_main+0x80): undefined reference to `posix_fallocate' util-linux/lib.a(unshare.o): In function `unshare_main': unshare.c:(.text.unshare_main+0x1ec): undefined reference to `unshare' collect2: ld returned 1 exit status Note: if build needs additional libraries, put them in CONFIG_EXTRA_LDLIBS. Example: CONFIG_EXTRA_LDLIBS="pthread dl tirpc audit pam" make: *** [busybox_unstripped] Error 1
重新make menuconfig 進(jìn)入設(shè)置把報(bào)錯(cuò)的模塊關(guān)閉不勾選。
參考網(wǎng)上的說法,還是會(huì)有很多錯(cuò)誤。而且關(guān)閉很多網(wǎng)絡(luò)的東西和系統(tǒng)的配置,擔(dān)心萬一影響到其他命令呢。因?yàn)槲野l(fā)現(xiàn)原來移植后的busybox,比如ls命令,不是單獨(dú)的一個(gè)bin文件。而是軟連接到busybox中
而且我發(fā)覺設(shè)備的空間有限,原先的busybox才800多k,即使新移植成功也要2M多。于是換個(gè)思路,單獨(dú)源碼移植mkfs.vfat
上述就是小編為大家分享的怎么在Linux系統(tǒng)中使用busybox中的mkfs.vfat命令了,如果剛好有類似的疑惑,不妨參照上述分析進(jìn)行理解。如果想知道更多相關(guān)知識,歡迎關(guān)注創(chuàng)新互聯(lián)行業(yè)資訊頻道。
網(wǎng)頁題目:怎么在Linux系統(tǒng)中使用busybox中的mkfs.vfat命令
網(wǎng)站路徑:http://jinyejixie.com/article4/jjhdoe.html
成都網(wǎng)站建設(shè)公司_創(chuàng)新互聯(lián),為您提供標(biāo)簽優(yōu)化、App開發(fā)、服務(wù)器托管、建站公司、云服務(wù)器、網(wǎng)站設(shè)計(jì)
聲明:本網(wǎng)站發(fā)布的內(nèi)容(圖片、視頻和文字)以用戶投稿、用戶轉(zhuǎn)載內(nèi)容為主,如果涉及侵權(quán)請盡快告知,我們將會(huì)在第一時(shí)間刪除。文章觀點(diǎn)不代表本網(wǎng)站立場,如需處理請聯(lián)系客服。電話:028-86922220;郵箱:631063699@qq.com。內(nèi)容未經(jīng)允許不得轉(zhuǎn)載,或轉(zhuǎn)載時(shí)需注明來源: 創(chuàng)新互聯(lián)