hth313 / Calypsi-tool-chains

Overview of the Calypsi tool chain and open source support packages
16 stars 0 forks source link

rpncomp fails on .import on Windows System #2

Open mjakuipers opened 2 years ago

mjakuipers commented 2 years ago

A short RPN program will compile correctly. When adding a .import 41CX (actually all modexport files fail). Using a non-existing .modexport file gives another error. Issue seen under Windows 10, rpncomp is run is a CMD window.

RPN file: 
; test program for failing .import
.import 41CX
 01  LBL "TEST"
 02  END

Command line and error message:

C:\Users\mkuipers\Documents\Development\CalypsiNut\example\Mein>rpncomp -l test.rpn

fatal error: unsupported protocol in URI "C:\\Program Files (x86)\\Calypsi-nut\\module-export\\41CX.modexport"

fatal error: document unpickling failed
no more contents to be read
context:    element "/"
attributes:  status="3" module="getContentsFromDoc" transfer-URI="C:/Program%20Files%20(x86)...
cannot parse XROM export file "C:\Program Files (x86)\Calypsi-nut\module-export\41CX.modexport"
Terminating due to errors
hth313 commented 2 years ago

This problem is caused by the XML parser confusing an absolute Windows path for a protocol. To work around it use the -I option and a path what does not contain a drive letter. If you are on the same drive you can use -I \Program Files (x86)\Calypsi-nut\module-export. If you are on another drive, copy the module-export directory to the same drive and use a suitable path to it without a drive letter.

To fix it for real I will need to fork and path the XML parser and patch it, but that is a bit of work so it may take some time.

References: https://github.com/UweSchmidt/hxt/issues/76 https://github.com/jgm/pandoc/issues/4836

mjakuipers commented 2 years ago

Thanks Hakan,

This seems to fix the problem. Complication under Windows is also the space in the directory tree with the -I option, so I moved the module exports elsewhere

Groeten,

Meindert

Van: Håkan Thörngren @.> Verzonden: zondag 8 mei 2022 02:02 Aan: hth313/Calypsi-tool-chains @.> CC: mjakuipers @.>; Author @.> Onderwerp: Re: [hth313/Calypsi-tool-chains] rpncomp fails on .import on Windows System (Issue #2)

This problem is caused by the XML parser confusing an absolute Windows path for a protocol. To work around it use the -I option and a path what does not contain a drive letter. If you are on the same drive you can use -I \Program Files (x86)\Calypsi-nut\module-export. If you are on another drive, copy the module-export directory to the same drive and use a suitable path to it without a drive letter.

To fix it for real I will need to fork and path the XML parser and patch it, but that is a bit of work so it may take some time.

References: UweSchmidt/hxt#76 https://github.com/UweSchmidt/hxt/issues/76 jgm/pandoc#4836 https://github.com/jgm/pandoc/issues/4836

— Reply to this email directly, view it on GitHub https://github.com/hth313/Calypsi-tool-chains/issues/2#issuecomment-1120319378 , or unsubscribe https://github.com/notifications/unsubscribe-auth/AQXFALEWYDCGEZLKOWVSQADVI4AADANCNFSM5VKSZOVA . You are receiving this because you authored the thread. https://github.com/notifications/beacon/AQXFALFKLYIUKQ3P755QFN3VI4AADA5CNFSM5VKSZOVKYY3PNVWWK3TUL52HS4DFVREXG43VMVBW63LNMVXHJKTDN5WW2ZLOORPWSZGOILDLPEQ.gif Message ID: @. @.> >