1、ntp源码包:ntp-dev-4.3.91.tar.gz(可下载地址:http://www.ntp.org/downloads.html)
2、交叉编译工具:arm-linux-gnueabihf-gcc 解压ntp源码包到指定目录 tar -zxvf ntp-dev-4.3.91.tar.gz
进入刚解压目录,并配置cd ntp-dev-4.3.91,在ntpd/ntp_loopfilter.c中增加下面的宏定义
#ifndef MOD_NANO
#define MOD_NANO 0x2000
#endif
./configure --prefix=$PWD/install --exec-prefix=$PWD/install --host=arm-none-linux-gnueabi CC=arm-none-linux-gnueabi-gcc
出现错误:
checking for pthread_kill_other_threads_np... no
checking for LinuxThreads implementation... no
checking for LinuxThreads consistency... no
checking if pthread_create() works... yes
checking if select yields when using pthreads... cross
con