Author Topic: SB64.AppImage  (Read 939 times)

Offline John

  • Forum Support / SB Dev
  • Posts: 2191
    • ScriptBasic Open Source Project
Re: SB64.AppImage
« Reply #15 on: October 07, 2018, 12:10:40 PM »
Not as kind as GCC under Linux.  :(

Online AIR

  • RETIRED
  • BASIC Developer
  • Posts: 410
Re: SB64.AppImage
« Reply #16 on: October 07, 2018, 12:29:18 PM »
It's a Windows-compatibility thing.

TCC has the same "issue" under Windows...as does PellesC.

« Last Edit: October 07, 2018, 12:57:26 PM by AIR »

Offline John

  • Forum Support / SB Dev
  • Posts: 2191
    • ScriptBasic Open Source Project
Re: SB64.AppImage
« Reply #17 on: October 07, 2018, 01:07:06 PM »
I'm trying to get things going with the VB6 OCX DLL Forms project under 32 bit Windows before taking anything else on with the Windows platform. I was hoping Mike might have some interest getting SB64 fine tuned on Windows 64.

I'm also in the process of moving the Script BASIC project to a repository and converting Peter's HTML docs to Markup.

My plate is full and help from members of the dev team (you, Mike, Tom and others) to get SB professionally distributable is the end goal.

I believe if Script BASIC were presented in a professional format, the BASIC would sell itself.
« Last Edit: October 07, 2018, 02:43:52 PM by John »

Offline Mike Lobanovsky

  • ON-HOLD
  • BASIC Developer
  • Posts: 216
Re: SB64.AppImage
« Reply #18 on: October 07, 2018, 02:19:34 PM »
Just FYI: (without any commitments on my behalf)

AFAIK Eros' every thinBasic standalone "executable" is in fact a self-extracting archive (he calls it "a bundle") of several modules: TB engine and its dependencies (dll helper modules like e.g. TB's O2 and/or COM and/or GUI and/or something else as needed), (optionally obfuscated) script to execute, and script dependencies (yet more non-system dll modules) if any. I think that's a pretty close match to what you're trying to achieve here.

Once un-archived in-place, the extra files are marked as hidden to avoid being displayed in Explorer, the script is run by the engine, and when the app execution is completed, the hidden files are all deleted not to litter the folder where the "executable" resides. However sometimes when the app terminates abnormally, the hidden files may fail to be deleted and would stay in the folder till the next time the app runs. Then the older hidden files are overwritten with newer copies, and if this time the app terminates successfully, the folder gets completely clean of all the payload as originally intended.

Probably Eros could elaborate some more on this setup if what I'm saying is wrong and/or incomplete.
Mike
____________________________________________________________________
(3.6GHz Intel Core i5, 16GB RAM / nVidia GTX 1060Ti , 6GB VRAM / x64 Win7 Ult.)

Offline Mike Lobanovsky

  • ON-HOLD
  • BASIC Developer
  • Posts: 216
Re: SB64.AppImage
« Reply #19 on: October 07, 2018, 02:45:36 PM »
Hi Armando,

I'm glad to see you here again. :)

TCC has the same "issue" under Windows...as does PellesC.

That's not an "issue", that's a Windows "feature" and when in Rome, you're supposed to do as the Romans do. :D

In fact, gcc can be made to emit Linuxoid-style 10-byte long doubles (and natural long integers) under x64 Windows. However this is not what Windows expects from its 64-bit user code, therefore:
  • gcc FPU calc will not be compatible with the other system components and user apps and libraries;
  • gcc will have to link its run time paraphernalia statically into the user app rather than use standard system msvcrt.dll and similar; and
  • gcc will have to link its own formatted IO routines statically into the user app as well and override the app's calls to their native Windows counterparts even if they (the calls) are hardcoded in the app explicitly.
So, it's only natural that gcc becomes less friendly to the user who's trying to deploy alien calc in MS Windows environment. :)
Mike
____________________________________________________________________
(3.6GHz Intel Core i5, 16GB RAM / nVidia GTX 1060Ti , 6GB VRAM / x64 Win7 Ult.)

Offline John

  • Forum Support / SB Dev
  • Posts: 2191
    • ScriptBasic Open Source Project
Re: SB64.AppImage
« Reply #20 on: October 07, 2018, 02:49:48 PM »
Quote
Hi Armando,

I'm glad to see you here. :)

Way too long of a BASIC vacation.  ;D

I'm going to follow your and AIR's lead to which C compiler to use under Windows.
« Last Edit: October 07, 2018, 02:54:11 PM by John »

Offline Mike Lobanovsky

  • ON-HOLD
  • BASIC Developer
  • Posts: 216
Re: SB64.AppImage
« Reply #21 on: October 07, 2018, 03:20:25 PM »
I think you can use GCC because it's in fact more flexible and permissive than native MS VC/C++ or Intel C++ compilers. But you shouldn't deviate from its default Windows settings that ensure binary compatibility of its machine code emitter with the MS Windows system components and smaller size of the resultant executables. Which means that from my perspective, making x64 SB's as-is source code truly universal is infeasible, and a lot of PP platform-dependent branching is, alas, unavoidable.

FBSL has almost always been compiled with GCC 4.3.3. MS VC required more elaborate and verbose coding style. Experiments with LCC-Win32 and PellesC were in fact nothing but bitter failures. Contemporary TCC is mostly usable for simpler non-time-critical tasks but still immature for anything better than "toy" interpreters, language development wise.
Mike
____________________________________________________________________
(3.6GHz Intel Core i5, 16GB RAM / nVidia GTX 1060Ti , 6GB VRAM / x64 Win7 Ult.)

Offline John

  • Forum Support / SB Dev
  • Posts: 2191
    • ScriptBasic Open Source Project
Re: SB64.AppImage
« Reply #22 on: October 07, 2018, 03:31:20 PM »
Does the idea of having a SB option to toggle 32/64 bit math on the fly with the Windows 64 bit version have merit?

If SB Windows 64 bit materializes, I would like to take the .Net forms control route allowing the SB code to be reused from its 32 bit VB6 COM associate.
« Last Edit: October 07, 2018, 04:44:16 PM by John »

Offline John

  • Forum Support / SB Dev
  • Posts: 2191
    • ScriptBasic Open Source Project
Re: SB64.AppImage
« Reply #23 on: October 07, 2018, 05:06:04 PM »
This HTML version of the Script BASIC User Guide might be nice to include in the AppImage for SB.

Online AIR

  • RETIRED
  • BASIC Developer
  • Posts: 410
Re: SB64.AppImage
« Reply #24 on: October 07, 2018, 05:30:42 PM »
I think you can use GCC because it's in fact more flexible and permissive than native MS VC/C++ or Intel C++ compilers. But you shouldn't deviate from its default Windows settings that ensure binary compatibility of its machine code emitter with the MS Windows system components and smaller size of the resultant executables. Which means that from my perspective, making x64 SB's as-is source code truly universal is infeasible, and a lot of PP platform-dependent branching is, alas, unavoidable.

I agree 100% with what Mike says.  I admit that I'm biased because when I first tried learning C I used MSVC and also Pelles, but neither clicked with me.  When I tried GCC, it started making sense.  That and the other two aren't available for macOS or Unix/Linux.   ;)

AIR.

Online AIR

  • RETIRED
  • BASIC Developer
  • Posts: 410
Re: SB64.AppImage
« Reply #25 on: October 07, 2018, 05:32:18 PM »
Hi Armando,

I'm glad to see you here again. :)

I never actually left, I was just in full-on lurking mode..... ;D

AIR.

Online AIR

  • RETIRED
  • BASIC Developer
  • Posts: 410
Re: SB64.AppImage
« Reply #26 on: October 07, 2018, 05:37:52 PM »
Does the idea of having a SB option to toggle 32/64 bit math on the fly with the Windows 64 bit version have merit?

What do you actually gain from 64bit math in SB?  Aside from a larger address space?

I'm not knocking this desire, I'm curious as to how you would utilize this?

AIR.

Offline John

  • Forum Support / SB Dev
  • Posts: 2191
    • ScriptBasic Open Source Project
Re: SB64.AppImage
« Reply #27 on: October 07, 2018, 05:44:47 PM »
Quote
What do you actually gain from 64bit math in SB?  Aside from a larger address space?

I'm not knocking this desire, I'm curious as to how you would utilize this?

AIR.

A good question and should be discussed before doing anything.

Online AIR

  • RETIRED
  • BASIC Developer
  • Posts: 410
Re: SB64.AppImage
« Reply #28 on: October 07, 2018, 05:49:08 PM »
This HTML version of the Script BASIC User Guide might be nice to include in the AppImage for SB.

You can add anything you like to an AppImage, but the question becomes how to access what you add.

That html is in serious need of some css, btw.  :o

AIR.

Offline John

  • Forum Support / SB Dev
  • Posts: 2191
    • ScriptBasic Open Source Project
Re: SB64.AppImage
« Reply #29 on: October 07, 2018, 05:58:56 PM »
I would much rather put any 64 bit effort into Linux to address the few minor issues I have found. I don't see the flow of 64 bit Windows apps coming down the road. It's all about the Cloud with Microsoft going forward. Screw desktop developers.