Skip Menu |
 

This queue is for tickets about the DBD-Pg CPAN distribution.

Report information
The Basics
Id: 131708
Status: open
Priority: 0/
Queue: DBD-Pg

People
Owner: Nobody in particular
Requestors: skeetabomb [...] gmail.com
Cc:
AdminCc:

Bug Information
Severity: (no value)
Broken in: (no value)
Fixed in: (no value)



Subject: BUG: 'cpan install DBD::Pg' fails looking for LIBPQ.dll
Date: Sat, 8 Feb 2020 17:58:29 +1100
To: bug-DBD-Pg [...] rt.cpan.org
From: "Stephen Dennis (Gmail)" <skeetabomb [...] gmail.com>
Download (untitled) / with headers
text/plain 5.4k
Hi, I posted this bug on metacpan, and someone was kind enough to redirect me to you, though I am not 100% sure it is solely a DBD::Pg bug. My original post is here: https://github.com/metacpan/metacpan-web/issues/2266 But here is the full thread again: ============================================================================================== * troogyt <https://github.com/troogyt> * commented 1 hour ago <https://github.com/metacpan/metacpan-web/issues/2266#issue-561974903> Cannot install DBD::Pg using cpan as every time it looks for LIBPQ.dll it cannot find it. I ran Sysinternals Process Monitor and can see it appears to be looking for LIBPQ.dll in the wrong place: "C:\Program Files (x86)\Common Files\Oracle\Java\javapath_target_3326048396\LIBPQ.dll" I have no idea why java has anything to do with this, but I definitely do have PostgreSQL 12 installed and LIBPQ.dll is located here: "C:\Program Files\PostgreSQL\12\bin\libpq.dll" I think the CPAN installer must be compiling the directory path using incorrect input variables or something. CPAN console output: Show quoted text
cpan> install DBD::Pg
Running install for module 'DBD::Pg' TURNSTEP/DBD-Pg-3.10.4.tar.gz Has already been unwrapped into directory C:\Perl64\cpan\build\DBD-Pg-3.10.4-0 TURNSTEP/DBD-Pg-3.10.4.tar.gz Has already been prepared TURNSTEP/DBD-Pg-3.10.4.tar.gz Has already been made Running make test "C:\Perl64\bin\perl.exe" -MExtUtils::Command::MM -e cp_nonempty -- Pg.bs blib\arch\auto\DBD\Pg\Pg.bs 644 "C:\Perl64\bin\perl.exe" "-MExtUtils::Command::MM" "-MTest::Harness" "-e" "undef *Test::Harness::Switches; test_harness(0, 'blib\lib', 'blib \arch')" t/*.t t/00_signature.t ....... skipped: Set the environment variable TEST_SIGNATURE to enable this test t/00basic.t ............ 2/3 # Failed test 'use DBD::Pg;' # at t/00basic.t line 17. # Tried to use 'DBD::Pg'. # Error: Can't load 'C:\Perl64\cpan\build\DBD-Pg-3.10.4-0\blib\arch/auto/DBD/Pg/Pg.dll' for module DBD::Pg: load_file:The specified mod ule could not be found at C:/Perl64/lib/DynaLoader.pm line 194. # at t/00basic.t line 17. # Compilation failed in require at t/00basic.t line 17. # BEGIN failed--compilation aborted at t/00basic.t line 17. # CCFLAGS: q[ -s -O2 -DWIN32 -DWIN64 -DCONSERVATIVE -DPERL_TEXTMODE_SCRIPTS -DUSE_SITECUSTOMIZE -DPERL_IMPLICIT_CONTEXT -DPERL_IMPLICIT_SYS -fwrapv -fno-strict-aliasing -mms-bitfields -DPGLIBVERSION=120001 -DPGDEFPORT=5432] # INC: q[-I"C:/PROGRA~1/POSTGR~1/12/include" -IC:\Perl64\lib\auto\DBI] # LIBS: [q[-L"C:/PROGRA~1/POSTGR~1/12/lib" -lpq -lm -L"C:/PROGRA~1/POSTGR~1/12/lib/ms" -lsecur32]] Bailout called. Further testing stopped: Cannot continue without DBD::Pg FAILED--Further testing stopped: Cannot continue without DBD::Pg dmake.exe: Error code 255, while making 'test_dynamic' TURNSTEP/DBD-Pg-3.10.4.tar.gz C:\Perl64\site\bin\dmake.exe test -- NOT OK //hint// to see the cpan-testers results for installing this module, try: reports TURNSTEP/DBD-Pg-3.10.4.tar.gz Failed during this command: TURNSTEP/DBD-Pg-3.10.4.tar.gz : make_test NO Show quoted text
cpan>
------------------------------ Error Dialog Box: [image: image] <https://user-images.githubusercontent.com/41710820/74079205-4a40f480-4a88-11ea-9b68-d3fa7a8cb6d5.png> ------------------------------ Also tried: cpan DBD::Pg but with same result. I then set all the environment variables that appeared relevant, and according to both https://metacpan.org/source/TURNSTEP/DBD-Pg-3.10.4/README and the pg_env.bat file: user@computer C:\Users\user Show quoted text
>set | findstr "PG POSTG"
PGDATA=C:\Users\user\Documents\DB PGDATABASE=postgres PGLOCALEDIR=C:\Program Files\PostgreSQL\12\share\locale PGPORT=5432 PGUSER=postgres POSTGRES_HOME=C:\Program Files\PostgreSQL\12 POSTGRES_INCLUDE=C:\Program Files\PostgreSQL\12\include POSTGRES_LIB=C:\Program Files\PostgreSQL\12\lib However, contrary to https://metacpan.org/source/TURNSTEP/DBD-Pg-3.10.4/README I have no idea how to run these, as I cannot find them and the README assumes the reader both knows what they are and has them installed: pexports libpq.dll > libpq.def dlltool -dllname libpq.dll --def libpq.def --output-lib ..\lib\libpq.a It is not clear to me whether this is an issue with Perl itself, or cpan.exe, or PostgreSQL, or some combination of the 3. All I want to do is get Perl scripts managing my Postgres DB... please help :-/ [image: @Grinnz] <https://github.com/Grinnz> Contributor * Grinnz <https://github.com/Grinnz> * commented 1 hour ago <https://github.com/metacpan/metacpan-web/issues/2266#issuecomment-583706637> The bug tracker for DBD::Pg is at https://rt.cpan.org/Public/Dist/Display.html?Name=DBD-Pg. [image: @troogyt] <https://github.com/troogyt> Author * troogyt <https://github.com/troogyt> * commented 4 minutes ago <https://github.com/metacpan/metacpan-web/issues/2266#issuecomment-583709333> Thank you. I will email bug details to them. TG … <https://github.com/metacpan/metacpan-web/issues/2266#> [image: @troogyt] <https://github.com/troogyt> Author * troogyt <https://github.com/troogyt> * commented 1 minute ago <https://github.com/metacpan/metacpan-web/issues/2266#issuecomment-583709482> A little more info on the problem: [image: image] <https://user-images.githubusercontent.com/41710820/74080628-25557d00-4a9a-11ea-8c5e-87bcbab90d85.png> ============================================================================================= I have also added the additional ENV variables mentioned in the README: user@computer C:\Users\user Show quoted text
>set DB
DBI_DSN=dbi:Pg:dbname=testdb DBI_PASS=<OBFUSCATED> DBI_USER=postgres Many thanks, *troogyt*
Download (untitled) / with headers
text/html 17.2k

Message body is not shown because it is too large.

Download (untitled) / with headers
text/plain 228b
Thanks for the report: I have no idea offhand what is going on, but will try to dig into it later. For now, don't worry about the test database (testdb) or things like the port as we are not getting far enough to even use those.
Subject: Re: [rt.cpan.org #131708] BUG: 'cpan install DBD::Pg' fails looking for LIBPQ.dll
Date: Sun, 9 Feb 2020 13:54:36 +1100
To: bug-DBD-Pg [...] rt.cpan.org
From: "Stephen Dennis (Gmail)" <skeetabomb [...] gmail.com>

Message body is not shown because it is too large.

Download (untitled) / with headers
text/html 27.5k

Message body is not shown because it is too large.

Subject: Re: [rt.cpan.org #131708] BUG: 'cpan install DBD::Pg' fails looking for LIBPQ.dll
Date: Sun, 9 Feb 2020 14:02:42 +1100
To: bug-DBD-Pg [...] rt.cpan.org
From: "Stephen Dennis (Gmail)" <skeetabomb [...] gmail.com>
Download (untitled) / with headers
text/plain 31.8k

Message body is not shown because it is too large.

Download (untitled) / with headers
text/html 37.2k

Message body is not shown because it is too large.



This service is sponsored and maintained by Best Practical Solutions and runs on Perl.org infrastructure.

Please report any issues with rt.cpan.org to rt-cpan-admin@bestpractical.com.