Move pg_test_timing from contrib/ to src/bin/
authorPeter Eisentraut <[email protected]>
Wed, 11 Mar 2015 02:33:24 +0000 (22:33 -0400)
committerPeter Eisentraut <[email protected]>
Tue, 21 Apr 2015 01:30:12 +0000 (21:30 -0400)
Reviewed-by: Michael Paquier <[email protected]>
12 files changed:
contrib/Makefile
contrib/pg_test_timing/Makefile [deleted file]
doc/src/sgml/contrib.sgml
doc/src/sgml/filelist.sgml
doc/src/sgml/ref/allfiles.sgml
doc/src/sgml/ref/pgtesttiming.sgml [moved from doc/src/sgml/pgtesttiming.sgml with 98% similarity]
doc/src/sgml/reference.sgml
src/bin/Makefile
src/bin/pg_test_timing/.gitignore [moved from contrib/pg_test_timing/.gitignore with 100% similarity]
src/bin/pg_test_timing/Makefile [new file with mode: 0644]
src/bin/pg_test_timing/pg_test_timing.c [moved from contrib/pg_test_timing/pg_test_timing.c with 100% similarity]
src/tools/msvc/Mkvcbuild.pm

index 9ca1ed707a00d1f67463b518a772aa2ca85e8dac..e5ce0be5fd4a61652676a36a978b831173c42ccf 100644 (file)
@@ -33,7 +33,6 @@ SUBDIRS = \
                pg_prewarm      \
                pg_standby      \
                pg_stat_statements \
-               pg_test_timing  \
                pg_trgm         \
                pgcrypto        \
                pgrowlocks      \
diff --git a/contrib/pg_test_timing/Makefile b/contrib/pg_test_timing/Makefile
deleted file mode 100644 (file)
index 8b37aa8..0000000
+++ /dev/null
@@ -1,18 +0,0 @@
-# contrib/pg_test_timing/Makefile
-
-PGFILEDESC = "pg_test_timing - test timing overhead"
-PGAPPICON = win32
-
-PROGRAM  = pg_test_timing
-OBJS = pg_test_timing.o $(WIN32RES)
-
-ifdef USE_PGXS
-PG_CONFIG = pg_config
-PGXS := $(shell $(PG_CONFIG) --pgxs)
-include $(PGXS)
-else
-subdir = contrib/pg_test_timing
-top_builddir = ../..
-include $(top_builddir)/src/Makefile.global
-include $(top_srcdir)/contrib/contrib-global.mk
-endif
index b25d18b344ad170980b6e0a0cd24923a6c42bc60..29e4f2df9b51bf3301878e84b60ff8c670b6b106 100644 (file)
@@ -202,7 +202,6 @@ pages.
   </para>
 
  &pgstandby;
- &pgtesttiming;
  &pgxlogdump;
  </sect1>
 </appendix>
index 5095e0fce2aaa88ce29ad239eec38c36afcb81b9..2f4896d4ce3e9856f35ac02fda6995512e9dc8a9 100644 (file)
 <!ENTITY pgstandby       SYSTEM "pgstandby.sgml">
 <!ENTITY pgstatstatements SYSTEM "pgstatstatements.sgml">
 <!ENTITY pgstattuple     SYSTEM "pgstattuple.sgml">
-<!ENTITY pgtesttiming    SYSTEM "pgtesttiming.sgml">
 <!ENTITY pgtrgm          SYSTEM "pgtrgm.sgml">
 <!ENTITY pgxlogdump      SYSTEM "pg_xlogdump.sgml">
 <!ENTITY postgres-fdw    SYSTEM "postgres-fdw.sgml">
index e940153540ee6179a12af27466be1b27b0e022f8..0e0a1f4f462e7f94d19f1b5c4092c06d75fdd19a 100644 (file)
@@ -194,6 +194,7 @@ Complete list of usable sgml source files in this directory.
 <!ENTITY pgRestore          SYSTEM "pg_restore.sgml">
 <!ENTITY pgRewind           SYSTEM "pg_rewind.sgml">
 <!ENTITY pgtestfsync        SYSTEM "pgtestfsync.sgml">
+<!ENTITY pgtesttiming       SYSTEM "pgtesttiming.sgml">
 <!ENTITY pgupgrade          SYSTEM "pgupgrade.sgml">
 <!ENTITY postgres           SYSTEM "postgres-ref.sgml">
 <!ENTITY postmaster         SYSTEM "postmaster.sgml">
similarity index 98%
rename from doc/src/sgml/pgtesttiming.sgml
rename to doc/src/sgml/ref/pgtesttiming.sgml
index a6ab9b114bb1bd5e3b2b360fe3faf15ead618e82..d5e231fff7bc1f977b9c52be803d8e56d42d6937 100644 (file)
@@ -1,4 +1,4 @@
-<!-- doc/src/sgml/pgtesttiming.sgml -->
+<!-- doc/src/sgml/ref/pgtesttiming.sgml -->
 
 <refentry id="pgtesttiming">
  <indexterm zone="pgtesttiming">
@@ -290,14 +290,6 @@ Histogram of timing durations:
   </refsect2>
  </refsect1>
 
- <refsect1>
-  <title>Author</title>
-
-  <para>
-   Ants Aasma <email>[email protected]</email>
-  </para>
- </refsect1>
-
  <refsect1>
   <title>See Also</title>
 
index 666493cd64010fad06a5c6325ac28ec6758647f1..a526638ec9bd0c6c2d3e4350b2fc77c0175df4e3 100644 (file)
    &pgResetxlog;
    &pgRewind;
    &pgtestfsync;
+   &pgtesttiming;
    &pgupgrade;
    &postgres;
    &postmaster;
index 06a0ab75b6b120fb56257c848b6a2b79f00ec4a0..d23c95c581c42bc6a3513b492235a831153aabc8 100644 (file)
@@ -24,6 +24,7 @@ SUBDIRS = \
        pg_resetxlog \
        pg_rewind \
        pg_test_fsync \
+       pg_test_timing \
        pg_upgrade \
        pgbench \
        psql \
diff --git a/src/bin/pg_test_timing/Makefile b/src/bin/pg_test_timing/Makefile
new file mode 100644 (file)
index 0000000..d1f3595
--- /dev/null
@@ -0,0 +1,27 @@
+# src/bin/pg_test_timing/Makefile
+
+PGFILEDESC = "pg_test_timing - test timing overhead"
+PGAPPICON = win32
+
+subdir = src/bin/pg_test_timing
+top_builddir = ../../..
+include $(top_builddir)/src/Makefile.global
+
+OBJS = pg_test_timing.o $(WIN32RES)
+
+all: pg_test_timing
+
+pg_test_timing: $(OBJS) | submake-libpgport
+       $(CC) $(CFLAGS) $^ $(LDFLAGS) $(LDFLAGS_EX) $(LIBS) -o $@$(X)
+
+install: all installdirs
+       $(INSTALL_PROGRAM) pg_test_timing$(X) '$(DESTDIR)$(bindir)/pg_test_timing$(X)'
+
+installdirs:
+       $(MKDIR_P) '$(DESTDIR)$(bindir)'
+
+uninstall:
+       rm -f '$(DESTDIR)$(bindir)/pg_test_timing$(X)'
+
+clean distclean maintainer-clean:
+       rm -f pg_test_timing$(X) $(OBJS)
index 5b86c805ae6ad29bba13cf0971b3b7001dbafa9f..6dd429a8b68efe12e210fb432dfb34e448f8c6e6 100644 (file)
@@ -35,13 +35,11 @@ my @contrib_uselibpq =
 my @contrib_uselibpgport = (
        'oid2name',
        'pg_standby',
-       'pg_test_timing',
        'pg_xlogdump',
        'vacuumlo');
 my @contrib_uselibpgcommon = (
        'oid2name',
        'pg_standby',
-       'pg_test_timing',
        'pg_xlogdump',
        'vacuumlo');
 my $contrib_extralibs = undef;
@@ -55,8 +53,8 @@ my @contrib_excludes = ('pgcrypto', 'commit_ts', 'intagg', 'sepgsql');
 # Set of variables for frontend modules
 my $frontend_defines = { 'initdb' => 'FRONTEND' };
 my @frontend_uselibpq = ('pg_ctl', 'pg_upgrade', 'pgbench', 'psql');
-my @frontend_uselibpgport = ( 'pg_archivecleanup', 'pg_test_fsync', 'pg_upgrade', 'pgbench' );
-my @frontend_uselibpgcommon = ( 'pg_archivecleanup', 'pg_test_fsync', 'pg_upgrade', 'pgbench' );
+my @frontend_uselibpgport = ( 'pg_archivecleanup', 'pg_test_fsync', 'pg_test_timing', 'pg_upgrade', 'pgbench' );
+my @frontend_uselibpgcommon = ( 'pg_archivecleanup', 'pg_test_fsync', 'pg_test_timing', 'pg_upgrade', 'pgbench' );
 my $frontend_extralibs = {
        'initdb'     => ['ws2_32.lib'],
        'pg_restore' => ['ws2_32.lib'],