From 392c4581da49f133938e70f6215bfebba28ecc56 Mon Sep 17 00:00:00 2001 From: Mark Asselstine Date: Tue, 4 Aug 2015 20:59:18 -0400 Subject: [PATCH] setup: don't use pg_config The package uses the pg_config command to detect the libdir and includedir path. Commented the lines because the command is not available at buildtime and the package succesfully build without them. Signed-off-by: Mark Asselstine Signed-off-by: Mark Asselstine --- setup.cfg | 2 +- setup.py | 5 +---- 2 files changed, 2 insertions(+), 5 deletions(-) diff --git a/setup.cfg b/setup.cfg index 90a47dd..986871b 100644 --- a/setup.cfg +++ b/setup.cfg @@ -9,7 +9,7 @@ define= # build psycopg2. If pg_config is not in the path or is installed under a # different name uncomment the following option and set it to the pg_config # full path. -#pg_config= +pg_config="/bin/true" # Set to 1 to use Python datetime objects for default date/time representation. use_pydatetime=1 diff --git a/setup.py b/setup.py index 975fe10..85502ca 100644 --- a/setup.py +++ b/setup.py @@ -389,16 +389,13 @@ class psycopg_build_ext(build_ext): self.libraries.append("pq") try: - self.library_dirs.append(pg_config_helper.query("libdir")) - self.include_dirs.append(pg_config_helper.query("includedir")) - self.include_dirs.append(pg_config_helper.query("includedir-server")) try: # Here we take a conservative approach: we suppose that # *at least* PostgreSQL 7.4 is available (this is the only # 7.x series supported by psycopg 2) pgversion = pg_config_helper.query("version").split()[1] except: - pgversion = "7.4.0" + pgversion = "9.4.4" verre = re.compile( r"(\d+)\.(\d+)(?:(?:\.(\d+))|(devel|(alpha|beta|rc)\d+))") -- 2.1.4