这是我的makefile。COM := src_dir1 src_dir2 src_dir3 CC := g+我尝试过的一些变体: 1. librt 2. lrt 3. rt 4. librt devPackage lrt was not found in the pkg-configNo package 'lrt' found
我
因此,我想我需要将-lrt添加到构建命令中(gcc)。但是,现在它不能在OS X中编译:ld: library not found for -lrt。如果没有,如何使用特定于操作系统的命令创建Makefile?我没有使用autoconf或任何类似的东西。Makefile相当复杂,但以下是可操作的部分:# In this line, remove -lrt to compile on OS XCFLA