Hi all,
I have some problems installing pillow on top of sicstus 3.7.1. What I have done:
-Installed pillow as described in README. -Changed the predicate 'save' to 'save_program' in html.pl
Tried phones.pl from the examples directory:
---------------- euklid:/provided/sicstus/pillow/examples >sicstus SICStus 3.7.1 (IRIX64-6.4-IP27): Tue Oct 06 13:24:09 MDT 1998 Licensed to uni-duesseldorf | ?- [phones]. {consulting /provided/sicstus/pillow/examples/phones.pl...} {consulting /provided/sicstus/library/pillow.pl...} {consulting /provided/sicstus/library/html.pl...} {loading /provided/sicstus/library/system.ql...} {loaded /provided/sicstus/library/system.ql in module system, 10 msec 28104 bytes} {consulted /provided/sicstus/library/html.pl in module pillow, 260 msec 124608 bytes} {loading /provided/sicstus/library/sockets.ql...} {loaded /provided/sicstus/library/sockets.ql in module sockets, 10 msec 29200 bytes} {consulted /provided/sicstus/library/pillow.pl in module pillow, 380 msec 212312 bytes} {SICStus state saved in /provided/sicstus/pillow/examples/phones.cgi} {/provided/sicstus/pillow/examples/phones.pl consulted, 400 msec 214992 bytes}
yes | ?- halt. --------------------
But ./phones.cgi says:
---------------------- euklid:/provided/sicstus/pillow/examples >./phones.cgi SICStus 3.7.1 (IRIX64-6.4-IP27): Tue Oct 06 13:24:09 MDT 1998 Licensed to uni-duesseldorf {SICStus state restored from /provided/sicstus/pillow/examples/phones.cgi} {INSTANTIATION ERROR: call(pillow:_668) - arg 1} | ?- ---------------------
The first line in phones.pl is: :- use_module('/provided/sicstus/library/pillow.pl'). This is correct.
Any ideas to get pillow running with sicstus 3.7.1? I have also tried prolog_shell3, almost the same problem. Also found nothing in the pillow docs, they seem to be related to an older version of sicstus.
Thanks,
Michael
Dear Michael,
Sorry for the delay. We have not tried PiLLoW ourselves with SICStus 3.7 because we have not installed 3.7 until very recently.
We plan to make the mods to PiLLoW for 3.7 in the coming days. However, in the meantime, perhaps someone in the list has done it already and can send the patches?
Cheers,
Daniel Cabeza
On Thu, 10 Jun 1999, Daniel Cabeza Gras wrote:
Dear Michael,
Sorry for the delay. We have not tried PiLLoW ourselves with SICStus 3.7 because we have not installed 3.7 until very recently.
We plan to make the mods to PiLLoW for 3.7 in the coming days. However, in the meantime, perhaps someone in the list has done it already and can send the patches?
Cheers,
Daniel Cabeza
what was the original question ?
i have pillow running with 3.7 but dont have a patch that does the whole job,
i think there are only few changes required
regards
nicos.
I used Pillow case for a graduate project, also on Sicstus 3.7. It did not work as the README file says. I used the core program of the Pillow, except the "save" part. My solution is to build another C-shell script help-file to call my Prolog program: #! /bin/csh set list = $0 exec /sw/arch/bin/prolog -l $list:r'.pl'
This C-shell script file is named as myfile.cgi, it calls myfile.pl (the Prolog file). In my Web page, myfile.cgi is called. In myfile.pl, two more calls are needed: :-main. /* run the program */ :-halt. /* quit from Prolog */ so that you can return the result to Web page.
Good luck. Please let me know if you have any further questions.
Mike Z Chen -------------------------------------- e-mail: zhc134(a)cs.usask.ca
Computer Science Department University of Saskatchewan Saskatoon, Sakatchewan Canada
On Fri, 11 Jun 1999, Nicos Angelopoulos wrote:
On Thu, 10 Jun 1999, Daniel Cabeza Gras wrote:
Dear Michael,
Sorry for the delay. We have not tried PiLLoW ourselves with SICStus 3.7 because we have not installed 3.7 until very recently.
We plan to make the mods to PiLLoW for 3.7 in the coming days. However, in the meantime, perhaps someone in the list has done it already and can send the patches?
Cheers,
Daniel Cabeza
Dear all,
As already pointed out the problem with PiLLoW is in save/1-2. Since SICStus 3.7 and 3.7.1 do not include save/1-2 PiLLoW was based we have to use save_program/1-2.
I used PiLLoW and SICStus 3.7.1 in our project on rewriting aggregate queries using views and changed a code of PiLLoW (html.pl) in the following way.
my_save(Name,Return,EntryPoint):- save_program(Name,my_goal(Name,EntryPoint)), Return = 0. my_goal(Name,EntryPoint) :- boot_form(1,Name,EntryPoint).
save_cgi_bin(Name,EntryPoint) :- cgi_bin_dir(BinDir), atom_concat(BinDir,Name,FullName), my_save(FullName,Return,EntryPoint), boot_form(Return,FullName,EntryPoint).
save_cgi(Name,EntryPoint) :- my_save(Name,Return,EntryPoint), boot_form(Return,Name,EntryPoint).
Now in order to create cgi_bin's save_cgi and save_cgi_bin may be used as usual.
Try it, probably this solution will fit your purposes as well.
Best regards, Alexander Serebrenik