Page 1 of 1

Windows Exe (made by link.lsp) could not read self exe-file.

Posted: Wed Feb 16, 2011 6:56 am
by unya
Hello,

Japanese (or CJK) may be environmental issues, UT8 version had problems with the execution.

1. executable (module link.lsp made from) will not run correctly from the Japanese path. Failure to read encrypted lisp code from self-execution file.
--> patch - self exeutable-filepath-name UTF-8 on startup.

2. Command Parameters (argv) is still MBCS. problem with main-args function as reference. Or some code to create and process, UTF8 must convert.
(main-args returns Character is MBCS)
--> changed main-args returns UTF8 string list on startup.

attached diff-file and the chaned file (protos.h, newlisp.c, win32-path.c).
base file is newlisp-10.3.0.

thanks,

Re: Windows Exe (made by link.lsp) could not read self exe-f

Posted: Wed Feb 16, 2011 12:32 pm
by Lutz
Thanks Unya, well done.

The merge is accessible here:

http://www.newlisp.org/downloads/develo ... nprogress/

Re: Windows Exe (made by link.lsp) could not read self exe-f

Posted: Thu Feb 17, 2011 4:06 pm
by unya
Thank you, Lutz.

"MBSC" is typo in CHANGES-10.3.1.txt, it's "MBCS".

Regards,

Re: Windows Exe (made by link.lsp) could not read self exe-f

Posted: Tue Apr 05, 2011 3:44 pm
by kosh
Hi Lutz.

A ifdef macro syntax errors found. [CentOS 5.5 x86_64]
(It is necessary to be likely to contact Ted Walther, because configure-alt is used..)

Code: Select all

$ ./configure-alt && make
...
make -f makefile_build
make[1]: Entering directory `/home/kosh/src/newlisp-10.3.1'
gcc -m64 -Wall -pedantic -Wno-long-long -Wno-strict-aliasing -O2 -c  -DNEWCONFIG newlisp.c
newlisp.c:629:27: error: operator '&&' has no right operand
make[1]: *** [newlisp.o] Error 1
make[1]: Leaving directory `/home/kosh/src/newlisp-10.3.1'
make: *** [default] Error 2
a patch file here:

Code: Select all

--- newlisp.orig.c 2011-04-02 23:32:01.000000000 +0900
+++ newlisp.c   2011-04-06 00:06:12.000000000 +0900
@@ -626,7 +626,9 @@
 initStacks();
 initDefaultInAddr(); 
 
-#if WIN_32 && SUPPORT_UTF8
+/* #if defined(WIN_32) && defined(SUPPORT_UTF8) */
+#ifdef WIN_32
+#ifdef SUPPORT_UTF8
  {
    /*
      command line parameter is MBCS.
@@ -644,7 +646,8 @@
      argv = argv_utf8 ;
    }
  }
-#endif
+#endif  /* SUPPORT_UTF8 */
+#endif  /* WIN_32 */
 mainArgsSymbol->contents = (UINT)getMainArgs(argv);
 
 if((errorReg = setjmp(errorJump)) != 0)