赞
踩
POSIX可移植操作系统接口(Portable Operating System Interface of UNIX)
POSIX标准意在期望获得源代码级别的软件可移植性。换句话说,为一个POSIX兼容的操作系统编写的程序,应该可以在任何其它的POSIX操作系统(即使是来自另一个厂商)上编译执行。
如下是makefile文件:
SKIN=alchemy //皮肤设置
MAIN_SRC=periodicTask//对应任务的名字
TARGET=periodicTask
LM=-lm
CFLAGS := $(shell xeno-config --skin=alchemy --cflags)
LDFLAGS := $(LM) $(shell xeno-config --skin=alchemy --ldflags)
CC := $(shell xeno-config --cc)
$(TARGET): $(MAIN_SRC).c
$(CC) -o $@ $< $(CFLAGS) $(LDFLAGS)
想要编译出来makefile,只要在工程目录下输入如下命令
make
然后我们就可以根据编译错误进行修改。
(base) warmtree@warmtree-HP-Pavilion-Laptop-15-cc5xx:~$ sudo apt install kernel-package [sudo] warmtree 的密码: 正在读取软件包列表... 完成 正在分析软件包的依赖关系树 正在读取状态信息... 完成 kernel-package 已经是最新版 (13.018+nmu1)。 下列软件包是自动安装的并且现在不需要了: python-rosdep 使用'sudo apt autoremove'来卸载它(它们)。 升级了 0 个软件包,新安装了 0 个软件包,要卸载 0 个软件包,有 255 个软件包未被升级。 (base) warmtree@warmtree-HP-Pavilion-Laptop-15-cc5xx:~$ sudo apt-get install libssl-dev 正在读取软件包列表... 完成 正在分析软件包的依赖关系树 正在读取状态信息... 完成 libssl-dev 已经是最新版 (1.1.1-1ubuntu2.1~18.04.5)。 libssl-dev 已设置为手动安装。 下列软件包是自动安装的并且现在不需要了: python-rosdep 使用'sudo apt autoremove'来卸载它(它们)。 升级了 0 个软件包,新安装了 0 个软件包,要卸载 0 个软件包,有 255 个软件包未被升级。 (base) warmtree@warmtree-HP-Pavilion-Laptop-15-cc5xx:~$ Uname -a Command 'Uname' not found, did you mean: command 'uname' from deb coreutils Try: sudo apt install <deb name> (base) warmtree@warmtree-HP-Pavilion-Laptop-15-cc5xx:~$ uname -a Linux warmtree-HP-Pavilion-Laptop-15-cc5xx 5.3.0-53-generic #47~18.04.1-Ubuntu SMP Thu May 7 13:10:50 UTC 2020 x86_64 x86_64 x86_64 GNU/Linux (base) warmtree@warmtree-HP-Pavilion-Laptop-15-cc5xx:~$ dmesg | grep Xenomai (base) warmtree@warmtree-HP-Pavilion-Laptop-15-cc5xx:~$ ls anaconda3 ros2 Anaconda3-2019.03-Linux-x86_64.sh snap a.out testcpp a.py test.cpp base universe catkin visp catkin_tools visp-ws catkin_ws Zippen-Huang.github.io code 公共的 examples.desktop 模板 gym 视频 im1.jpg 图片 im2.jpg '未命名 1.odt' math.m '未命名 3.ods' opencv-2.4.13.5.zip 文档 project.m 下载 python-mnist 音乐 Re:ZICONG.odt 桌面 ros (base) warmtree@warmtree-HP-Pavilion-Laptop-15-cc5xx:~$ cd 下载 (base) warmtree@warmtree-HP-Pavilion-Laptop-15-cc5xx:~/下载$ ls A.jpg Dichotomous.zip discord-0.0.1.deb dmPDF.pdf 'fiche-signale tique-centrale nantes 2020.pdf' GR8_07-05.docx ipipe-core-4.14.134-x86-8.patch ipipe-core-4.9.146-x86-8.patch jbmaze-code linux-4.14.134 linux-4.14.134.tar.xz linux-4.9.146.tar.xz linux-5.7.tar M2_AVG Mystep2.zip okMANIP.pdf okRobotProgramming.pdf Project_descriptions.zip Project_report_first_page_model.odt sogoupinyin_2.3.1.0112_amd64.deb The+note+of+installing+the+Xenomai.pdf TypicalRrrorsDYBACDynamics.docx Untitled1.png wget-log xenomai-3.1 xenomai-3.1.tar.bz2 'Xenomai 3 LearningJun04.html' Xenomai3LearningJun05.html Xenomai3LearningJun12.html xenomai-master.zip XenomaiPeriodicRealTimeTaskExample.zip zoom_amd64.deb 陈家榜:ROS2.0+敏捷5G工业无线,使能未来无线工厂.pdf '未命名 1.odt' (base) warmtree@warmtree-HP-Pavilion-Laptop-15-cc5xx:~/下载$ cd xenomai-3.1/ (base) warmtree@warmtree-HP-Pavilion-Laptop-15-cc5xx:~/下载/xenomai-3.1$ ./configure --with-pic --with-core=cobalt --enable-smp --disable-tls --enable-dlopen-libs --disable-clock- configure: WARNING: unrecognized options: --disable-clock- checking whether we build for Cobalt or Mercury core... cobalt checking build system type... x86_64-pc-linux-gnu checking host system type... x86_64-pc-linux-gnu checking for a BSD-compatible install... /usr/bin/install -c checking for gcc... 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... no checking for suffix of object files... o checking whether we are using the GNU C compiler... yes checking whether gcc accepts -g... yes checking for gcc option to accept ISO C89... none needed checking whether gcc understands -c and -o together... yes checking how to run the C preprocessor... gcc -E checking target system type... x86_64-pc-linux-gnu checking for gcc... gcc checking whether we are using the GNU C compiler... (cached) yes checking whether gcc accepts -g... yes checking for gcc option to accept ISO C89... (cached) none needed checking whether gcc understands -c and -o together... (cached) yes checking how to run the C preprocessor... gcc -E checking for grep that handles long lines and -e... /bin/grep checking for BSD- or MS-compatible name lister (nm)... /usr/bin/nm -B checking the name lister (/usr/bin/nm -B) interface... BSD nm checking for gawk... no checking for mawk... mawk checking for a sed that does not truncate output... /bin/sed checking for egrep... /bin/grep -E checking for fgrep... /bin/grep -F checking how to print strings... printf checking for ld used by gcc... /usr/bin/ld checking if the linker (/usr/bin/ld) is GNU ld... yes checking command to parse /usr/bin/nm -B output from gcc object... ok checking for _ prefix in compiled symbols... no checking whether build environment is sane... yes checking for a thread-safe mkdir -p... /bin/mkdir -p checking whether make sets $(MAKE)... yes checking for style of include used by make... GNU checking whether make supports nested variables... yes checking whether UID '1000' is supported by ustar format... yes checking whether GID '1000' is supported by ustar format... yes checking how to create a ustar tar archive... gnutar checking dependency style of gcc... gcc3 checking whether make supports nested variables... (cached) yes checking whether to enable maintainer-specific portions of Makefiles... no checking dependency style of gcc... gcc3 checking for flex... no checking for lex... no checking for target architecture... x86 checking whether ln -s works... yes checking the maximum length of command line arguments... 1572864 checking how to convert x86_64-pc-linux-gnu file names to x86_64-pc-linux-gnu format... func_convert_file_noop checking how to convert x86_64-pc-linux-gnu file names to toolchain format... func_convert_file_noop checking for
Copyright © 2003-2013 www.wpsshop.cn 版权所有,并保留所有权利。