Author Topic: ScriptBasic 32 bit Windows  (Read 23819 times)

Support

  • Administrator
  • *****
  • Posts: 1
    • View Profile
ScriptBasic 32 bit Windows
« on: July 04, 2010, 09:14:42 am »
I will be posting a release candidate for the 32 bit version of Armando's work with the 64 bit ScriptBasic effort using the GCC / MinGW C/C++ compiler. Armando has sent me the ZLIB and new XML extension modules to test. I will include a batch file to convert ScriptBasic applications to a standalone executable using a shared object runtime using this same compiler.

I have noticed in the site logs that there have been daily downloads of ScriptBasic. It would be great to hear some feedback from the users for a change.  :(
« Last Edit: July 04, 2010, 09:17:12 am by support »

Airr

  • Guest
Re: ScriptBasic 32 bit Windows
« Reply #1 on: July 05, 2010, 01:19:05 am »
John,

The XML module is not necessarily "new", just "fixed" (somewhat).  ;D

It still requires libxml.dll, iconv.dll, and zlib1.dll files, which add up to about 2megs worth of external dependencies.

I've finished the preliminary work on a replacement xml module, called "mxml".  It requires NO external dependencies.

Using the following xml file as a test:
<?xml version="1.0" encoding="UTF-8" ?>


<stufflist>
        <stuff_test>This is a test!</stuff_test>
        <stuff_test2>And this is another test!</stuff_test2>
        <stuff_test3>
                <painting>
                        <img src="madonna.jpg" alt='Foligno Madonna, by Raphael'/>
                        <caption>This is Raphael's "Foligno" Madonna, painted in
                                <date>1511</date>.
                        </caption>
                </painting>
        </stuff_test3>
        <books>
            <book>
                <id>1</id>
                <name>Hello, world!</name>
            </book>
            <book>
                <id>2</id>
                <name>Hello, China!</name>
            </book>
        </books>
</stufflist>
I can parse it like so:

include "c:\scriptbasic\include\mxml.bas"

filename = "stuff.xml"

doc = mxml::LoadDoc(filename)

node =  mxml::GetNode(doc,"/stufflist/stuff_test")
if node then print "Test1: ", mxml::GetNodeValue(node),"\n"

node =  mxml::GetNode(doc,"/stufflist/stuff_test2")
if (node) then print "Test2: ", mxml::GetNodeValue(node),"\n\n"

 
node = mxml::GetNode(doc,"/stufflist/stuff_test3/painting/img")
if node then
        print "Image: ", mxml::GetProperty(node,"src"), "\n"
        print "Alt Image: ", mxml::GetProperty(node,"alt"), "\n\n"
endif


node = mxml::GetNode(doc,"/stufflist/books")
child = mxml::GetChild(node)

while child
        node = mxml::GetNode(child,"id")
        if node then print "ID = ", mxml::GetNodeValue(node),"\n"
        node = mxml::GetNode(child,"name")
        if node then print "Name = ", mxml::GetNodeValue(node),"\n"
       
        child = mxml::GetNext(child)
wend


if doc then mxml::FreeDoc(doc)
I coded this to use an XPATH-like call to get a pointer/handle to a given node.

Here's the output:
Code: [Select]
C:\Scriptbasic\mxmltest>\Scriptbasic\bin\scriba.exe mxmltest.sb
Test1: This is a test!
Test2: And this is another test!

Image: madonna.jpg
Alt Image: Foligno Madonna, by Raphael

ID = 1
Name = Hello, world!
ID = 2
Name = Hello, China!

I'll send you the mxml module in a bit so you can test before adding to the RC.

A.


Support

  • Administrator
  • *****
  • Posts: 1
    • View Profile
Re: ScriptBasic 32 bit Windows
« Reply #2 on: July 05, 2010, 05:47:04 am »
I now understand that the XML extension module you sent in the Windows 32 build is a fixed version of what we had already.

Your new XML effort looks great with a slimmer look and less baggage is a welcome addition.




Support

  • Administrator
  • *****
  • Posts: 1
    • View Profile
Re: ScriptBasic 32 bit Windows
« Reply #3 on: July 05, 2010, 07:58:54 am »
Armando,

Your new XML extension module could be used to treat Gtk XML project files as GUI object templates. I could then load XML template files, extract the GUI definitions I'm interested in and process the request as direct calls to the Gtk-Server extension module. (which hasn't been converted to MinGW/GCC yet under Windows)

If you wanted to, you could use the web as a repository for GUI template definitions. The cURL extension module would come in handy with that task.


Just some low hanging fruit to salivate over.  :o
« Last Edit: July 05, 2010, 08:25:49 am by support »

Ran

  • Guest
Re: ScriptBasic 32 bit Windows
« Reply #4 on: December 31, 2013, 10:11:50 am »
Did try to run Scriptbasic under Wine (Ubuntu 12.04)
but it didn't work.
Of course Wine is not a full winows and a lot of Win Progs
do not run under Wine.
You have to be lucky here.
I run Pelle's C under Wine and Visual C++ 6.0

Ran

  • Guest
Re: ScriptBasic 32 bit Windows
« Reply #5 on: December 31, 2013, 01:28:33 pm »
But ScriptBasic 32 runs fine under windows 7 64 bits
 :)

Support

  • Administrator
  • *****
  • Posts: 1
    • View Profile
Re: ScriptBasic 32 bit Windows
« Reply #6 on: December 31, 2013, 06:16:17 pm »
I use the 32 bit version of scriba under Wine all the time. What issues are you having?

Ran

  • Guest
Re: ScriptBasic 32 bit Windows
« Reply #7 on: January 01, 2014, 08:20:12 am »
Well, it works ok for the moment but I run normally win programs from allover dir's in Ubuntu.
So, ScriptBasic doesn't work if I do so.
I posted it here.
But I was thinking later on to run it from the C dir where Wine lives.
And yes, it runs happily there...... :D