Differences

This shows you the differences between two versions of the page.

Link to this comparison view

Both sides previous revision Previous revision
Next revision
Previous revision
diana:windows:building:sql [2010-03-10 15:14:01]
dages
diana:windows:building:sql [2022-05-31 09:29:31] (current)
Line 16: Line 16:
  
 ==== libpq (C interface) ==== ==== libpq (C interface) ====
 +
 +PostgreSQL includes its own implementations of certain functions which are not available in Win32, such as ''inet_aton()'' and ''strlcat()'' Unfortunately, so do the [[ffmpeg|ffmpeg libraries]].  We resolve this conflict by using macros to transparently add a ''pq_'' prefix to each of these functions.
 +
 +**NOTE:** The PostgreSQL developers have [[http://thread.gmane.org/gmane.comp.db.postgresql.devel.general/137878|stated quite unambiguously]] that they do not support static linking and will disable it completely in future releases.  If / when that happens, it will be necessary to link ''libpq'' (and possibly also the ffmpeg libraries) dynamically.
  
 First, get the latest source (currently 8.3.9 for the 8.3 branch) from http://www.postgresql.org/ftp/source/v8.3.9/ and extract it in a convenient place.  First, get the latest source (currently 8.3.9 for the 8.3 branch) from http://www.postgresql.org/ftp/source/v8.3.9/ and extract it in a convenient place. 
Line 125: Line 129:
   $ LDFLAGS=-L/c/met.no/lib CPPFLAGS=-I/c/met.no/include ./configure --prefix=/c/met.no --disable-shared   $ LDFLAGS=-L/c/met.no/lib CPPFLAGS=-I/c/met.no/include ./configure --prefix=/c/met.no --disable-shared
  
-We don't want to install the entire package (server and all); we'll just install the library and headers and the ''pg_config'' tool which is used by other packages (such as ''libpqxx'') that link against ''libpq''.+We don't want to install the entire package (server and all); we'll just install the library and headers and the ''pg_config'' tool which is used by other packages (such as ''libpqxx'') that link against ''libpq'' This complicates the build process a little, but saves a lot of time:
  
   $ make -C src/port all   $ make -C src/port all
Line 133: Line 137:
   $ make -C src/interfaces/libpq all install   $ make -C src/interfaces/libpq all install
   $ make -C src/bin/pg_config all install   $ make -C src/bin/pg_config all install
 +  $ cp COPYRIGHT /c/met.no/copyright/libpq.txt
  
 ==== libpqxx (C++ interface) ==== ==== libpqxx (C++ interface) ====
Line 147: Line 152:
  
   $ make all install   $ make all install
 +  $ cp AUTHORS /c/met.no/copyright/libpqxx.txt
 +  $ cat COPYING >>/c/met.no/copyright/libpqxx.txt
  • diana/windows/building/sql.1268234041.txt.gz
  • Last modified: 2022-05-31 09:23:14
  • (external edit)