From: ttate@... Date: 1998-08-13T08:15:50+09:00 Subject: [ruby-list:9086] PostgreSQL Module 立石@JAISTです。 PostgreSQL拡張モジュールが現在のRubyには 対応していませんでした。 以下のような修正はどうでしょうか? diff -c -r -N postgres-old/Makefile.rb postgres/Makefile.rb *** postgres-old/Makefile.rb Fri Dec 12 20:12:02 1997 --- postgres/Makefile.rb Thu Aug 13 08:10:12 1998 *************** *** 5,10 **** --- 5,13 ---- require "mkmf" + $LDFLAGS = "" + $CFLAGS = "" + have_library("wsock32", "cygwin32_socket") or have_library("socket", "socket") have_library("inet", "gethostbyname") have_library("nsl", "gethostbyname") *************** *** 23,30 **** $LDFLAGS = "-L" + libdir $CFLAGS += "-I" + libdir.gsub("lib", "include") else ! $LDFLAGS = "-L/usr/local/pgsql/lib" ! $CFLAGS += "-I/usr/local/pgsql/include" end if have_library("pq", "PQsetdb") create_makefile("postgres") --- 26,36 ---- $LDFLAGS = "-L" + libdir $CFLAGS += "-I" + libdir.gsub("lib", "include") else ! $LDFLAGS = "-L/opt/local/pgsql/lib -lpq" ! $CFLAGS += "-I/opt/local/pgsql/include" ! end ! if have_header("rubyio.h") ! $CFLAGS += " -DHAVE_RUBYIO_H " end if have_library("pq", "PQsetdb") create_makefile("postgres") diff -c -r -N postgres-old/postgres.c postgres/postgres.c *** postgres-old/postgres.c Fri Dec 12 20:12:02 1997 --- postgres/postgres.c Thu Aug 13 08:09:36 1998 *************** *** 11,17 **** --- 11,22 ---- ************************************************/ #include "ruby.h" + #ifdef HAVE_RUBYIO_H + #include "rubyio.h" + #else #include "io.h" + #endif + #include #include