[Gambas-user] Installing on webserver

R. Stormo rohnny at ...1248...
Wed Mar 26 19:33:40 CET 2008




Benoit Minisini wrote:
> 
> On mercredi 26 mars 2008, R. Stormo wrote:
>> Is there a way I can use gambas on my isp's webserver without installing
>> it
>> on the main system.?
>> They say I was welcome to install new components but they could not
>> guarantee that it would work.
>> So I wonder if I could place gambas files someplace on my path to make it
>> work.
>>
>>
>> Regards Rohnny
>>
>> My Gambas Community http://gambasforum.tk
> 
> Theoretically, you can compile gambas by specifying the installation
> prefix to 
> configure:
> 
> $ ./configure --prefix=/home/rohnny/gambas
> 
> Then, the only requirement is that the gbx2 (or gbx3) executable must be 
> accessible from the PATH environmental variable.
> 
> Try, and tell me if it works for you! :-)
> 
> Regards,
> 
> -- 
> Benoit Minisini
> 
> -------------------------------------------------------------------------
> Check out the new SourceForge.net Marketplace.
> It's the best place to buy or sell services for
> just about anything Open Source.
> http://ad.doubleclick.net/clk;164216239;13503038;w?http://sf.net/marketplace
> _______________________________________________
> Gambas-user mailing list
> Gambas-user at lists.sourceforge.net
> https://lists.sourceforge.net/lists/listinfo/gambas-user
> 
> 
Well it was not so lucky. But I hope you may have another solution for me ;)

Moved the bin folder to root of my domain .
Moved the gambas folder to root of my domain also.

copy my file called mem.gambas (found on this list some time ago.)

By running the gambas file I got server error. But by modify a test file so
I can run some command I got further.
I called it test.
#!/bin/sh
# disable filename globbing
#set -f
echo Content-type: text/plain
echo
#echo CGI/1.0 test script report:
#echo
PATH=$PATH:$HOME/bin:/hsphere/local/home/rstormo/bin
export PATH
echo $PATH
./mem.gambas
 echo "Gambas program was executed"
 echo "Running programs"
ps -A
 
I got alot of output but not from the gambas software,.
--snip
/usr/local/bin:/usr/bin:/bin:/bin:/hsphere/xxxxxxxxxxxxxx/bin
Gambas program was executed
Running programs
  PID TTY          TIME CMD
    1 ?        00:00:00 init
    2 ?        00:00:00 kthreadd
    3 ?        00:00:00 mig.......

-snap

My Mem program
--snip
' This script returns the memory really used by the system, the cache
'AND SWAP being excluded.

FUNCTION GetUsedMemory() AS Integer

  DIM sRes AS String
  DIM aRes AS String[]
  DIM cVal AS NEW Collection
  DIM sVal AS String

  EXEC ["cat", "/proc/meminfo"] TO sRes

  FOR EACH sVal IN Split(sRes, "\n", "", TRUE)
    aRes = Split(sVal, " ", "", TRUE)
    cVal[Left$(aRes[0], -1)] = CInt(aRes[1])
  NEXT

  RETURN cVal!MemTotal - cVal!MemFree - cVal!Buffers - cVal!Cached +
cVal!SwapTotal - cVal!SwapFree - cVal!SwapCached

END

PUBLIC SUB Main()
PRINT Subst("Used memory: &1 bytes", GetUsedMemory())
END
-snap


Regards Rohnny

My Gambas Community http://gambasforum.tk


-- 
View this message in context: http://www.nabble.com/Installing-on-webserver-tp16301165p16311631.html
Sent from the gambas-user mailing list archive at Nabble.com.





More information about the User mailing list