AppliedLogicSystems / ALSProlog

ALS Prolog Compiler & Development Environment
https://alsprolog.com
MIT License
16 stars 9 forks source link

curl segment of 'make test' fails with call to echo server #200

Closed kenbowen closed 1 year ago

kenbowen commented 1 year ago

After a build, executing 'make test' in ALSProlog/unix produces an error in the curl segment, specifically the call to run an echo server fails, so that subsequent alspro curl calls fail:

+ exec php --server localhost:8888 index.php
../../alsp_src/tests/tsuite/echo/serve: line 7: exec: php: not found     <<<<<<<
+ ((  0  ))
+ ./alspro -no_obp -s ../../alsp_src/tests ../../alsp_src/tests/tsuite/curl_test.pro -g test
ALS Prolog (Byte) Version 3.5.0-213-ga2cee431-dirty [darwin]
   Copyright (c) 1987-2022 Applied Logic Systems, Inc.

Setting up library indicies...may take a moment...Done.

Uncaught Error: curl_error(curl_easy_perform() failed: Couldn't connect to server)
FAIL: open(url('http://localhost:8888/abc'),read,_A), get_line(_A,abc), close(_A)
Uncaught Error: curl_error(curl_easy_perform() failed: Couldn't connect to server)
FAIL: open(url('http://localhost:8888/abc',[]),read,_A), get_line(_A,abc), close(_A)
Uncaught Error: curl_error(curl_easy_perform() failed: Couldn't connect to server)
FAIL: open(url('http://localhost:8888/myatom.'),read,_A), read(_A,myatom), close(_A)
Uncaught Error: curl_error(curl_easy_perform() failed: Couldn't connect to server)
FAIL: open(url('http://localhost:8888/myfunc(a,b,[l1,l2]).'),read,_A), read(_A,myfunc(a,b,[l1,l2])), close(_A)
Uncaught Error: curl_error(curl_easy_perform() failed: Couldn't connect to server)
FAIL: open(url('http://localhost:8888/?REQUEST_METHOD'),read,_A), get_line(_A,'GET'), close(_A)
../../alsp_src/tests/tsuite/curl_test.sh: line 22: 76044 Segmentation fault: 11  "$ALSPRO" -no_obp -s "$TESTDIR" "$TSUITE"/curl_test.pro -g test < /dev/null
chuckhoupt commented 1 year ago

Good point. PHP was removed from recent versions of macOS, so we can no longer rely on it being installed by default. PR to follow...

chuckhoupt commented 1 year ago

Fix in PR #201