YML解析错误

时间:2014-03-18 03:55:07

标签: ruby yaml

我正在尝试从ubutno编译windows的比特币客户端,但每次我尝试构建它时,我都会收到此错误:

/usr/lib/ruby/1.9.1/psych.rb:207:in `parse': (../bitcoin/contrib/gitian-descriptors/boost-win32.yml): could not find expected ':' while scanning a simple key at line 21 column 1 (Psych::SyntaxError)

我已经对它进行了一些调查,发现这通常是由YML文件中的一些拼写引起的。但是我对ruby几乎一无所知,希望你们中的一些人可以帮我解决这个问题。

我的yml文件是:

---
name: "boost"
suites:
- "lucid"
architectures:
- "i386"
packages: 
- "mingw32"
- "faketime"
- "zip"
reference_datetime: "2011-01-30 00:00:00"
remotes: []
files:
- "boost_1_49_0.tar.bz2"
script: |
  TMPDIR="$HOME/tmpdir"
  mkdir -p $TMPDIR/bin/$GBUILD_BITS $TMPDIR/include
  tar xjf boost_1_49_0.tar.bz2
  cd boost_1_49_0
  echo "--- tmp_dir_helpers.orig.hpp    2012-06-10 01:39:25.403268210 +0200
+++ tmp_dir_helpers.hpp 2012-06-10 01:41:14.653823479 +0200
@@ -19,9 +19,9 @@
 #include <string>

 #if defined(BOOST_INTERPROCESS_WINDOWS)
-   //#define BOOST_INTERPROCESS_HAS_WINDOWS_KERNEL_BOOTTIME
-   //#define BOOST_INTERPROCESS_HAS_KERNEL_BOOTTIME
-   //#include <boost/interprocess/detail/win32_api.hpp>
+   #define BOOST_INTERPROCESS_HAS_WINDOWS_KERNEL_BOOTTIME
+   #define BOOST_INTERPROCESS_HAS_KERNEL_BOOTTIME
+   #include <boost/interprocess/detail/win32_api.hpp>
 #elif defined(__FreeBSD__) || defined(__NetBSD__) || defined(__OpenBSD__) || defined(__APPLE__)
    //#include <sys/sysctl.h>
    //#if defined(CTL_KERN) && defined (KERN_BOOTTIME)" > useboottime.patch
  patch boost/interprocess/detail/tmp_dir_helpers.hpp useboottime.patch
  echo "using gcc : 4.4 : i586-mingw32msvc-g++
        :
        <rc>i586-mingw32msvc-windres
        <archiver>i586-mingw32msvc-ar
        <cxxflags>-frandom-seed=boost1
  ;" > user-config.jam
  ./bootstrap.sh --without-icu
  ./bjam toolset=gcc target-os=windows threadapi=win32 threading=multi variant=release link=static --user-config=user-config.jam --without-mpi --without-python -sNO_BZIP2=1 -sNO_ZLIB=1 --layout=tagged --build-type=complete $MAKEOPTS stage
  for lib in chrono date_time exception filesystem graph iostreams math_c99f math_c99l math_c99 math_tr1f math_tr1l math_tr1 prg_exec_monitor program_options random regex serialization signals system test_exec_monitor thread_win32 unit_test_framework wave wserialization; do
      mkdir $lib
      (cd $lib ; ar xf ../stage/lib/libboost_${lib}-mt-s.a)
      mv $lib $TMPDIR/bin/$GBUILD_BITS
  done
  cp -a boost $TMPDIR/include
  cd $TMPDIR
  export LD_PRELOAD=/usr/lib/faketime/libfaketime.so.1
  export FAKETIME=$REFERENCE_DATETIME
  zip -r boost-win32-1.49.0-gitian2.zip *
  cp boost-win32-1.49.0-gitian2.zip $OUTDIR

提前谢谢你,如果我要问的话,很抱歉:)

编辑: 顺便说一句,我使用的是Ruby 1.9.1,而我的机器正在运行Ubuntu 13.0

0 个答案:

没有答案