pg.ddx.io  pgsql-committers@postgresql.org mailing list archive  
help / color / mirror / Atom feed
pgsql: Move pg_crc.c to src/common, and remove pg_crc_tables.h
3+ messages / 3 participants
[nested] [flat]

* pgsql: Move pg_crc.c to src/common, and remove pg_crc_tables.h
@ 2015-02-09 09:18  Heikki Linnakangas <heikki.linnakangas@iki.fi>
  0 siblings, 1 reply; 3+ messages in thread

From: Heikki Linnakangas @ 2015-02-09 09:18 UTC (permalink / raw)
  To: pgsql-committers

Move pg_crc.c to src/common, and remove pg_crc_tables.h

To get CRC functionality in a client program, you now need to link with
libpgcommon instead of libpgport. The CRC code has nothing to do with
portability, so libpgcommon is a better home. (libpgcommon didn't exist
when pg_crc.c was originally moved to src/port.)

Remove the possibility to get CRC functionality by just #including
pg_crc_tables.h. I'm not aware of any extensions that actually did that and
couldn't simply link with libpgcommon.

This also moves the pg_crc.h header file from src/include/utils to
src/include/common, which will require changes to any external programs
that currently does #include "utils/pg_crc.h". That seems acceptable, as
include/common is clearly the right home for it now, and the change needed
to any such programs is trivial.

Branch
------
master

Details
-------
http://git.postgresql.org/pg/commitdiff/c619c2351f7ec429b6ddce519c939f7b8465d711

Modified Files
--------------
contrib/hstore/hstore_gist.c      |    2 +-
contrib/ltree/crc32.c             |    2 +-
src/backend/utils/adt/tsquery.c   |    1 +
src/common/Makefile               |    2 +-
src/common/pg_crc.c               |  166 +++++++++++++++++++++++++++++++++++
src/include/access/xlogrecord.h   |    2 +-
src/include/catalog/pg_control.h  |    2 +-
src/include/common/pg_crc.h       |  121 ++++++++++++++++++++++++++
src/include/tsearch/ts_type.h     |    1 -
src/include/utils/pg_crc.h        |  121 --------------------------
src/include/utils/pg_crc_tables.h |  171 -------------------------------------
src/port/Makefile                 |    2 +-
src/port/pg_crc.c                 |   21 -----
13 files changed, 294 insertions(+), 320 deletions(-)


-- 
Sent via pgsql-committers mailing list (pgsql-committers@postgresql.org)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-committers


^ permalink  raw  reply  [nested|flat] 3+ messages in thread

* Re: pgsql: Move pg_crc.c to src/common, and remove pg_crc_tables.h
@ 2015-02-09 11:27  Michael Paquier <michael.paquier@gmail.com>
  parent: Heikki Linnakangas <heikki.linnakangas@iki.fi>
  0 siblings, 1 reply; 3+ messages in thread

From: Michael Paquier @ 2015-02-09 11:27 UTC (permalink / raw)
  To: Heikki Linnakangas <heikki.linnakangas@iki.fi>; +Cc: pgsql-committers

On Mon, Feb 9, 2015 at 6:18 PM, Heikki Linnakangas
<heikki.linnakangas@iki.fi> wrote:
> Move pg_crc.c to src/common, and remove pg_crc_tables.h
> (snip)
> contrib/hstore/hstore_gist.c      |    2 +-
> contrib/ltree/crc32.c             |    2 +-
> src/backend/utils/adt/tsquery.c   |    1 +
> src/common/Makefile               |    2 +-
> src/common/pg_crc.c               |  166 +++++++++++++++++++++++++++++++++++
> src/include/access/xlogrecord.h   |    2 +-
> src/include/catalog/pg_control.h  |    2 +-
> src/include/common/pg_crc.h       |  121 ++++++++++++++++++++++++++
> src/include/tsearch/ts_type.h     |    1 -
> src/include/utils/pg_crc.h        |  121 --------------------------
> src/include/utils/pg_crc_tables.h |  171 -------------------------------------
> src/port/Makefile                 |    2 +-
> src/port/pg_crc.c                 |   21 -----
> 13 files changed, 294 insertions(+), 320 deletions(-)

This commit is not updating the MSVC scripts. In Mkvcbuild.pm,
pg_crc.c should be moved from pgportfiles to pgcommonallfiles.
-- 
Michael


-- 
Sent via pgsql-committers mailing list (pgsql-committers@postgresql.org)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-committers



^ permalink  raw  reply  [nested|flat] 3+ messages in thread

* Re: pgsql: Move pg_crc.c to src/common, and remove pg_crc_tables.h
@ 2015-02-09 20:25  Heikki Linnakangas <hlinnakangas@vmware.com>
  parent: Michael Paquier <michael.paquier@gmail.com>
  0 siblings, 0 replies; 3+ messages in thread

From: Heikki Linnakangas @ 2015-02-09 20:25 UTC (permalink / raw)
  To: Michael Paquier <michael.paquier@gmail.com>; +Cc: pgsql-committers

On 02/09/2015 01:27 PM, Michael Paquier wrote:
> On Mon, Feb 9, 2015 at 6:18 PM, Heikki Linnakangas
> <heikki.linnakangas@iki.fi> wrote:
>> Move pg_crc.c to src/common, and remove pg_crc_tables.h
>> (snip)
>> contrib/hstore/hstore_gist.c      |    2 +-
>> contrib/ltree/crc32.c             |    2 +-
>> src/backend/utils/adt/tsquery.c   |    1 +
>> src/common/Makefile               |    2 +-
>> src/common/pg_crc.c               |  166 +++++++++++++++++++++++++++++++++++
>> src/include/access/xlogrecord.h   |    2 +-
>> src/include/catalog/pg_control.h  |    2 +-
>> src/include/common/pg_crc.h       |  121 ++++++++++++++++++++++++++
>> src/include/tsearch/ts_type.h     |    1 -
>> src/include/utils/pg_crc.h        |  121 --------------------------
>> src/include/utils/pg_crc_tables.h |  171 -------------------------------------
>> src/port/Makefile                 |    2 +-
>> src/port/pg_crc.c                 |   21 -----
>> 13 files changed, 294 insertions(+), 320 deletions(-)
>
> This commit is not updating the MSVC scripts. In Mkvcbuild.pm,
> pg_crc.c should be moved from pgportfiles to pgcommonallfiles.

Ah, fixed, thanks!

- Heikki


-- 
Sent via pgsql-committers mailing list (pgsql-committers@postgresql.org)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-committers



^ permalink  raw  reply  [nested|flat] 3+ messages in thread


end of thread, other threads:[~2015-02-09 20:25 UTC | newest]

Thread overview: 3+ messages (download: mbox mbox.gz follow: Atom feed)
-- links below jump to the message on this page --
2015-02-09 09:18 pgsql: Move pg_crc.c to src/common, and remove pg_crc_tables.h Heikki Linnakangas <heikki.linnakangas@iki.fi>
2015-02-09 11:27 ` Michael Paquier <michael.paquier@gmail.com>
2015-02-09 20:25   ` Heikki Linnakangas <hlinnakangas@vmware.com>

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