MacPortsでJavascript-lintのビルドに失敗する
MacPorts1.8.2でjavascript-lint@0.3.0_0 をインストールしようと
sudo port install javascript-lint +universal
としたところ、以下のようなエラーがでました。
---> Computing dependencies for javascript-lint ---> Building javascript-lint Error: Target org.macports.build returned: shell command " cd "/opt/local/var/macports/build/_opt_local_var_macports_sources_rsync.macports.org_release_ports_lang_javascript-lint/work/jsl-0.3.0/src" && /usr/bin/make -f Makefile.ref " returned error 2 Command output: cat: ../../dist/Darwin_DBG.OBJ/nspr/Version: No such file or directorycd editline; /usr/bin/make -f Makefile.ref all make[1]: Nothing to be done for `all'.cd fdlibm; /usr/bin/make -f Makefile.ref all make[1]: Nothing to be done for `all'. /usr/bin/make -f Makefile.ref Darwin_DBG.OBJ/libjs.a Darwin_DBG.OBJ/libjs.so Darwin_DBG.OBJ/jsl Darwin_DBG.OBJ/jsautocfg.h Darwin_DBG.OBJ/jscpucfg Darwin_DBG.OBJ/jscpucfg.o Darwin_DBG.OBJ/jsmathtemp.o cat: ../../dist/Darwin_DBG.OBJ/nspr/Version: No such file or directory make[1]: Circular jscpucfg.h <- Darwin_DBG.OBJ/jsautocfg.h dependency dropped. make[1]: Circular Darwin_DBG.OBJ/jsautocfg.h <- Darwin_DBG.OBJ/jsautocfg.h dependency dropped. cc -o Darwin_DBG.OBJ/jsprf.o -c -Wall -Wno-format -g -DXP_UNIX -DSVR4 -DSYSV -D_BSD_SOURCE -DPOSIX_SOURCE -DDARWIN -DX86_LINUX -DDEBUG -DDEBUG_root -DEDITLINE -IDarwin_DBG.OBJ jsprf.c jsprf.c: In function 'BuildArgArray': jsprf.c:620: error: incompatible types in assignment make[1]: *** [Darwin_DBG.OBJ/jsprf.o] Error 1 make: *** [all] Error 2 Error: Status 1 encountered during processing. Before reporting a bug, first run the command again with the -d flag to get complete output.
どうしたのかなーと思いましたが、解決法がフォーラムにありました。
ここに書いてあるとおり、
couchdbx-core/patch-jsprf.c at ff47372552d10df00d74cb7989dfed4a19a6040d · janl/couchdbx-core · GitHub
このパッチをあてればちゃんと無事にインストールされました。