pg.ddx.io  pgsql-general@postgresql.org mailing list archive  
help / color / mirror / Atom feed
From: Rob Sargent <robjsargent@gmail.com>
To: William Torrez Corea <willitc9888@gmail.com>
Cc: pgsql-general@lists.postgresql.org
Subject: Re: collect2: error: ld returned 1 exit status
Date: Sat, 26 Nov 2022 16:24:55 -0700
Message-ID: <A547C5F4-BF42-424F-AF85-BF8994BAF16D@gmail.com> (raw)
In-Reply-To: <CAGiORHfFmxqqwdodLA31D-sgUsoueDAtp+3RxxC3aG9RhpHL4w@mail.gmail.com>
References: <CAGiORHfFmxqqwdodLA31D-sgUsoueDAtp+3RxxC3aG9RhpHL4w@mail.gmail.com>


--Apple-Mail-63EC68A3-3280-462A-B2BF-9CCAFE9C3163
Content-Type: text/html;
	charset=utf-8
Content-Transfer-Encoding: quoted-printable

<html><head><meta http-equiv=3D"content-type" content=3D"text/html; charset=3D=
utf-8"></head><body dir=3D"auto"><div dir=3D"ltr"></div><div dir=3D"ltr"><br=
></div><div dir=3D"ltr"><div dir=3D"ltr"><blockquote type=3D"cite">On Nov 26=
, 2022, at 4:17 PM, William Torrez Corea &lt;willitc9888@gmail.com&gt; wrote=
:<br><br></blockquote></div><blockquote type=3D"cite"><div dir=3D"ltr">=EF=BB=
=BF<div dir=3D"ltr"><div dir=3D"ltr"><br></div><br><div class=3D"gmail_quote=
"><div dir=3D"ltr" class=3D"gmail_attr">On Sat, Nov 26, 2022 at 5:00 PM Rob S=
argent &lt;<a href=3D"mailto:robjsargent@gmail.com">robjsargent@gmail.com</a=
>&gt; wrote:<br></div><blockquote class=3D"gmail_quote" style=3D"margin: 0px=
 0px 0px 0.8ex; border-left-color: rgb(204, 204, 204); padding-left: 1ex;"><=
div dir=3D"auto"><div dir=3D"ltr"></div><div dir=3D"ltr"><br></div><div dir=3D=
"ltr"><br><blockquote type=3D"cite">On Nov 26, 2022, at 3:43 PM, William Tor=
rez Corea &lt;<a href=3D"mailto:willitc9888@gmail.com" target=3D"_blank">wil=
litc9888@gmail.com</a>&gt; wrote:<br><br></blockquote></div><blockquote type=
=3D"cite"><div dir=3D"ltr">=EF=BB=BF<div dir=3D"ltr"><div>I am using libpq: t=
he C application programmer's interface to PostgreSQL.&nbsp;<br></div><div><=
br></div><div>Compile the code:<br></div><div><br></div><blockquote class=3D=
"gmail_quote" style=3D"margin: 0px 0px 0px 0.8ex; border-left-color: rgb(204=
, 204, 204); padding-left: 1ex;"><b>sudo cc -o testprog testprog1.o testprog=
2.o -L/usr/local/pgsql/lib -lpq<br></b></blockquote><div><br></div><div>But i=
 get the following error:</div><div><br></div><blockquote class=3D"gmail_quo=
te" style=3D"margin: 0px 0px 0px 0.8ex; border-left-color: rgb(204, 204, 204=
); padding-left: 1ex;"><b>collect2: error: ld returned 1 exit status</b><br>=
</blockquote><div><br>--&nbsp;</div><div><br></div></div></div></blockquote>=
</div></blockquote></div></div></div></blockquote></div><div dir=3D"ltr">And=
 do you have at hand why the loader (ld) failed?</div><blockquote type=3D"ci=
te"><div dir=3D"ltr"><div dir=3D"ltr"><div class=3D"gmail_quote"><blockquote=
 class=3D"gmail_quote" style=3D"margin:0px 0px 0px 0.8ex;border-left:1px sol=
id rgb(204,204,204);padding-left:1ex"><div dir=3D"auto"><blockquote type=3D"=
cite"><div dir=3D"ltr"><div dir=3D"ltr"><div><div dir=3D"ltr"><br></div></di=
v></div>
</div></blockquote></div></blockquote></div><br clear=3D"all">Package libpq w=
as not found in the pkg-config search path.<br>Perhaps you should add the di=
rectory containing `libpq.pc'<br>to the PKG_CONFIG_PATH environment variable=
<br>No package 'libpq' found<br><br>-- <br></div></div></blockquote><div><br=
></div>So libpq is not in&nbsp;<b>-L/usr/local/pgsql/lib ?</b>&nbsp;Do you k=
now that libpq is installed? &nbsp;You may need to use the Debian package in=
staller to get the =E2=80=9Cdev=E2=80=9D environment&nbsp;<blockquote type=3D=
"cite"><div dir=3D"ltr"><div dir=3D"ltr"><div dir=3D"ltr" class=3D"gmail_sig=
nature"><br>With kindest regards, William.<br><br>=E2=A2=80=E2=A3=B4=E2=A0=BE=
=E2=A0=BB=E2=A2=B6=E2=A3=A6=E2=A0=80 <br>=E2=A3=BE=E2=A0=81=E2=A2=A0=E2=A0=92=
=E2=A0=80=E2=A3=BF=E2=A1=81 Debian - The universal operating system<br>=E2=A2=
=BF=E2=A1=84=E2=A0=98=E2=A0=B7=E2=A0=9A=E2=A0=8B=E2=A0=80 <a href=3D"https:/=
/www.debian.org" target=3D"_blank">https://www.debian.org</a><br>=E2=A0=88=E2=
=A0=B3=E2=A3=84=E2=A0=80=E2=A0=80=E2=A0=80=E2=A0=80 <br><br><br></div></div>=

</div></blockquote></body></html>=

--Apple-Mail-63EC68A3-3280-462A-B2BF-9CCAFE9C3163--





view thread (8+ messages)  latest in thread

Message-ID: <A547C5F4-BF42-424F-AF85-BF8994BAF16D@gmail.com>
Permalink:  ../A547C5F4-BF42-424F-AF85-BF8994BAF16D@gmail.com/
Also on:    postgresql.org/message-id/A547C5F4-BF42-424F-AF85-BF8994BAF16D@gmail.com

 · 

reply

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Reply to all the recipients from your mail client; the link fills in
  the headers below: reply via email
  Some clients, webmail especially, drop In-Reply-To and References from
  a link, and the reply then starts a new thread: use the mbox below.

  To: pgsql-general@postgresql.org
  Cc: robjsargent@gmail.com, willitc9888@gmail.com
  Subject: Re: collect2: error: ld returned 1 exit status
  In-Reply-To: <A547C5F4-BF42-424F-AF85-BF8994BAF16D@gmail.com>
  References: <CAGiORHfFmxqqwdodLA31D-sgUsoueDAtp+3RxxC3aG9RhpHL4w@mail.gmail.com> <A547C5F4-BF42-424F-AF85-BF8994BAF16D@gmail.com>

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

This inbox is served by DDX for PostgreSQL; see mirroring instructions
for how to clone and mirror all data and code used for this inbox