arm-linux-gnueabihf-gcc-11.1.0
在交叉编译之前,需要设置交叉编译工具链的环境变量。
export PATH=/path/to/toolchains/arm-linux-gnueabihf/bin:$PATH
libuuid download | SourceForge.net
下载并解压源码。
tar -xvzf libuuid-1.0.3.tar.gz
CC=arm-linux-gnueabihf-gcc ./configure \
--host=arm-linux-gnueabihf \
--prefix=/path/to/libuuid-1.0.3/arm32_install \
--enable-shared
输出示例:
yoyo@yoyo:~/360Downloads/libuuid-1.0.3$ CC=arm-linux-gnueabihf-gcc ./configure \
> --host=arm-linux-gnueabihf \
> --prefix=/path/to/libuuid-1.0.3/arm32_install \
> --enable-shared
checking for a BSD-compatible install... /usr/bin/install -c
checking whether build environment is sane... yes
checking for arm-linux-gnueabihf-strip... arm-linux-gnueabihf-strip
checking for a thread-safe mkdir -p... /usr/bin/mkdir -p
checking for gawk... no
checking for mawk... mawk
checking whether make sets $(MAKE)... yes
checking whether make supports nested variables... yes
checking build system type... x86_64-unknown-linux-gnu
checking host system type... arm-unknown-linux-gnueabihf
checking how to print strings... printf
checking for style of include used by make... GNU
checking for arm-linux-gnueabihf-gcc... arm-linux-gnueabihf-gcc
checking whether the C compiler works... yes
checking for C compiler default output file name... a.out
checking for suffix of executables...
checking whether we are cross compiling... yes
checking for suffix of object files... o
checking whether we are using the GNU C compiler... yes
checking whether arm-linux-gnueabihf-gcc accepts -g... yes
checking for arm-linux-gnueabihf-gcc option to accept ISO C89... none needed
checking dependency style of arm-linux-gnueabihf-gcc... gcc3
checking for a sed that does not truncate output... /usr/bin/sed
checking for grep that handles long lines and -e... /usr/bin/grep
checking for egrep... /usr/bin/grep -E
checking for fgrep... /usr/bin/grep -F
checking for ld used by arm-linux-gnueabihf-gcc... /path/to/toolchains/arm-linux-gnueabihf/arm-linux-gnueabihf/bin/ld
checking if the linker (/path/to/toolchains/arm-linux-gnueabihf/arm-linux-gnueabihf/bin/ld) is GNU ld... yes
checking for BSD- or MS-compatible name lister (nm)... /path/to/toolchains/arm-linux-gnueabihf/bin/arm-linux-gnueabihf-nm -B
checking the name lister (/path/to/toolchains/arm-linux-gnueabihf/bin/arm-linux-gnueabihf-nm -B) interface... BSD nm
checking whether ln -s works... yes
checking the maximum length of command line arguments... 1572864
checking whether the shell understands some XSI constructs... yes
checking whether the shell understands "+="... yes
checking how to convert x86_64-unknown-linux-gnu file names to arm-unknown-linux-gnueabihf format... func_convert_file_noop
checking how to convert x86_64-unknown-linux-gnu file names to toolchain format... func_convert_file_noop
checking for /path/to/toolchains/arm-linux-gnueabihf/arm-linux-gnueabihf/bin/ld option to reload object files... -r
checking for arm-linux-gnueabihf-objdump... arm-linux-gnueabihf-objdump
checking how to recognize dependent libraries... pass_all
checking for arm-linux-gnueabihf-dlltool... no
checking for dlltool... no
checking how to associate runtime and link libraries... printf %s\n
checking for arm-linux-gnueabihf-ar... arm-linux-gnueabihf-ar
checking for archiver @FILE support... @
checking for arm-linux-gnueabihf-strip... (cached) arm-linux-gnueabihf-strip
checking for arm-linux-gnueabihf-ranlib... arm-linux-gnueabihf-ranlib
checking command to parse /path/to/toolchains/arm-linux-gnueabihf/bin/arm-linux-gnueabihf-nm -B output from arm-linux-gnueabihf-gcc object... ok
checking for sysroot... no
checking for arm-linux-gnueabihf-mt... no
checking for mt... mt
configure: WARNING: using cross tools not prefixed with host triplet
checking if mt is a manifest tool... no
checking how to run the C preprocessor... arm-linux-gnueabihf-gcc -E
checking for ANSI C header files... yes
checking for sys/types.h... yes
checking for sys/stat.h... yes
checking for stdlib.h... yes
checking for string.h... yes
checking for memory.h... yes
checking for strings.h... yes
checking for inttypes.h... yes
checking for stdint.h... yes
checking for unistd.h... yes
checking for dlfcn.h... yes
checking for objdir... .libs
checking if arm-linux-gnueabihf-gcc supports -fno-rtti -fno-exceptions... no
checking for arm-linux-gnueabihf-gcc option to produce PIC... -fPIC -DPIC
checking if arm-linux-gnueabihf-gcc PIC flag -fPIC -DPIC works... yes
checking if arm-linux-gnueabihf-gcc static flag -static works... yes
checking if arm-linux-gnueabihf-gcc supports -c -o file.o... yes
checking if arm-linux-gnueabihf-gcc supports -c -o file.o... (cached) yes
checking whether the arm-linux-gnueabihf-gcc linker (/path/to/toolchains/arm-linux-gnueabihf/arm-linux-gnueabihf/bin/ld) supports shared libraries... yes
checking whether -lc should be explicitly linked in... no
checking dynamic linker characteristics... GNU/Linux ld.so
checking how to hardcode library paths into programs... immediate
checking whether stripping libraries is possible... yes
checking if libtool supports shared libraries... yes
checking whether to build shared libraries... yes
checking whether to build static libraries... yes
checking for arm-linux-gnueabihf-gcc... (cached) arm-linux-gnueabihf-gcc
checking whether we are using the GNU C compiler... (cached) yes
checking whether arm-linux-gnueabihf-gcc accepts -g... (cached) yes
checking for arm-linux-gnueabihf-gcc option to accept ISO C89... (cached) none needed
checking dependency style of arm-linux-gnueabihf-gcc... (cached) gcc3
checking for library containing socket... none required
checking fcntl.h usability... yes
checking fcntl.h presence... yes
checking for fcntl.h... yes
checking for inttypes.h... (cached) yes
checking limits.h usability... yes
checking limits.h presence... yes
checking for limits.h... yes
checking netinet/in.h usability... yes
checking netinet/in.h presence... yes
checking for netinet/in.h... yes
checking for stdlib.h... (cached) yes
checking for string.h... (cached) yes
checking sys/file.h usability... yes
checking sys/file.h presence... yes
checking for sys/file.h... yes
checking sys/ioctl.h usability... yes
checking sys/ioctl.h presence... yes
checking for sys/ioctl.h... yes
checking sys/socket.h usability... yes
checking sys/socket.h presence... yes
checking for sys/socket.h... yes
checking sys/time.h usability... yes
checking sys/time.h presence... yes
checking for sys/time.h... yes
checking for unistd.h... (cached) yes
checking whether _SC_HOST_NAME_MAX is declared... yes
checking for int32_t... yes
checking for mode_t... yes
checking for size_t... yes
checking for ssize_t... yes
checking for uint16_t... yes
checking for uint32_t... yes
checking for uint64_t... yes
checking for uint8_t... yes
checking for ftruncate... yes
checking for gettimeofday... yes
checking for memset... yes
checking for socket... yes
checking for strtoul... yes
checking for usleep... yes
checking for srandom... yes
checking that generated files are newer than configure... done
configure: creating ./config.status
config.status: creating Makefile
config.status: creating uuid.pc
config.status: creating config.h
config.status: executing depfiles commands
config.status: executing libtool commands
make -j8
make install
安装后的目录:
yoyo@yoyo:~/360Downloads/libuuid-1.0.3$ tree -L 3 arm32_install/
arm32_install/
├── include
│ └── uuid
│ └── uuid.h
└── lib
├── libuuid.a
├── libuuid.la
├── libuuid.so -> libuuid.so.1.0.0
├── libuuid.so.1 -> libuuid.so.1.0.0
├── libuuid.so.1.0.0
└── pkgconfig
└── uuid.pc
make 编译:
yoyo@yoyo:~/360Downloads/libuuid-1.0.3$ make -j8
make all-am
make[1]: Entering directory '/path/to/libuuid-1.0.3'
/bin/bash ./libtool --tag=CC --mode=compile arm-linux-gnueabihf-gcc -DHAVE_CONFIG_H -I. -I. -g -O2 -MT libuuid_la-clear.lo -MD -MP -MF .deps/libuuid_la-clear.Tpo -c -o libuuid_la-clear.lo `test -f 'clear.c' || echo './'`clear.c
/bin/bash ./libtool --tag=CC --mode=compile arm-linux-gnueabihf-gcc -DHAVE_CONFIG_H -I. -I. -g -O2 -MT libuuid_la-compare.lo -MD -MP -MF .deps/libuuid_la-compare.Tpo -c -o libuuid_la-compare.lo `test -f 'compare.c' || echo './'`compare.c
/bin/bash ./libtool --tag=CC --mode=compile arm-linux-gnueabihf-gcc -DHAVE_CONFIG_H -I. -I. -g -O2 -MT libuuid_la-copy.lo -MD -MP -MF .deps/libuuid_la-copy.Tpo -c -o libuuid_la-copy.lo `test -f 'copy.c' || echo './'`copy.c
/bin/bash ./libtool --tag=CC --mode=compile arm-linux-gnueabihf-gcc -DHAVE_CONFIG_H -I. -I. -g -O2 -MT libuuid_la-gen_uuid.lo -MD -MP -MF .deps/libuuid_la-gen_uuid.Tpo -c -o libuuid_la-gen_uuid.lo `test -f 'gen_uuid.c' || echo './'`gen_uuid.c
/bin/bash ./libtool --tag=CC --mode=compile arm-linux-gnueabihf-gcc -DHAVE_CONFIG_H -I. -I. -g -O2 -MT libuuid_la-isnull.lo -MD -MP -MF .deps/libuuid_la-isnull.Tpo -c -o libuuid_la-isnull.lo `test -f 'isnull.c' || echo './'`isnull.c
/bin/bash ./libtool --tag=CC --mode=compile arm-linux-gnueabihf-gcc -DHAVE_CONFIG_H -I. -I. -g -O2 -MT libuuid_la-pack.lo -MD -MP -MF .deps/libuuid_la-pack.Tpo -c -o libuuid_la-pack.lo `test -f 'pack.c' || echo './'`pack.c
/bin/bash ./libtool --tag=CC --mode=compile arm-linux-gnueabihf-gcc -DHAVE_CONFIG_H -I. -I. -g -O2 -MT libuuid_la-parse.lo -MD -MP -MF .deps/libuuid_la-parse.Tpo -c -o libuuid_la-parse.lo `test -f 'parse.c' || echo './'`parse.c
/bin/bash ./libtool --tag=CC --mode=compile arm-linux-gnueabihf-gcc -DHAVE_CONFIG_H -I. -I. -g -O2 -MT libuuid_la-unpack.lo -MD -MP -MF .deps/libuuid_la-unpack.Tpo -c -o libuuid_la-unpack.lo `test -f 'unpack.c' || echo './'`unpack.c
libtool: compile: arm-linux-gnueabihf-gcc -DHAVE_CONFIG_H -I. -I. -g -O2 -MT libuuid_la-clear.lo -MD -MP -MF .deps/libuuid_la-clear.Tpo -c clear.c -fPIC -DPIC -o .libs/libuuid_la-clear.o
libtool: compile: arm-linux-gnueabihf-gcc -DHAVE_CONFIG_H -I. -I. -g -O2 -MT libuuid_la-parse.lo -MD -MP -MF .deps/libuuid_la-parse.Tpo -c parse.c -fPIC -DPIC -o .libs/libuuid_la-parse.o
libtool: compile: arm-linux-gnueabihf-gcc -DHAVE_CONFIG_H -I. -I. -g -O2 -MT libuuid_la-compare.lo -MD -MP -MF .deps/libuuid_la-compare.Tpo -c compare.c -fPIC -DPIC -o .libs/libuuid_la-compare.o
libtool: compile: arm-linux-gnueabihf-gcc -DHAVE_CONFIG_H -I. -I. -g -O2 -MT libuuid_la-copy.lo -MD -MP -MF .deps/libuuid_la-copy.Tpo -c copy.c -fPIC -DPIC -o .libs/libuuid_la-copy.o
libtool: compile: arm-linux-gnueabihf-gcc -DHAVE_CONFIG_H -I. -I. -g -O2 -MT libuuid_la-pack.lo -MD -MP -MF .deps/libuuid_la-pack.Tpo -c pack.c -fPIC -DPIC -o .libs/libuuid_la-pack.o
libtool: compile: arm-linux-gnueabihf-gcc -DHAVE_CONFIG_H -I. -I. -g -O2 -MT libuuid_la-unpack.lo -MD -MP -MF .deps/libuuid_la-unpack.Tpo -c unpack.c -fPIC -DPIC -o .libs/libuuid_la-unpack.o
libtool: compile: arm-linux-gnueabihf-gcc -DHAVE_CONFIG_H -I. -I. -g -O2 -MT libuuid_la-isnull.lo -MD -MP -MF .deps/libuuid_la-isnull.Tpo -c isnull.c -fPIC -DPIC -o .libs/libuuid_la-isnull.o
libtool: compile: arm-linux-gnueabihf-gcc -DHAVE_CONFIG_H -I. -I. -g -O2 -MT libuuid_la-gen_uuid.lo -MD -MP -MF .deps/libuuid_la-gen_uuid.Tpo -c gen_uuid.c -fPIC -DPIC -o .libs/libuuid_la-gen_uuid.o
In file included from /path/to/toolchains/arm-linux-gnueabihf/arm-linux-gnueabihf/libc/usr/include/bits/libc-header-start.h:33,
from /path/to/toolchains/arm-linux-gnueabihf/arm-linux-gnueabihf/libc/usr/include/stdio.h:27,
from gen_uuid.c:46:
/path/to/toolchains/arm-linux-gnueabihf/arm-linux-gnueabihf/libc/usr/include/features.h:187:3: warning: #warning "_BSD_SOURCE and _SVID_SOURCE are deprecated, use _DEFAULT_SOURCE" [-Wcpp]
187 | # warning "_BSD_SOURCE and _SVID_SOURCE are deprecated, use _DEFAULT_SOURCE"
| ^~~~~~~
libtool: compile: arm-linux-gnueabihf-gcc -DHAVE_CONFIG_H -I. -I. -g -O2 -MT libuuid_la-clear.lo -MD -MP -MF .deps/libuuid_la-clear.Tpo -c clear.c -o libuuid_la-clear.o >/dev/null 2>&1
libtool: compile: arm-linux-gnueabihf-gcc -DHAVE_CONFIG_H -I. -I. -g -O2 -MT libuuid_la-copy.lo -MD -MP -MF .deps/libuuid_la-copy.Tpo -c copy.c -o libuuid_la-copy.o >/dev/null 2>&1
libtool: compile: arm-linux-gnueabihf-gcc -DHAVE_CONFIG_H -I. -I. -g -O2 -MT libuuid_la-pack.lo -MD -MP -MF .deps/libuuid_la-pack.Tpo -c pack.c -o libuuid_la-pack.o >/dev/null 2>&1
libtool: compile: arm-linux-gnueabihf-gcc -DHAVE_CONFIG_H -I. -I. -g -O2 -MT libuuid_la-compare.lo -MD -MP -MF .deps/libuuid_la-compare.Tpo -c compare.c -o libuuid_la-compare.o >/dev/null 2>&1
gen_uuid.c: In function 'get_clock':
gen_uuid.c:297:24: warning: implicit declaration of function 'flock'; did you mean 'clock'? [-Wimplicit-function-declaration]
297 | while (flock(state_fd, LOCK_EX) < 0) {
| ^~~~~
| clock
libtool: compile: arm-linux-gnueabihf-gcc -DHAVE_CONFIG_H -I. -I. -g -O2 -MT libuuid_la-isnull.lo -MD -MP -MF .deps/libuuid_la-isnull.Tpo -c isnull.c -o libuuid_la-isnull.o >/dev/null 2>&1
libtool: compile: arm-linux-gnueabihf-gcc -DHAVE_CONFIG_H -I. -I. -g -O2 -MT libuuid_la-unpack.lo -MD -MP -MF .deps/libuuid_la-unpack.Tpo -c unpack.c -o libuuid_la-unpack.o >/dev/null 2>&1
mv -f .deps/libuuid_la-clear.Tpo .deps/libuuid_la-clear.Plo
libtool: compile: arm-linux-gnueabihf-gcc -DHAVE_CONFIG_H -I. -I. -g -O2 -MT libuuid_la-parse.lo -MD -MP -MF .deps/libuuid_la-parse.Tpo -c parse.c -o libuuid_la-parse.o >/dev/null 2>&1
/bin/bash ./libtool --tag=CC --mode=compile arm-linux-gnueabihf-gcc -DHAVE_CONFIG_H -I. -I. -g -O2 -MT libuuid_la-unparse.lo -MD -MP -MF .deps/libuuid_la-unparse.Tpo -c -o libuuid_la-unparse.lo `test -f 'unparse.c' || echo './'`unparse.c
mv -f .deps/libuuid_la-copy.Tpo .deps/libuuid_la-copy.Plo
/bin/bash ./libtool --tag=CC --mode=compile arm-linux-gnueabihf-gcc -DHAVE_CONFIG_H -I. -I. -g -O2 -MT libuuid_la-uuid_time.lo -MD -MP -MF .deps/libuuid_la-uuid_time.Tpo -c -o libuuid_la-uuid_time.lo `test -f 'uuid_time.c' || echo './'`uuid_time.c
mv -f .deps/libuuid_la-unpack.Tpo .deps/libuuid_la-unpack.Plo
libtool: compile: arm-linux-gnueabihf-gcc -DHAVE_CONFIG_H -I. -I. -g -O2 -MT libuuid_la-unparse.lo -MD -MP -MF .deps/libuuid_la-unparse.Tpo -c unparse.c -fPIC -DPIC -o .libs/libuuid_la-unparse.o
/bin/bash ./libtool --tag=CC --mode=compile arm-linux-gnueabihf-gcc -DHAVE_CONFIG_H -I. -I. -g -O2 -MT libuuid_la-randutils.lo -MD -MP -MF .deps/libuuid_la-randutils.Tpo -c -o libuuid_la-randutils.lo `test -f 'randutils.c' || echo './'`randutils.c
mv -f .deps/libuuid_la-compare.Tpo .deps/libuuid_la-compare.Plo
mv -f .deps/libuuid_la-pack.Tpo .deps/libuuid_la-pack.Plo
libtool: compile: arm-linux-gnueabihf-gcc -DHAVE_CONFIG_H -I. -I. -g -O2 -MT libuuid_la-uuid_time.lo -MD -MP -MF .deps/libuuid_la-uuid_time.Tpo -c uuid_time.c -fPIC -DPIC -o .libs/libuuid_la-uuid_time.o
mv -f .deps/libuuid_la-isnull.Tpo .deps/libuuid_la-isnull.Plo
libtool: compile: arm-linux-gnueabihf-gcc -DHAVE_CONFIG_H -I. -I. -g -O2 -MT libuuid_la-randutils.lo -MD -MP -MF .deps/libuuid_la-randutils.Tpo -c randutils.c -fPIC -DPIC -o .libs/libuuid_la-randutils.o
libtool: compile: arm-linux-gnueabihf-gcc -DHAVE_CONFIG_H -I. -I. -g -O2 -MT libuuid_la-gen_uuid.lo -MD -MP -MF .deps/libuuid_la-gen_uuid.Tpo -c gen_uuid.c -o libuuid_la-gen_uuid.o >/dev/null 2>&1
mv -f .deps/libuuid_la-parse.Tpo .deps/libuuid_la-parse.Plo
libtool: compile: arm-linux-gnueabihf-gcc -DHAVE_CONFIG_H -I. -I. -g -O2 -MT libuuid_la-unparse.lo -MD -MP -MF .deps/libuuid_la-unparse.Tpo -c unparse.c -o libuuid_la-unparse.o >/dev/null 2>&1
libtool: compile: arm-linux-gnueabihf-gcc -DHAVE_CONFIG_H -I. -I. -g -O2 -MT libuuid_la-uuid_time.lo -MD -MP -MF .deps/libuuid_la-uuid_time.Tpo -c uuid_time.c -o libuuid_la-uuid_time.o >/dev/null 2>&1
libtool: compile: arm-linux-gnueabihf-gcc -DHAVE_CONFIG_H -I. -I. -g -O2 -MT libuuid_la-randutils.lo -MD -MP -MF .deps/libuuid_la-randutils.Tpo -c randutils.c -o libuuid_la-randutils.o >/dev/null 2>&1
mv -f .deps/libuuid_la-unparse.Tpo .deps/libuuid_la-unparse.Plo
mv -f .deps/libuuid_la-uuid_time.Tpo .deps/libuuid_la-uuid_time.Plo
mv -f .deps/libuuid_la-gen_uuid.Tpo .deps/libuuid_la-gen_uuid.Plo
mv -f .deps/libuuid_la-randutils.Tpo .deps/libuuid_la-randutils.Plo
/bin/bash ./libtool --tag=CC --mode=link arm-linux-gnueabihf-gcc -I. -g -O2 -version-info 1:0:0 -o libuuid.la -rpath /path/to/libuuid-1.0.3/arm32_install/lib libuuid_la-clear.lo libuuid_la-compare.lo libuuid_la-copy.lo libuuid_la-gen_uuid.lo libuuid_la-isnull.lo libuuid_la-pack.lo libuuid_la-parse.lo libuuid_la-unpack.lo libuuid_la-unparse.lo libuuid_la-uuid_time.lo libuuid_la-randutils.lo
libtool: link: arm-linux-gnueabihf-gcc -shared -fPIC -DPIC .libs/libuuid_la-clear.o .libs/libuuid_la-compare.o .libs/libuuid_la-copy.o .libs/libuuid_la-gen_uuid.o .libs/libuuid_la-isnull.o .libs/libuuid_la-pack.o .libs/libuuid_la-parse.o .libs/libuuid_la-unpack.o .libs/libuuid_la-unparse.o .libs/libuuid_la-uuid_time.o .libs/libuuid_la-randutils.o -O2 -Wl,-soname -Wl,libuuid.so.1 -o .libs/libuuid.so.1.0.0
libtool: link: (cd ".libs" && rm -f "libuuid.so.1" && ln -s "libuuid.so.1.0.0" "libuuid.so.1")
libtool: link: (cd ".libs" && rm -f "libuuid.so" && ln -s "libuuid.so.1.0.0" "libuuid.so")
libtool: link: arm-linux-gnueabihf-ar cru .libs/libuuid.a libuuid_la-clear.o libuuid_la-compare.o libuuid_la-copy.o libuuid_la-gen_uuid.o libuuid_la-isnull.o libuuid_la-pack.o libuuid_la-parse.o libuuid_la-unpack.o libuuid_la-unparse.o libuuid_la-uuid_time.o libuuid_la-randutils.o
libtool: link: arm-linux-gnueabihf-ranlib .libs/libuuid.a
libtool: link: ( cd ".libs" && rm -f "libuuid.la" && ln -s "../libuuid.la" "libuuid.la" )
make[1]: Leaving directory '/path/to/libuuid-1.0.3'
make install 安装:
yoyo@yoyo:~/360Downloads/libuuid-1.0.3$ make install
make[1]: Entering directory '/path/to/libuuid-1.0.3'
/usr/bin/mkdir -p '/path/to/libuuid-1.0.3/arm32_install/lib'
/bin/bash ./libtool --mode=install /usr/bin/install -c libuuid.la '/path/to/libuuid-1.0.3/arm32_install/lib'
libtool: install: /usr/bin/install -c .libs/libuuid.so.1.0.0 /path/to/libuuid-1.0.3/arm32_install/lib/libuuid.so.1.0.0
libtool: install: (cd /path/to/libuuid-1.0.3/arm32_install/lib && { ln -s -f libuuid.so.1.0.0 libuuid.so.1 || { rm -f libuuid.so.1 && ln -s libuuid.so.1.0.0 libuuid.so.1; }; })
libtool: install: (cd /path/to/libuuid-1.0.3/arm32_install/lib && { ln -s -f libuuid.so.1.0.0 libuuid.so || { rm -f libuuid.so && ln -s libuuid.so.1.0.0 libuuid.so; }; })
libtool: install: /usr/bin/install -c .libs/libuuid.lai /path/to/libuuid-1.0.3/arm32_install/lib/libuuid.la
libtool: install: /usr/bin/install -c .libs/libuuid.a /path/to/libuuid-1.0.3/arm32_install/lib/libuuid.a
libtool: install: chmod 644 /path/to/libuuid-1.0.3/arm32_install/lib/libuuid.a
libtool: install: arm-linux-gnueabihf-ranlib /path/to/libuuid-1.0.3/arm32_install/lib/libuuid.a
libtool: finish: PATH="/path/to/toolchains/arm-linux-gnueabihf/bin:/path/to/cmake-3.31.3-linux-x86_64/bin:/home/yoyo/miniconda3/condabin:/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin:/usr/games:/usr/local/games:/snap/bin:/sbin" ldconfig -n /path/to/libuuid-1.0.3/arm32_install/lib
----------------------------------------------------------------------
Libraries have been installed in:
/path/to/libuuid-1.0.3/arm32_install/lib
If you ever happen to want to link against installed libraries
in a given directory, LIBDIR, you must either use libtool, and
specify the full pathname of the library, or use the `-LLIBDIR'
flag during linking and do at least one of the following:
- add LIBDIR to the `LD_LIBRARY_PATH' environment variable
during execution
- add LIBDIR to the `LD_RUN_PATH' environment variable
during linking
- use the `-Wl,-rpath -Wl,LIBDIR' linker flag
- have your system administrator add LIBDIR to `/etc/ld.so.conf'
See any operating system documentation about shared libraries for
more information, such as the ld(1) and ld.so(8) manual pages.
----------------------------------------------------------------------
/usr/bin/mkdir -p '/path/to/libuuid-1.0.3/arm32_install/lib/pkgconfig'
/usr/bin/install -c -m 644 uuid.pc '/path/to/libuuid-1.0.3/arm32_install/lib/pkgconfig'
/usr/bin/mkdir -p '/path/to/libuuid-1.0.3/arm32_install/include/uuid'
/usr/bin/install -c -m 644 uuid.h '/path/to/libuuid-1.0.3/arm32_install/include/uuid'
make[1]: Leaving directory '/path/to/libuuid-1.0.3'
将编译好的文件,拷贝到开发板。
# 拷贝 include
cp -r ./arm32_install/include/ /usr/local/libuuid/
# 拷贝lib
cp -r ./arm32_install/lib/ /usr/local/libuuid/