aboutsummaryrefslogtreecommitdiffstats
path: root/devel
diff options
context:
space:
mode:
authorade <ade@FreeBSD.org>2002-03-13 06:37:52 +0800
committerade <ade@FreeBSD.org>2002-03-13 06:37:52 +0800
commita42f0a71658b4afca035a3594d82306425c0a31c (patch)
tree65df51db84db52a1fbd5152c0209fb808eec1ebe /devel
parentf2498715475847a6df00cde0136d58d05e0257fb (diff)
downloadfreebsd-ports-gnome-a42f0a71658b4afca035a3594d82306425c0a31c.tar.gz
freebsd-ports-gnome-a42f0a71658b4afca035a3594d82306425c0a31c.tar.zst
freebsd-ports-gnome-a42f0a71658b4afca035a3594d82306425c0a31c.zip
On -stable anyway, there is a problem getting "other" libs and cflags from
dependency packages (for example, from gthread-2.0). This prevents ports like ORbit2 from compiling. It seems to be a pretty serious oversight on the pkgconfig folks, so I'm going to submit this patch to them. Basically, this patch adds recursive scanning capabilities to the other_cflags and other_libs functions. PR: 35831 Submitted by: Joe Clarke <marcus@marcuscom.com>
Diffstat (limited to 'devel')
-rw-r--r--devel/pkg-config/Makefile1
-rw-r--r--devel/pkg-config/files/patch-pkg.c61
-rw-r--r--devel/pkgconfig/Makefile1
-rw-r--r--devel/pkgconfig/files/patch-pkg.c61
4 files changed, 102 insertions, 22 deletions
diff --git a/devel/pkg-config/Makefile b/devel/pkg-config/Makefile
index 13b7c5a5a734..b966b6eaefca 100644
--- a/devel/pkg-config/Makefile
+++ b/devel/pkg-config/Makefile
@@ -7,6 +7,7 @@
PORTNAME= pkgconfig
PORTVERSION= 0.11.0
+PORTREVISION= 1
CATEGORIES= devel
MASTER_SITES= ${MASTER_SITE_GNOME}
MASTER_SITE_SUBDIR= pre-gnome2/releases/gnome-2.0-desktop-beta2
diff --git a/devel/pkg-config/files/patch-pkg.c b/devel/pkg-config/files/patch-pkg.c
index 3bf9b3f766bf..1284af1949e2 100644
--- a/devel/pkg-config/files/patch-pkg.c
+++ b/devel/pkg-config/files/patch-pkg.c
@@ -1,19 +1,16 @@
-
-$FreeBSD$
-
---- pkg.c.orig Mon May 28 16:02:53 2001
-+++ pkg.c Wed Jul 11 14:42:22 2001
-@@ -71,7 +71,7 @@
+--- pkg.c.orig Thu Feb 7 14:32:13 2002
++++ pkg.c Tue Mar 12 16:54:50 2002
+@@ -93,7 +93,7 @@
* locations, ignoring duplicates
*/
static void
-scan_dir (const char *dirname)
+scan_dir (const char *dirname, void *quiet)
{
- DIR *dir = opendir (dirname);
+ DIR *dir;
struct dirent *dent;
-@@ -82,7 +82,8 @@
-
+@@ -113,7 +113,8 @@
+ free (dirname_copy);
if (!dir)
{
- debug_spew ("Cannot open directory '%s' in package search path: %s\n",
@@ -22,8 +19,8 @@ $FreeBSD$
dirname, g_strerror (errno));
return;
}
-@@ -141,7 +142,9 @@
- locations = g_hash_table_new (g_str_hash, g_str_equal);
+@@ -177,7 +178,9 @@
+ path_positions = g_hash_table_new (g_str_hash, g_str_equal);
g_slist_foreach (search_dirs, (GFunc)scan_dir, NULL);
- scan_dir (PKGLIBDIR);
@@ -33,3 +30,45 @@ $FreeBSD$
}
}
+@@ -901,6 +904,13 @@
+ while (tmp != NULL)
+ {
+ Package *pkg = tmp->data;
++ GSList *reqs = pkg->requires;
++
++ if (reqs)
++ {
++ g_string_append (str, packages_get_other_libs(reqs));
++ g_string_append (str, " ");
++ }
+
+ if (pkg->other_libs)
+ {
+@@ -924,10 +934,13 @@
+ char *L_libs;
+ char *other_libs;
+ GString *str;
++ GSList *tmp;
+ char *retval;
+
+ str = g_string_new ("");
+
++ tmp = pkgs;
++
+ other_libs = packages_get_other_libs (pkgs);
+ L_libs = packages_get_L_libs (pkgs);
+ l_libs = packages_get_l_libs (pkgs);
+@@ -986,6 +999,13 @@
+ while (tmp != NULL)
+ {
+ Package *pkg = tmp->data;
++ GSList *reqs = pkg->requires;
++
++ if (reqs)
++ {
++ g_string_append (str, packages_get_other_cflags(reqs));
++ g_string_append (str, " ");
++ }
+
+ if (pkg->other_cflags)
+ {
diff --git a/devel/pkgconfig/Makefile b/devel/pkgconfig/Makefile
index 13b7c5a5a734..b966b6eaefca 100644
--- a/devel/pkgconfig/Makefile
+++ b/devel/pkgconfig/Makefile
@@ -7,6 +7,7 @@
PORTNAME= pkgconfig
PORTVERSION= 0.11.0
+PORTREVISION= 1
CATEGORIES= devel
MASTER_SITES= ${MASTER_SITE_GNOME}
MASTER_SITE_SUBDIR= pre-gnome2/releases/gnome-2.0-desktop-beta2
diff --git a/devel/pkgconfig/files/patch-pkg.c b/devel/pkgconfig/files/patch-pkg.c
index 3bf9b3f766bf..1284af1949e2 100644
--- a/devel/pkgconfig/files/patch-pkg.c
+++ b/devel/pkgconfig/files/patch-pkg.c
@@ -1,19 +1,16 @@
-
-$FreeBSD$
-
---- pkg.c.orig Mon May 28 16:02:53 2001
-+++ pkg.c Wed Jul 11 14:42:22 2001
-@@ -71,7 +71,7 @@
+--- pkg.c.orig Thu Feb 7 14:32:13 2002
++++ pkg.c Tue Mar 12 16:54:50 2002
+@@ -93,7 +93,7 @@
* locations, ignoring duplicates
*/
static void
-scan_dir (const char *dirname)
+scan_dir (const char *dirname, void *quiet)
{
- DIR *dir = opendir (dirname);
+ DIR *dir;
struct dirent *dent;
-@@ -82,7 +82,8 @@
-
+@@ -113,7 +113,8 @@
+ free (dirname_copy);
if (!dir)
{
- debug_spew ("Cannot open directory '%s' in package search path: %s\n",
@@ -22,8 +19,8 @@ $FreeBSD$
dirname, g_strerror (errno));
return;
}
-@@ -141,7 +142,9 @@
- locations = g_hash_table_new (g_str_hash, g_str_equal);
+@@ -177,7 +178,9 @@
+ path_positions = g_hash_table_new (g_str_hash, g_str_equal);
g_slist_foreach (search_dirs, (GFunc)scan_dir, NULL);
- scan_dir (PKGLIBDIR);
@@ -33,3 +30,45 @@ $FreeBSD$
}
}
+@@ -901,6 +904,13 @@
+ while (tmp != NULL)
+ {
+ Package *pkg = tmp->data;
++ GSList *reqs = pkg->requires;
++
++ if (reqs)
++ {
++ g_string_append (str, packages_get_other_libs(reqs));
++ g_string_append (str, " ");
++ }
+
+ if (pkg->other_libs)
+ {
+@@ -924,10 +934,13 @@
+ char *L_libs;
+ char *other_libs;
+ GString *str;
++ GSList *tmp;
+ char *retval;
+
+ str = g_string_new ("");
+
++ tmp = pkgs;
++
+ other_libs = packages_get_other_libs (pkgs);
+ L_libs = packages_get_L_libs (pkgs);
+ l_libs = packages_get_l_libs (pkgs);
+@@ -986,6 +999,13 @@
+ while (tmp != NULL)
+ {
+ Package *pkg = tmp->data;
++ GSList *reqs = pkg->requires;
++
++ if (reqs)
++ {
++ g_string_append (str, packages_get_other_cflags(reqs));
++ g_string_append (str, " ");
++ }
+
+ if (pkg->other_cflags)
+ {