Received: from malur.postgresql.org ([217.196.149.56]) by arkaria.postgresql.org with esmtp (Exim 4.80) (envelope-from ) id 1XJN0p-0006EC-3y for pgsql-odbc@arkaria.postgresql.org; Mon, 18 Aug 2014 13:30:15 +0000 Received: from localhost ([127.0.0.1] helo=postgresql.org) by malur.postgresql.org with smtp (Exim 4.80) (envelope-from ) id 1XJN0o-0004bZ-8m for pgsql-odbc@arkaria.postgresql.org; Mon, 18 Aug 2014 13:30:14 +0000 Received: from makus.postgresql.org ([2001:4800:1501:1::229]) by malur.postgresql.org with esmtps (TLS1.2:DHE_RSA_AES_256_CBC_SHA256:256) (Exim 4.80) (envelope-from ) id 1XJN0n-0004aE-Lf for pgsql-odbc@postgresql.org; Mon, 18 Aug 2014 13:30:13 +0000 Received: from smtp-outbound-1.vmware.com ([208.91.2.12]) by makus.postgresql.org with esmtps (TLS1.0:DHE_RSA_AES_256_CBC_SHA1:256) (Exim 4.80) (envelope-from ) id 1XJN0i-0004P7-3z for pgsql-odbc@postgresql.org; Mon, 18 Aug 2014 13:30:10 +0000 Received: from sc9-mailhost3.vmware.com (sc9-mailhost3.vmware.com [10.113.161.73]) by smtp-outbound-1.vmware.com (Postfix) with ESMTP id 514362894E; Mon, 18 Aug 2014 06:30:06 -0700 (PDT) Received: from EX13-CAS-002.vmware.com (EX13-CAS-002.vmware.com [10.113.191.52]) by sc9-mailhost3.vmware.com (Postfix) with ESMTP id 461B7410BA; Mon, 18 Aug 2014 06:30:06 -0700 (PDT) Received: from EX13-MBX-024.vmware.com (10.113.191.44) by EX13-MBX-009.vmware.com (10.113.191.29) with Microsoft SMTP Server (TLS) id 15.0.775.38; Mon, 18 Aug 2014 06:29:59 -0700 Received: from [192.168.1.90] (10.113.160.246) by EX13-MBX-024.vmware.com (10.113.191.44) with Microsoft SMTP Server (TLS) id 15.0.775.38; Mon, 18 Aug 2014 06:29:43 -0700 Message-ID: <53F1FFC2.9090204@vmware.com> Date: Mon, 18 Aug 2014 16:29:38 +0300 From: Heikki Linnakangas Organization: VMware User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:24.0) Gecko/20100101 Icedove/24.5.0 MIME-Version: 1.0 To: Sandeep Thakkar CC: "pgsql-odbc@postgresql.org" Subject: Re: psqlodbc build with libpq on OS X References: <53F1EFBB.1060100@vmware.com> In-Reply-To: Content-Type: text/plain; charset="UTF-8"; format=flowed Content-Transfer-Encoding: 7bit X-Originating-IP: [10.113.160.246] X-ClientProxiedBy: EX13-CAS-013.vmware.com (10.113.191.65) To EX13-MBX-024.vmware.com (10.113.191.44) X-Pg-Spam-Score: -7.6 (-------) List-Archive: List-Help: List-ID: List-Owner: List-Post: List-Subscribe: List-Unsubscribe: X-Mailing-List: pgsql-odbc Precedence: bulk Sender: pgsql-odbc-owner@postgresql.org On 08/18/2014 03:49 PM, Sandeep Thakkar wrote: > May be you are right that iodbc-config should not return "-L/usr/lib". But, > when I provide, --with-libpq= switch specifically, > shoudn't it pick the libpq from there? Well, yeah, but iodbc-config returning "-L/usr/lib" screws that up. What's your point? Looking closer at configure.ac, we actually have a similar issue with pg_config. If you had libpq in the standard location, in /usr/lib/, and libiodbc in a non-standard location, with your patch that case would go wrong. No matter which way you order the -L's, it's going to be wrong in the other direction. The solution is to not include standard paths like /usr/lib in the output. Perhaps it would be better to not use odbc_config / pg_config at all, at least if the ./configure option is just "--with-libpq" and not "--with-libpq=". We could add just -lodbcinst and -lpq to LDFLAGS directly, and assume that the required headers and libraries are in the default system paths, without any -L or -I options. With that, you could do "--with-iodbc" without a path and "--with-libpq=", and it would work, I think. Want to try writing a patch for that? - Heikki -- Sent via pgsql-odbc mailing list (pgsql-odbc@postgresql.org) To make changes to your subscription: http://www.postgresql.org/mailpref/pgsql-odbc