Обсуждение: Problem with interfaces/ecpg/lib/Makefile.in in PostgreSQL 6.4.

Поиск
Список
Период
Сортировка

Problem with interfaces/ecpg/lib/Makefile.in in PostgreSQL 6.4.

От
"Billy G. Allie"
Дата:
The make file for interfaces/ecpg/lib cuased the following problem:

gmake[3]: *** No rule to make target `ecpglib.sho.o', needed by `libecpg.so.1'.

The following patch will fix the problem.  It works by removing the need for
the *.sho files, which seems to be only used to create the shared libraries.
These files are not needed since the ecpglib.o and typename.o files will be
built correctly for inclusion to the shared libraries because CFLAGS_SL are
added to CFLAGS if the systems is one of the systems supporting shared
libraries.


____       | Billy G. Allie    | Domain....: Bill.Allie@mug.org
|  /|      | 7436 Hartwell     | Compuserve: 76337,2061
|-/-|----- | Dearborn, MI 48126| MSN.......: B_G_Allie@email.msn.com
|/  |LLIE  | (313) 582-1540    |

Вложения

Re: [HACKERS] Problem with interfaces/ecpg/lib/Makefile.in in PostgreSQL 6.4.

От
Michael Meskes
Дата:
On Sat, Oct 17, 1998 at 02:29:06PM -0400, Billy G. Allie wrote:
> The make file for interfaces/ecpg/lib cuased the following problem:
>
> gmake[3]: *** No rule to make target `ecpglib.sho.o', needed by `libecpg.so.1'.

Is this still in there? I had a fix for this in m ylast patch.

> The following patch will fix the problem.  It works by removing the need for
> the *.sho files, which seems to be only used to create the shared libraries.

The *.sho are needed. It seems much easier to just remove the .o after the
.sho.

> These files are not needed since the ecpglib.o and typename.o files will be
> built correctly for inclusion to the shared libraries because CFLAGS_SL are
> added to CFLAGS if the systems is one of the systems supporting shared
> libraries.

I'm afraid that's not true. The .o files are for the static library. The .sho
files are compiled with -fpic instead so they are better suited for the
shared library.

Michael

--
Dr. Michael Meskes      | Th.-Heuss-Str. 61, D-41812 Erkelenz | Go SF49ers!
Senior-Consultant       | business: Michael.Meskes@mummert.de | Go Rhein Fire!
Mummert+Partner         |  private: Michael.Meskes@usa.net    | Use Debian
Unternehmensberatung AG |           Michael.Meskes@gmx.net    | GNU/Linux!

Re: [HACKERS] Problem with interfaces/ecpg/lib/Makefile.in in PostgreSQL 6.4.

От
"Billy G. Allie"
Дата:
On Sat, 17 Oct 1998 21:22:56 EDT, Michael Meskes wrote:
> On Sat, Oct 17, 1998 at 02:29:06PM -0400, Billy G. Allie wrote:
>    [...]
> > These files are not needed since the ecpglib.o and typename.o files will be
> > built correctly for inclusion to the shared libraries because CFLAGS_SL are
> > added to CFLAGS if the systems is one of the systems supporting shared
> > libraries.
>
> I'm afraid that's not true. The .o files are for the static library. The .sho
> files are compiled with -fpic instead so they are better suited for the
> shared library.
>

If the system is one that supports building shared libraries, then the
variable CFLAGS is modified as follows: CFLAGS += $(CFLAGS_SL).  This occurs
within the IF statement for setting up support for shared libraries for the
particular system.  Therefore, the *.o files are also compiled with the flag
for position independant code (PIC).  This does not affect there use in a
static library, but does make it possible to use them in the dynamic
libraries.  If the system for which postgreSQL is being built is not one of
the systems for which shared library support is included, then the *.o files
are compiled without the flag for PIC support.  So as I said, the *.sho files
not necessary.
--
____       | Billy G. Allie    | Domain....: Bill.Allie@mug.org
|  /|      | 7436 Hartwell     | Compuserve: 76337,2061
|-/-|----- | Dearborn, MI 48126| MSN.......: B_G_Allie@email.msn.com
|/  |LLIE  | (313) 582-1540    |



Re: [HACKERS] Problem with interfaces/ecpg/lib/Makefile.in in PostgreSQL 6.4.

От
Michael Meskes
Дата:
On Sat, Oct 17, 1998 at 07:18:22PM -0400, Billy G. Allie wrote:
> If the system is one that supports building shared libraries, then the 
> variable CFLAGS is modified as follows: CFLAGS += $(CFLAGS_SL).  This occurs 
> within the IF statement for setting up support for shared libraries for the 
> particular system.  Therefore, the *.o files are also compiled with the flag 
> for position independant code (PIC).  This does not affect there use in a 

Correct so far.

> static library, but does make it possible to use them in the dynamic 
> libraries.  If the system for which postgreSQL is being built is not one of 

Yes, they can be used. But the static library is better off without the
-fpic flag.

Michael

-- 
Dr. Michael Meskes      | Th.-Heuss-Str. 61, D-41812 Erkelenz | Go SF49ers!
Senior-Consultant       | business: Michael.Meskes@mummert.de | Go Rhein Fire!
Mummert+Partner         |  private: Michael.Meskes@usa.net    | Use Debian
Unternehmensberatung AG |           Michael.Meskes@gmx.net    | GNU/Linux!