]> TLD Linux GIT Repositories - packages/postgresql.git/blob - per-version-dirs.patch
- release 4
[packages/postgresql.git] / per-version-dirs.patch
1 diff -urpa postgresql-9.3.24.orig/src/bin/pg_config/pg_config.c postgresql-9.3.24/src/bin/pg_config/pg_config.c
2 --- postgresql-9.3.24.orig/src/bin/pg_config/pg_config.c        2018-08-23 19:56:17.187401335 +0000
3 +++ postgresql-9.3.24/src/bin/pg_config/pg_config.c     2018-08-23 19:56:33.221401154 +0000
4 @@ -26,6 +26,8 @@
5  
6  #include "port.h"
7  
8 +#include "../port/pg_config_paths.h"
9 +
10  static const char *progname;
11  static char mypath[MAXPGPATH];
12  
13 @@ -481,7 +483,6 @@ main(int argc, char **argv)
14  {
15         int                     i;
16         int                     j;
17 -       int                     ret;
18  
19         set_pglocale_pgservice(argv[0], PG_TEXTDOMAIN("pg_config"));
20  
21 @@ -497,13 +498,7 @@ main(int argc, char **argv)
22                 }
23         }
24  
25 -       ret = find_my_exec(argv[0], mypath);
26 -
27 -       if (ret)
28 -       {
29 -               fprintf(stderr, _("%s: could not find own program executable\n"), progname);
30 -               exit(1);
31 -       }
32 +       snprintf(mypath, sizeof(mypath), "%s/%s", PGBINDIR, progname);
33  
34         /* no arguments -> print everything */
35         if (argc < 2)
36 diff -urpa postgresql-9.3.24.orig/src/Makefile.global.in postgresql-9.3.24/src/Makefile.global.in
37 --- postgresql-9.3.24.orig/src/Makefile.global.in       2018-08-23 19:56:17.183401335 +0000
38 +++ postgresql-9.3.24/src/Makefile.global.in    2018-08-23 19:56:33.221401154 +0000
39 @@ -100,7 +100,7 @@ libdir := @libdir@
40  pkglibdir = $(libdir)
41  ifeq "$(findstring pgsql, $(pkglibdir))" ""
42  ifeq "$(findstring postgres, $(pkglibdir))" ""
43 -override pkglibdir := $(pkglibdir)/postgresql
44 +override pkglibdir := $(pkglibdir)/postgresql/@PG_MAJORVERSION@/lib
45  endif
46  endif
47  
48 @@ -148,7 +148,7 @@ endif # PGXS
49  
50  # These derived path variables aren't separately configurable.
51  
52 -includedir_server = $(pkgincludedir)/server
53 +includedir_server = $(pkgincludedir)/@PG_MAJORVERSION@/server
54  includedir_internal = $(pkgincludedir)/internal
55  pgxsdir = $(pkglibdir)/pgxs
56