aboutsummaryrefslogtreecommitdiff
path: root/src/port
diff options
context:
space:
mode:
Diffstat (limited to 'src/port')
-rw-r--r--src/port/Makefile4
-rw-r--r--src/port/path.c38
2 files changed, 38 insertions, 4 deletions
diff --git a/src/port/Makefile b/src/port/Makefile
index 4684cb024e4..dc2ddee3e6a 100644
--- a/src/port/Makefile
+++ b/src/port/Makefile
@@ -7,7 +7,7 @@
# with broken/missing library files.
# IDENTIFICATION
-# $PostgreSQL: pgsql/src/port/Makefile,v 1.15 2004/05/30 14:07:47 momjian Exp $
+# $PostgreSQL: pgsql/src/port/Makefile,v 1.16 2004/08/01 06:56:39 momjian Exp $
#
#-------------------------------------------------------------------------
@@ -35,6 +35,8 @@ pg_config_paths.h: $(top_builddir)/src/Makefile.global
echo "#define SYSCONFDIR \"$(sysconfdir)\"" >>$@
echo "#define INCLUDEDIR \"$(includedir)\"" >>$@
echo "#define PKGINCLUDEDIR \"$(pkgincludedir)\"" >>$@
+ echo "#define INCLUDEDIRSERVER \"$(includedir_server)\"" >>$@
+ echo "#define LIBDIR \"$(libdir)\"" >>$@
echo "#define PKGLIBDIR \"$(pkglibdir)\"" >>$@
echo "#define LOCALEDIR \"$(localedir)\"" >>$@
diff --git a/src/port/path.c b/src/port/path.c
index aaecf33f741..1e45a8f3e2c 100644
--- a/src/port/path.c
+++ b/src/port/path.c
@@ -8,7 +8,7 @@
*
*
* IDENTIFICATION
- * $PostgreSQL: pgsql/src/port/path.c,v 1.25 2004/07/12 19:27:31 momjian Exp $
+ * $PostgreSQL: pgsql/src/port/path.c,v 1.26 2004/08/01 06:56:39 momjian Exp $
*
*-------------------------------------------------------------------------
*/
@@ -206,9 +206,41 @@ get_pkginclude_path(const char *my_exec_path, char *ret_path)
/*
+ * get_includeserver_path
+ */
+void
+get_includeserver_path(const char *my_exec_path, char *ret_path)
+{
+ const char *p;
+
+ if ((p = relative_path(PGBINDIR, INCLUDEDIRSERVER)))
+ make_relative(my_exec_path, p, ret_path);
+ else
+ StrNCpy(ret_path, INCLUDEDIRSERVER, MAXPGPATH);
+ canonicalize_path(ret_path);
+}
+
+
+
+/*
+ * get_lib_path
+ */
+void
+get_lib_path(const char *my_exec_path, char *ret_path)
+{
+ const char *p;
+
+ if ((p = relative_path(PGBINDIR, LIBDIR)))
+ make_relative(my_exec_path, p, ret_path);
+ else
+ StrNCpy(ret_path, LIBDIR, MAXPGPATH);
+ canonicalize_path(ret_path);
+}
+
+
+
+/*
* get_pkglib_path
- *
- * Return library path, either relative to /bin or hardcoded
*/
void
get_pkglib_path(const char *my_exec_path, char *ret_path)