On Fri, Jul 12, 2013 at 12:24 AM, Aaron W.Hsu <arcf...@sacrideo.us> wrote:
>
> I have a Git fast-export that comes in at around 322MB in size or
> thereabouts. I am running the Windows version of Fossil from 2013-06.
> I run the following from within PowerShell and get some funny output:
>
> C:\...> git fast-export --all | fossil import --git blah.fossil
> ]ad fast-import line: [AGS} -fPIC -shared -o $@ $<
>
> That ]ad line seems to be incorrect, as at the end of it I get no
> blan.fossil file. Can anyone tell me what I am doing wrong here?

I've checked the code again, and found out two things:

  1. The error message is mangled because it contains a CR character at
     the end (harmless bug).

  2. The only situation that, I think, leads to this error is a badly
     formatted, badly interpreted or mangled "data" command.  That is,
     the number of bytes declared do not match the actual content bytes.

Both of which make me suspicious about an automatic line-ending
conversion going on (LF to CRLF most likely).  What I don't really know
is who to blame.

Here are some more tests you can do to help the diagnosis:

  - Does the error happen quickly or it takes a while to show up?

  - Try the conversion WITHOUT a pipeline.  That is:

      git fast-export --all >my_export
      fossil import --git blah.fossil my_export

    Note the absence of redirection in the second command.

  - Take a look at the "my_export" file with a text editor or a pager
    looking for the same string ("${CFLAGS} -fPIC -shared -o $@"), then
    scroll back until you find a line that starts with "data " followed
    by a number.

    Then, extract the content from the "data" line until the end of the
    content (i.e. the whole contents of that particular version of your
    Makefile) and calculate its size in bytes.  If I'm correct the size
    of the Makefile content should approximately match:

        content_size = reported_size + linecount_in_content

Once this behaviour is confirmed, the next step is to look out for
guilty parties ;-)

Regards.

-- 
Isaac Jurado

"The noblest pleasure is the joy of understanding"
Leonardo da Vinci
_______________________________________________
fossil-users mailing list
fossil-users@lists.fossil-scm.org
http://lists.fossil-scm.org:8080/cgi-bin/mailman/listinfo/fossil-users

Reply via email to