rpms/pkgconfig/F-9 pkg-config-lib64-excludes.patch,NONE,1.1
Matthias Clasen
mclasen at fedoraproject.org
Wed Jan 28 21:55:55 UTC 2009
- Previous message (by thread): rpms/libsieve/devel .cvsignore, 1.4, 1.5 libsieve.spec, 1.5, 1.6 sources, 1.4, 1.5
- Next message (by thread): rpms/ltsp/F-10 .cvsignore, 1.24, 1.25 ltsp.spec, 1.30, 1.31 sources, 1.28, 1.29
- Messages sorted by:
[ date ]
[ thread ]
[ subject ]
[ author ]
Author: mclasen
Update of /cvs/pkgs/rpms/pkgconfig/F-9
In directory cvs1.fedora.phx.redhat.com:/tmp/cvs-serv26772
Added Files:
pkg-config-lib64-excludes.patch
Log Message:
add missing patch
pkg-config-lib64-excludes.patch:
--- NEW FILE pkg-config-lib64-excludes.patch ---
=== modified file 'pkg.c'
--- pkg.c 2008-03-23 20:39:07 +0000
+++ pkg.c 2008-06-06 18:49:58 +0000
@@ -936,31 +936,44 @@
g_slist_foreach (system_directories, (GFunc) g_free, NULL);
g_slist_free (system_directories);
+
+ system_directories = g_slist_prepend (NULL, "/usr/lib");
#ifdef PREFER_LIB64
-#define SYSTEM_LIBDIR "/usr/lib64"
-#else
-#define SYSTEM_LIBDIR "/usr/lib"
+ system_directories = g_slist_prepend (system_directories, "/usr/lib64");
#endif
count = 0;
iter = pkg->L_libs;
while (iter != NULL)
{
- if (strcmp (iter->data, "-L" SYSTEM_LIBDIR) == 0 ||
- strcmp (iter->data, "-L " SYSTEM_LIBDIR) == 0)
+ GSList *subiter = system_directories;
+ while (subiter != NULL)
{
- debug_spew ("Package %s has -L" SYSTEM_LIBDIR " in Libs\n",
- pkg->name);
- if (g_getenv ("PKG_CONFIG_ALLOW_SYSTEM_LIBS") == NULL)
- {
- iter->data = NULL;
- ++count;
- debug_spew ("Removing -L" SYSTEM_LIBDIR " from libs for %s\n", pkg->key);
+ gboolean is_system = FALSE;
+ const char *linker_arg = iter->data;
+ const char *system_libpath = subiter->data;
+ if (strncmp (linker_arg, "-L ", 3) == 0 &&
+ strcmp (linker_arg + 3, system_libpath) == 0)
+ is_system = TRUE;
+ else if (strncmp (linker_arg, "-L", 2) == 0 &&
+ strcmp (linker_arg + 2, system_libpath) == 0)
+ is_system = TRUE;
+ if (is_system)
+ {
+ debug_spew ("Package %s has -L %s in Libs\n",
+ pkg->name, system_libpath);
+ if (g_getenv ("PKG_CONFIG_ALLOW_SYSTEM_LIBS") == NULL)
+ {
+ iter->data = NULL;
+ ++count;
+ debug_spew ("Removing -L %s from libs for %s\n", system_libpath, pkg->key);
+ break;
+ }
}
+ subiter = subiter->next;
}
-
iter = iter->next;
}
-#undef SYSTEM_LIBDIR
+ g_slist_free (system_directories);
while (count)
{
- Previous message (by thread): rpms/libsieve/devel .cvsignore, 1.4, 1.5 libsieve.spec, 1.5, 1.6 sources, 1.4, 1.5
- Next message (by thread): rpms/ltsp/F-10 .cvsignore, 1.24, 1.25 ltsp.spec, 1.30, 1.31 sources, 1.28, 1.29
- Messages sorted by:
[ date ]
[ thread ]
[ subject ]
[ author ]
More information about the fedora-extras-commits
mailing list