~ubuntu-branches/ubuntu/oneiric/postgresql-9.1/oneiric-security

« back to all changes in this revision

Viewing changes to src/backend/catalog/Makefile

  • Committer: Bazaar Package Importer
  • Author(s): Martin Pitt
  • Date: 2011-05-11 10:41:53 UTC
  • Revision ID: james.westby@ubuntu.com-20110511104153-psbh2o58553fv1m0
Tags: upstream-9.1~beta1
ImportĀ upstreamĀ versionĀ 9.1~beta1

Show diffs side-by-side

added added

removed removed

Lines of Context:
 
1
#-------------------------------------------------------------------------
 
2
#
 
3
# Makefile for backend/catalog
 
4
#
 
5
# src/backend/catalog/Makefile
 
6
#
 
7
#-------------------------------------------------------------------------
 
8
 
 
9
subdir = src/backend/catalog
 
10
top_builddir = ../../..
 
11
include $(top_builddir)/src/Makefile.global
 
12
 
 
13
OBJS = catalog.o dependency.o heap.o index.o indexing.o namespace.o aclchk.o \
 
14
       objectaddress.o pg_aggregate.o pg_collation.o pg_constraint.o pg_conversion.o \
 
15
       pg_depend.o pg_enum.o pg_inherits.o pg_largeobject.o pg_namespace.o \
 
16
       pg_operator.o pg_proc.o pg_db_role_setting.o pg_shdepend.o pg_type.o \
 
17
       storage.o toasting.o
 
18
 
 
19
BKIFILES = postgres.bki postgres.description postgres.shdescription
 
20
 
 
21
include $(top_srcdir)/src/backend/common.mk
 
22
 
 
23
all: $(BKIFILES) schemapg.h
 
24
 
 
25
# Note: there are some undocumented dependencies on the ordering in which
 
26
# the catalog header files are assembled into postgres.bki.  In particular,
 
27
# indexing.h had better be last, and toasting.h just before it.
 
28
 
 
29
POSTGRES_BKI_SRCS = $(addprefix $(top_srcdir)/src/include/catalog/,\
 
30
        pg_proc.h pg_type.h pg_attribute.h pg_class.h \
 
31
        pg_attrdef.h pg_constraint.h pg_inherits.h pg_index.h pg_operator.h \
 
32
        pg_opfamily.h pg_opclass.h pg_am.h pg_amop.h pg_amproc.h \
 
33
        pg_language.h pg_largeobject_metadata.h pg_largeobject.h pg_aggregate.h \
 
34
        pg_statistic.h pg_rewrite.h pg_trigger.h pg_description.h \
 
35
        pg_cast.h pg_enum.h pg_namespace.h pg_conversion.h pg_depend.h \
 
36
        pg_database.h pg_db_role_setting.h pg_tablespace.h pg_pltemplate.h \
 
37
        pg_authid.h pg_auth_members.h pg_shdepend.h pg_shdescription.h \
 
38
        pg_ts_config.h pg_ts_config_map.h pg_ts_dict.h \
 
39
        pg_ts_parser.h pg_ts_template.h pg_extension.h \
 
40
        pg_foreign_data_wrapper.h pg_foreign_server.h pg_user_mapping.h \
 
41
        pg_foreign_table.h \
 
42
        pg_default_acl.h pg_seclabel.h pg_collation.h \
 
43
        toasting.h indexing.h \
 
44
    )
 
45
 
 
46
# location of Catalog.pm
 
47
catalogdir = $(top_srcdir)/src/backend/catalog
 
48
 
 
49
# locations of headers that genbki.pl needs to read
 
50
pg_includes = -I$(top_srcdir)/src/include/catalog -I$(top_builddir)/src/include/catalog
 
51
 
 
52
# see explanation in ../parser/Makefile
 
53
postgres.description: postgres.bki ;
 
54
 
 
55
postgres.shdescription: postgres.bki ;
 
56
 
 
57
schemapg.h: postgres.bki ;
 
58
 
 
59
postgres.bki: genbki.pl Catalog.pm $(POSTGRES_BKI_SRCS)
 
60
        $(PERL) -I $(catalogdir) $< $(pg_includes) --set-version=$(MAJORVERSION) $(POSTGRES_BKI_SRCS)
 
61
 
 
62
.PHONY: install-data
 
63
install-data: $(BKIFILES) installdirs
 
64
        $(INSTALL_DATA) $(call vpathsearch,postgres.bki) '$(DESTDIR)$(datadir)/postgres.bki'
 
65
        $(INSTALL_DATA) $(call vpathsearch,postgres.description) '$(DESTDIR)$(datadir)/postgres.description'
 
66
        $(INSTALL_DATA) $(call vpathsearch,postgres.shdescription) '$(DESTDIR)$(datadir)/postgres.shdescription'
 
67
        $(INSTALL_DATA) $(srcdir)/system_views.sql '$(DESTDIR)$(datadir)/system_views.sql'
 
68
        $(INSTALL_DATA) $(srcdir)/information_schema.sql '$(DESTDIR)$(datadir)/information_schema.sql'
 
69
        $(INSTALL_DATA) $(srcdir)/sql_features.txt '$(DESTDIR)$(datadir)/sql_features.txt'
 
70
 
 
71
installdirs:
 
72
        $(MKDIR_P) '$(DESTDIR)$(datadir)'
 
73
 
 
74
.PHONY: uninstall-data
 
75
uninstall-data:
 
76
        rm -f $(addprefix '$(DESTDIR)$(datadir)'/, $(BKIFILES) system_views.sql information_schema.sql sql_features.txt)
 
77
 
 
78
# postgres.bki, postgres.description, postgres.shdescription, and schemapg.h
 
79
# are in the distribution tarball, so they are not cleaned here.
 
80
clean:
 
81
 
 
82
maintainer-clean: clean
 
83
        rm -f $(BKIFILES)