vscosta / yap-6.3

YAP Development release
Other
13 stars 5 forks source link

myydas compiles but does not load correctedly #35

Closed lasergyro closed 2 years ago

lasergyro commented 6 years ago

Using the pythonless version (commit 927a43933ccc4d3def3563c1012a14bac4dee6fe , more recent do not compile yap), myydas shows this when loaded and db_open fails.

[ma@MAvmfedora2 ~]$ yap
% YAP 6.3.5-927a4393 (compiled  2018-03-27T13:19:32@MAvmfedora2)
% database loaded from /usr/local/lib/Yap/startup.yss
?- use_module(library(myddas)).
 % reconsulting library(myddas)...
  % reconsulting myddas_assert_predicates...
   % reconsulting myddas_errors...
    % reconsulting myddas_util_predicates...
     % reconsulting myddas_prolog2sql...
      % reconsulting lists...
      % reconsulted /usr/local/share/Yap/lists.yap in module lists, 6 msec 0 bytes
      % reconsulting myddas_prolog2sql_optimizer...
      % reconsulted /usr/local/share/Yap/myddas_prolog2sql_optimizer.yap in module myddas_prolog2sql_optimizer, 3 msec 0 bytes
     % reconsulted /usr/local/share/Yap/myddas_prolog2sql.yap in module myddas_prolog2sql, 25 msec 0 bytes
/usr/local/share/Yap/myddas_util_predicates.yap:248:0  warning: /usr/local/share/Yap/myddas_util_predicates.yap redefines prolog:'$abolish_all'/1 from  /var/tmp/yap-6.3/pl.

    % reconsulted /usr/local/share/Yap/myddas_util_predicates.yap in module myddas_util_predicates, 38 msec 0 bytes
   % reconsulted /usr/local/share/Yap/myddas_errors.yap in module myddas_errors, 42 msec 0 bytes
   % reconsulting myddas_mysql...
   % reconsulted /usr/local/share/Yap/myddas_mysql.yap in module myddas_mysql, 8 msec 0 bytes
   % reconsulting myddas_sqlite3...
dlopen of image . failed: libYapsqlite3: cannot open shared object file: No such file or directory
Unknown exception: error(system_error(operating_system_error,init_sqlite3),[[e|p(prolog,load_foreign_files,3,/var/tmp/yap-6.3/pl/load_foreign.yap,0)],[p|p(prolog,load_foreign_files,3,/var/tmp/yap-6.3/pl/load_foreign.yap,0)],[c|c(/usr/tmp/yap-6.3/C/load_foreign.c,99,p_load_foreign)],[i|Foreign module libYapsqlite3 does not have initialization function init_sqlite3]])
   % reconsulted /usr/local/share/Yap/myddas_sqlite3.yap in module myddas_sqlite3, 4 msec 0 bytes
   % reconsulting myddas_odbc...
dlopen of image . failed: libYapodbc: cannot open shared object file: No such file or directory
Unknown exception: error(system_error(operating_system_error,init_odbc),[[e|p(prolog,load_foreign_files,3,/var/tmp/yap-6.3/pl/load_foreign.yap,0)],[p|p(prolog,load_foreign_files,3,/var/tmp/yap-6.3/pl/load_foreign.yap,0)],[c|c(/usr/tmp/yap-6.3/C/load_foreign.c,99,p_load_foreign)],[i|Foreign module libYapodbc does not have initialization function init_odbc]])
   % reconsulted /usr/local/share/Yap/myddas_odbc.yap in module myddas_odbc, 5 msec 0 bytes
  % reconsulted /usr/local/share/Yap/myddas_assert_predicates.yap in module myddas_assert_predicates, 67 msec 0 bytes
/usr/local/share/Yap/myddas.yap:441:0  warning: discontiguous definition for myddas:db_datalog_show_tables/0.

 % reconsulted /usr/local/share/Yap/myddas.yap in module myddas, 82 msec 0 bytes
true.

?- db_open(mysql,localhost/guest,guest,'').
user_input:3:0 error in prolog:'$handle_error'/3: error:  procedure c_db_my_connect/7 could not be found,
          goal was prolog:context(myddas:c_db_my_connect(localhost,guest,'',guest,0,_131123,_131124),prolog:'$yes_no'/2)
          exception raised from prolog:'$handle_error':3, /var/tmp/yap-6.3/pl/undefined.yap:0:0:

?- .
[ma@MAvmfedora2 ~]$ mysql -u guest
Welcome to the MariaDB monitor.  Commands end with ; or \g.
Your MariaDB connection id is 43
Server version: 10.1.30-MariaDB MariaDB Server

Copyright (c) 2000, 2017, Oracle, MariaDB Corporation Ab and others.

Type 'help;' or '\h' for help. Type '\c' to clear the current input statement.

MariaDB [(none)]> use guest
Reading table information for completion of table and column names
You can turn off this feature to get a quicker startup with -A

Database changed
MariaDB [guest]>