在MobaXterm上编译Poly / ML:ar u选项

问题描述 投票:1回答:1

我将在基于MobaXterm v11.1 cygwin的发行版上编译Poly / ML Standard ML编译器。做完后,我明白了

/bin/sh ./libtool  --tag=CC   --mode=link gcc  -O3 -fomit-frame-pointer -fstrict-aliasing -ffast-math -march=core2  -Wall -fexceptions   -o libffi_convenience.la  src/prep_cif.lo src/types.lo src/raw_api.lo src/java_raw_api.lo src/closures.lo      src/x86/ffi.lo src/x86/win32.lo
libtool: link: ar cru .libs/libffi_convenience.a src/.libs/prep_cif.o src/.libs/types.o src/.libs/raw_api.o src/.libs/java_raw_api.o src/.libs/closures.o src/x86/.libs/ffi.o src/x86/.libs/win32.o
ar: unknown option -- u
BusyBox v1.22.1 (2015-11-10 11:07:12    ) multi-call binary.

这里我有binutils / ar版本2.29.1。

在带有binutils / ar版本2.22.52的Fedora盒子上进行编译。

我将binutils 2.22.52下载到我的MobaXterm并尝试编译它,但我得到了与上面相同的错误消息:

ar cru libintl.a bindtextdom.o dcgettext.o dgettext.o gettext.o finddomain.o loadmsgcat.o localealias.o textdomain.o l10nflist.o explodename.o dcigettext.o dcngettext.o dngettext.o ngettext.o plural.o plural-exp.o localcharset.o relocatable.o localename.o log.o osdep.o intl-compat.o
ar: unknown option -- u

我看到两个可能的原因:

  • ar的u选项在版本2.22.52和2.29.1之间被弃用
  • MobaXterm使用Busybox,其中包含有限版本的ar

什么是真正的解释,我如何安装一个理解你的选项?

configure busybox ar polyml mobaxterm
1个回答
2
投票

在polyml源代码分发的libffi目录中,我用configure编辑了AR_FLAGS=cr,然后在该目录中的make经过,然后在主polyml目录中的make经历了。

幸运的是,u选项对生成的文件没有实际影响,仅在编译时:

   u   Normally, ar r... inserts all files listed into the archive.  If you would like to insert only
       those of the files you list that are newer than existing members of the same names, use this
       modifier.  The u modifier is allowed only for the operation r (replace).  In particular, the
       combination qu is not allowed, since checking the timestamps would lose any speed advantage
       from the operation q.
© www.soinside.com 2019 - 2024. All rights reserved.