<html>
  <head>
    <meta content="text/html; charset=ISO-8859-1"
      http-equiv="Content-Type">
  </head>
  <body bgcolor="#FFFFFF" text="#000000">
    Hi,<br>
    <br>
    Place them right after the "main(Args) ->" line and it should
    work.<br>
    <br>
    I see nothing wrong with the output you pasted below.<br>
    <br>
    Lukas<br>
    <br>
    On 19/06/12 16:16, Barry Hawkins wrote:
    <blockquote
cite="mid:CAAN2i5PXL-q6xnTyFsWZnv-eYUm2fwubRFm1tErpnyuW8NXu=Q@mail.gmail.com"
      type="cite">Lukas,
      <div>Hello, and thanks for your response. Placing those two lines
        just after the comment blocks and just before the "main(Args)
        ->" line, but it results in a syntax error:</div>
      <div><br>
      </div>
      <div>
        <div>otp_src_R15B01 barryh$ make install-docs</div>
        <div>ERL_TOP=/Users/barryh/otp_src_R15B01
          INSTALLROOT=/Users/barryh/lib/erlang
          PATH=/Users/barryh/otp_src_R15B01/bootstrap/bin:${PATH} \</div>
        <div><span class="Apple-tab-span" style="white-space:pre"> </span>make
          RELEASE_ROOT=/Users/barryh/lib/erlang release_docs</div>
        <div>PATH=/Users/barryh/otp_src_R15B01/bin:${PATH} escript
          /Users/barryh/otp_src_R15B01/lib/erl_docgen/priv/bin/xref_mod_app.escript
          -topdir /Users/barryh/otp_src_R15B01 -outfile
          /Users/barryh/otp_src_R15B01/make/i386-apple-darwin11.4.0/mod2app.xml</div>
        <div>/Users/barryh/otp_src_R15B01/lib/erl_docgen/priv/bin/xref_mod_app.escript:42:
          syntax error before: ':'</div>
        <div>escript: There were compilation errors.</div>
        <div>make[1]: *** [mod2app] Error 127</div>
        <div>make: *** [install-docs] Error 2</div>
        <div><br>
        </div>
        <div>Being new to Erlang, there may be some context I'm missing.
          Is there a particular function in which I need to embed those
          directives? In the meantime I have executed those two
          directives in the shell in the event that would be partially
          helpful:</div>
        <div><br>
        </div>
        <div>
          <div>$ erl</div>
          <div>Erlang R15B01 (erts-5.9.1) [source] [smp:8:8]
            [async-threads:0] [hipe] [kernel-poll:false]</div>
          <div><br>
          </div>
          <div>Eshell V5.9.1  (abort with ^G)</div>
          <div>1> erlang:display({rootdir,code:root_dir()}).</div>
          <div>{rootdir,"/Users/barryh/lib/erlang"}</div>
          <div>true</div>
          <div>2> erlang:display({paths,code:get_path()}).</div>
          <div>{paths,[".","/Users/barryh/lib/erlang/lib/kernel-2.15.1/ebin","/Users/barryh/lib/erlang/lib/stdlib-1.18.1/ebin","/Users/barryh/lib/erlang/lib/xmerl-1.3.1/ebin","/Users/barryh/lib/erlang/lib/wx-0.99.2/ebin","/Users/barryh/lib/erlang/lib/webtool-0.8.9.1/ebin","/Users/barryh/lib/erlang/lib/typer-0.9.3/ebin","/Users/barryh/lib/erlang/lib/tv-2.1.4.9/ebin","/Users/barryh/lib/erlang/lib/tools-2.6.7/ebin","/Users/barryh/lib/erlang/lib/toolbar-1.4.2.2/ebin","/Users/barryh/lib/erlang/lib/test_server-3.5.1/ebin","/Users/barryh/lib/erlang/lib/syntax_tools-1.6.8/ebin","/Users/barryh/lib/erlang/lib/ssl-5.0.1/ebin","/Users/barryh/lib/erlang/lib/ssh-2.1/ebin","/Users/barryh/lib/erlang/lib/snmp-4.22/ebin","/Users/barryh/lib/erlang/lib/sasl-2.2.1/ebin","/Users/barryh/lib/erlang/lib/runtime_tools-1.8.8/ebin","/Users/barryh/lib/erlang/lib/reltool-0.6/ebin","/Users/barryh/lib/erlang/lib/public_key-0.15/ebin","/Users/barryh/lib/erlang/lib/pman-2.7.1.2/ebin","/Users/barryh/lib/erlan!
 g/lib/perc
ept-0.8.6.1/ebin","/Users/barryh/lib/erlang/lib/parsetools-2.0.7/ebin","/Users/barryh/lib/erlang/lib/otp_mibs-1.0.7/ebin","/Users/barryh/lib/erlang/lib/os_mon-2.2.9/ebin","/Users/barryh/lib/erlang/lib/orber-3.6.24/ebin","/Users/barryh/lib/erlang/lib/odbc-2.10.12/ebin","/Users/barryh/lib/erlang/lib/observer-1.1/ebin","/Users/barryh/lib/erlang/lib/mnesia-4.7/ebin","/Users/barryh/lib/erlang/lib/megaco-3.16.0.1/ebin","/Users/barryh/lib/erlang/lib/jinterface-1.5.6","/Users/barryh/lib/erlang/lib/inviso-0.6.3/ebin","/Users/barryh/lib/erlang/lib/inets-5.9/ebin","/Users/barryh/lib/erlang/lib/ic-4.2.30/ebin","/Users/barryh/lib/erlang/lib/hipe-3.9.1/ebin","/Users/barryh/lib/erlang/lib/gs-1.5.15.1/ebin","/Users/barryh/lib/erlang/lib/eunit-2.2.2/ebin","/Users/barryh/lib/erlang/lib/et-1.4.4.1/ebin","/Users/barryh/lib/erlang/lib/erts-5.9.1/ebin","/Users/barryh/lib/erlang/lib/erl_interface-3.7.7","/Users/barryh/lib/erlang/lib/erl_docgen-0.3.1/ebin","/Users/barryh/lib/erlang/lib/eldap-1.0/eb!
 in","/User
s/barryh/lib/erlang/lib/edoc-0.7.9.1/ebin","/Users/barryh/lib/erlang/lib/diameter-1.1/ebin","/Users/barryh/lib/erlang/lib/dialyzer-2.5.1/ebin","/Users/barryh/lib/erlang/lib/debugger-3.2.8/ebin","/Users/barryh/lib/erlang/lib/crypto-2.1/ebin","/Users/barryh/lib/erlang/lib/cosTransactions-1.2.12/ebin","/Users/barryh/lib/erlang/lib/cosTime-1.1.12/ebin","/Users/barryh/lib/erlang/lib/cosProperty-1.1.15/ebin","/Users/barryh/lib/erlang/lib/cosNotification-1.1.18/ebin","/Users/barryh/lib/erlang/lib/cosFileTransfer-1.1.13/ebin","/Users/barryh/lib/erlang/lib/cosEventDomain-1.1.12/ebin","/Users/barryh/lib/erlang/lib/cosEvent-2.1.12/ebin","/Users/barryh/lib/erlang/lib/compiler-4.8.1/ebin","/Users/barryh/lib/erlang/lib/common_test-1.6.1/ebin","/Users/barryh/lib/erlang/lib/asn1-1.7/ebin","/Users/barryh/lib/erlang/lib/appmon-2.1.14.1/ebin"]}</div>
          <div>true</div>
        </div>
        <div><br>
        </div>
        <div>Regards,</div>
        <div>-- </div>
        <div>Barry</div>
        <br>
        <div class="gmail_quote">On Mon, Jun 18, 2012 at 6:24 AM, Lukas
          Larsson <span dir="ltr"><<a moz-do-not-send="true"
              href="mailto:lukas@erlang.org" target="_blank">lukas@erlang.org</a>></span>
          wrote:<br>
          <blockquote class="gmail_quote" style="margin:0 0 0
            .8ex;border-left:1px #ccc solid;padding-left:1ex">
            <div bgcolor="#FFFFFF" text="#000000"> Hello,<br>
              <br>
              Unfortunately I cannot reproduce your error. Could you try
              to insert this into the beginning
              /Users/barryh/otp_src_R15B01/lib/erl_docgen/priv/bin/xref_mod_app.escript

              and report back with your findings?<br>
              <br>
              erlang:display({rootdir,code:root_dir()}),<br>
              erlang:display({paths,code:get_path()}),<br>
              <br>
              Lukas
              <div>
                <div class="h5"><br>
                  <br>
                  On 15/06/12 16:52, Barry Hawkins wrote: </div>
              </div>
              <blockquote type="cite">
                <div>
                  <div class="h5">
                    <div>Summary: A local build and install from source
                      for Erlang R15B01 succeeds, 'make docs' succeeds,
                      but the subsequent 'make install-docs' fails.</div>
                    Release: R15B01
                    <div>Operating System: Mac OS X Lion 10.7.4</div>
                    <div><br>
                    </div>
                    <div>Steps to Reproduce:</div>
                    <div>
                      <div>$ curl -O <a moz-do-not-send="true"
                          href="http://www.erlang.org/download/otp_src_R15B01.tar.gz"
                          target="_blank">http://www.erlang.org/download/otp_src_R15B01.tar.gz</a></div>
                      <div>$ tar xzvf otp_src_R15B01.tar.gz</div>
                      <div>$ cd otp_src_R15B01</div>
                    </div>
                    <div><br>
                    </div>
                    <div>Per instructions at <a moz-do-not-send="true"
href="http://www.erlang.org/doc/installation_guide/INSTALL.html#Building-a-fast-Erlang-VM-on-Mac-OS-Lion"
                        target="_blank">http://www.erlang.org/doc/installation_guide/INSTALL.html#Building-a-fast-Erlang-VM-on-Mac-OS-Lion</a>
                      install MacPorts GCC 4.5.</div>
                    <div><br>
                    </div>
                    <div>$ sudo port install gcc45 +universal</div>
                    <div><br>
                    </div>
                    <div>Install wxWidgets 2.8.12 and FOP 1.0 from
                      MacPorts to satisfy dependencies.</div>
                    <div><br>
                    </div>
                    <div>
                      <div>$ sudo port install wxwidgets</div>
                      <div>$ which wx-config </div>
                      <div>/opt/local/bin/wx-config</div>
                    </div>
                    <div><br>
                    </div>
                    <div>
                      <div>$ sudo port install fop</div>
                      <div>$ which fop</div>
                      <div>/opt/local/bin/fop</div>
                    </div>
                    <div><br clear="all">
                      <div>otp_src_R15B01 barryh$
                        PATH=/usr/local/bin:$PATH
                        CC=/opt/local/bin/gcc-mp-4.5
                        CXX=/opt/local/bin/g++-mp-4.5 ./configure
                        --enable-m32-build --prefix=$HOME</div>
                      <div>otp_src_R15B01 barryh$ make install</div>
                      <div>
                        <div>otp_src_R15B01 barryh$ which erl</div>
                        <div>/Users/barryh/bin/erl</div>
                      </div>
                      <div><br>
                      </div>
                      <div>With a successful installation of the system,
                        proceeding to install the documentation per
                        instructions at <a moz-do-not-send="true"
href="http://www.erlang.org/doc/installation_guide/INSTALL.html#The-ErlangOTP-Documentation_How-to-Build-the-Documentation"
                          target="_blank">http://www.erlang.org/doc/installation_guide/INSTALL.html#The-ErlangOTP-Documentation_How-to-Build-the-Documentation</a></div>
                      <div><br>
                      </div>
                      <div>otp_src_R15B01 barryh$ export
                        PATH=$HOME/lib/erlang/bin:$PATH</div>
                      <div>
                        <div>otp_src_R15B01 barryh$ echo $PATH</div>
                        <div>/Users/barryh/lib/erlang/bin:/Users/barryh/bin:/opt/local/bin:/opt/local/sbin:/Users/barryh/play-2.0.1:/Users/barryh/scala/bin:/Library/Frameworks/Python.framework/Versions/3.2/bin:/usr/bin:/bin:/usr/sbin:/sbin:/usr/local/bin:/usr/X11/bin</div>
                      </div>
                      <div>
                        <div>otp_src_R15B01 barryh$ export
                          FOP_OPTS="-Xmx8192m"</div>
                        <div>otp_src_R15B01 barryh$ make docs</div>
                      </div>
                      <div>
                        <div>otp_src_R15B01 barryh$ make install-docs</div>
                        <div>ERL_TOP=/Users/barryh/otp_src_R15B01
                          INSTALLROOT=/Users/barryh/lib/erlang
                          PATH=/Users/barryh/otp_src_R15B01/bootstrap/bin:${PATH}
                          \</div>
                        <div><span style="white-space:pre-wrap"> </span>make

                          RELEASE_ROOT=/Users/barryh/lib/erlang
                          release_docs</div>
                        <div>PATH=/Users/barryh/otp_src_R15B01/bin:${PATH}
                          escript
                          /Users/barryh/otp_src_R15B01/lib/erl_docgen/priv/bin/xref_mod_app.escript

                          -topdir /Users/barryh/otp_src_R15B01 -outfile
/Users/barryh/otp_src_R15B01/make/i386-apple-darwin11.4.0/mod2app.xml</div>
                        <div>escript: exception error: undefined
                          function xmerl:export_simple/2</div>
                        <div>  in function  erl_eval:do_apply/6
                          (erl_eval.erl, line 572)</div>
                        <div>  in call from erl_eval:expr/5
                          (erl_eval.erl, line 367)</div>
                        <div>  in call from erl_eval:exprs/5
                          (erl_eval.erl, line 118)</div>
                        <div>  in call from erl_eval:local_func/5
                          (erl_eval.erl, line 470)</div>
                        <div>  in call from escript:interpret/4
                          (escript.erl, line 754)</div>
                        <div>  in call from escript:start/1
                          (escript.erl, line 277)</div>
                        <div>  in call from init:start_it/1 </div>
                        <div>make[1]: *** [mod2app] Error 127</div>
                        <div>make: *** [install-docs] Error 2</div>
                      </div>
                      <div><br>
                      </div>
                      <div>Comments:</div>
                      <div>After some searching, it seems a similar
                        issue has been encountered before. In
                        particular, there were some reports following
                        the release of R14B02 in March 2011, with
                        commentary confirming the behavior on Ubuntu,
                        CentOS, and Mac OS X. Here are links to the
                        start of the related threads, one in
                        erlang-questions and the other in erlang-bugs:</div>
                      <div><br>
                      </div>
                      <div><a moz-do-not-send="true"
href="http://erlang.org/pipermail/erlang-questions/2011-March/057024.html"
                          target="_blank">http://erlang.org/pipermail/erlang-questions/2011-March/057024.html</a></div>
                      <div><a moz-do-not-send="true"
                          href="http://erlang.org/pipermail/erlang-bugs/2011-March/002247.html"
                          target="_blank">http://erlang.org/pipermail/erlang-bugs/2011-March/002247.html</a></div>
                      <div><br>
                      </div>
                      <div>I confirmed the presence of xmerl-X.X.X in
                        the installation's lib directory:</div>
                      <div><br>
                      </div>
                      <div>
                        <div>$ ls -Fla
                          /Users/barryh/lib/erlang/lib/xmerl-1.3.1/</div>
                        <div>total 0</div>
                        <div>drwxr-xr-x   5 barryh  staff   170 Jun 14
                          13:18 ./</div>
                        <div>drwxr-xr-x  58 barryh  staff  1972 Jun 14
                          13:18 ../</div>
                        <div>drwxr-xr-x  37 barryh  staff  1258 Jun 14
                          13:18 ebin/</div>
                        <div>drwxr-xr-x   5 barryh  staff   170 Jun 14
                          13:18 include/</div>
                        <div>drwxr-xr-x  42 barryh  staff  1428 Jun 14
                          13:18 src/</div>
                        <div><br>
                        </div>
                        <div>I also confirmed that the xmerl module
                          could be loaded in my shell using a small
                          example from <a moz-do-not-send="true"
href="http://stackoverflow.com/questions/1227241/building-an-xmerl-document-in-erlang"
                            target="_blank">http://stackoverflow.com/questions/1227241/building-an-xmerl-document-in-erlang</a>.</div>
                        <div><br>
                        </div>
                        <div>
                          <div>> Data =
                            {myNode,[{foo,"Foo"},{bar,"Bar"}], []}.</div>
                          <div>{myNode,[{foo,"Foo"},{bar,"Bar"}],[]}</div>
                          <div>>
                            lists:flatten(xmerl:export_simple([Data],
                            xmerl_xml)).</div>
                          <div>"<?xml version=\"1.0\"?><myNode
                            foo=\"Foo\" bar=\"Bar\"/>"</div>
                        </div>
                      </div>
                      <div>
                        <div>> m().</div>
                        <div>Module                File</div>
                        <div>application          
                          /Users/barryh/lib/erlang/lib/kernel-2.15.1/ebin/application.beam</div>
                      </div>
                      <div>...</div>
                      <div>
                        <div>xmerl                
                          /Users/barryh/lib/erlang/lib/xmerl-1.3.1/ebin/xmerl.beam</div>
                        <div>xmerl_lib            
                          /Users/barryh/lib/erlang/lib/xmerl-1.3.1/ebin/xmerl_lib.beam</div>
                        <div>xmerl_xml            
                          /Users/barryh/lib/erlang/lib/xmerl-1.3.1/ebin/xmerl_xml.beam</div>
                      </div>
                      <div>...</div>
                      <div><br>
                      </div>
                      <div>I tried changing "#!/usr/bin/env escript" to
                        "#!/Users/barryh/bin/escript" as mentioned in <a
                          moz-do-not-send="true"
href="http://erlang.org/pipermail/erlang-questions/2011-March/057072.html"
                          target="_blank">http://erlang.org/pipermail/erlang-questions/2011-March/057072.html</a>,
                        but the behavior remained the same.</div>
                      <div><br>
                      </div>
                      <div>I also tried adding the source's bin
                        directory to $PATH instead of the installed
                        system's bin directory, but the behavior did not
                        change:</div>
                      <div><br>
                      </div>
                      <div>
                        <div>otp_src_R15B01 barryh$ export
                          PATH=/Users/barryh/otp_src_R15B01/bin:$PATH</div>
                        <div>otp_src_R15B01 barryh$ echo $PATH</div>
                        <div>/Users/barryh/otp_src_R15B01/bin:/Users/barryh/bin:/opt/local/bin:/opt/local/sbin:/Users/barryh/play-2.0.1:/Users/barryh/scala/bin:/Library/Frameworks/Python.framework/Versions/3.2/bin:/usr/bin:/bin:/usr/sbin:/sbin:/usr/local/bin:/usr/X11/bin</div>
                        <div>otp_src_R15B01 barryh$ make install-docs</div>
                        <div>ERL_TOP=/Users/barryh/otp_src_R15B01
                          INSTALLROOT=/Users/barryh/lib/erlang
                          PATH=/Users/barryh/otp_src_R15B01/bootstrap/bin:${PATH}
                          \</div>
                        <div><span style="white-space:pre-wrap"> </span>make

                          RELEASE_ROOT=/Users/barryh/lib/erlang
                          release_docs</div>
                        <div>PATH=/Users/barryh/otp_src_R15B01/bin:${PATH}
                          escript
                          /Users/barryh/otp_src_R15B01/lib/erl_docgen/priv/bin/xref_mod_app.escript

                          -topdir /Users/barryh/otp_src_R15B01 -outfile
/Users/barryh/otp_src_R15B01/make/i386-apple-darwin11.4.0/mod2app.xml</div>
                        <div>escript: exception error: undefined
                          function xmerl:export_simple/2</div>
                        <div>  in function  erl_eval:do_apply/6
                          (erl_eval.erl, line 572)</div>
                        <div>  in call from erl_eval:expr/5
                          (erl_eval.erl, line 367)</div>
                        <div>  in call from erl_eval:exprs/5
                          (erl_eval.erl, line 118)</div>
                        <div>  in call from erl_eval:local_func/5
                          (erl_eval.erl, line 470)</div>
                        <div>  in call from escript:interpret/4
                          (escript.erl, line 754)</div>
                        <div>  in call from escript:start/1
                          (escript.erl, line 277)</div>
                        <div>  in call from init:start_it/1 </div>
                        <div>make[1]: *** [mod2app] Error 127</div>
                        <div>make: *** [install-docs] Error 2</div>
                      </div>
                      <div><br>
                      </div>
                      <div>Thanks in advance for any insight one may be
                        able to provide, and apologies if I have
                        overlooked some issue.</div>
                      <div><br>
                      </div>
                      <div>Regards,</div>
                      -- <br>
                      Barry Hawkins<br>
                      twitter: @barryhawkins<br>
                      blog: <a moz-do-not-send="true"
                        href="http://barryhawkins.com/blog/"
                        target="_blank">http://barryhawkins.com/blog/</a><br>
                      linkedin: <a moz-do-not-send="true"
                        href="http://www.linkedin.com/in/barryhawkins"
                        target="_blank">http://www.linkedin.com/in/barryhawkins</a><br>
                      <br>
                    </div>
                    <br>
                    <fieldset></fieldset>
                    <br>
                  </div>
                </div>
                <pre>_______________________________________________
erlang-bugs mailing list
<a moz-do-not-send="true" href="mailto:erlang-bugs@erlang.org" target="_blank">erlang-bugs@erlang.org</a>
<a moz-do-not-send="true" href="http://erlang.org/mailman/listinfo/erlang-bugs" target="_blank">http://erlang.org/mailman/listinfo/erlang-bugs</a>
</pre>
              </blockquote>
            </div>
            <br>
            _______________________________________________<br>
            erlang-bugs mailing list<br>
            <a moz-do-not-send="true"
              href="mailto:erlang-bugs@erlang.org">erlang-bugs@erlang.org</a><br>
            <a moz-do-not-send="true"
              href="http://erlang.org/mailman/listinfo/erlang-bugs"
              target="_blank">http://erlang.org/mailman/listinfo/erlang-bugs</a><br>
            <br>
          </blockquote>
        </div>
        <br>
        <br clear="all">
        <div><br>
        </div>
        -- <br>
        Barry Hawkins<br>
        twitter: @barryhawkins<br>
        blog: <a moz-do-not-send="true"
          href="http://barryhawkins.com/blog/" target="_blank">http://barryhawkins.com/blog/</a><br>
        linkedin: <a moz-do-not-send="true"
          href="http://www.linkedin.com/in/barryhawkins" target="_blank">http://www.linkedin.com/in/barryhawkins</a><br>
        <br>
      </div>
      <br>
      <fieldset class="mimeAttachmentHeader"></fieldset>
      <br>
      <pre wrap="">_______________________________________________
erlang-bugs mailing list
<a class="moz-txt-link-abbreviated" href="mailto:erlang-bugs@erlang.org">erlang-bugs@erlang.org</a>
<a class="moz-txt-link-freetext" href="http://erlang.org/mailman/listinfo/erlang-bugs">http://erlang.org/mailman/listinfo/erlang-bugs</a>
</pre>
    </blockquote>
  </body>
</html>