mirror of
https://git.in.rschanz.org/ryan77627/guix.git
synced 2025-01-25 20:19:18 -05:00
gnu: libxt: Update to 1.2.0.
* gnu/packages/xorg.scm (libxt): Update to 1.2.0. * gnu/packages/patches/libxt-guix-search-paths.patch: Adjust for 1.2.0. While at it, trim spurious whitespaces.
This commit is contained in:
parent
1ea1ce18ad
commit
5ab605b952
2 changed files with 23 additions and 23 deletions
|
@ -1,26 +1,27 @@
|
||||||
--- libXt-1.1.5/src/Intrinsic.c 2015-05-01 07:36:20.000000000 +0200
|
diff --git a/src/Intrinsic.c b/src/Intrinsic.c
|
||||||
+++ Intrinsic.c 2016-12-12 00:42:16.567388450 +0100
|
index c9624ec..addcdba 100644
|
||||||
@@ -1303,21 +1303,101 @@
|
--- a/src/Intrinsic.c
|
||||||
|
+++ b/src/Intrinsic.c
|
||||||
|
@@ -1312,21 +1312,101 @@ static void FillInLangSubs(
|
||||||
} else (void) strcpy(*rest, string);
|
} else (void) strcpy(*rest, string);
|
||||||
}
|
}
|
||||||
|
|
||||||
-/*
|
+
|
||||||
|
+
|
||||||
|
/*
|
||||||
- * default path used if environment variable XFILESEARCHPATH
|
- * default path used if environment variable XFILESEARCHPATH
|
||||||
- * is not defined. Also substitued for %D.
|
- * is not defined. Also substitued for %D.
|
||||||
- * The exact value should be documented in the implementation
|
- * The exact value should be documented in the implementation
|
||||||
- * notes for any Xt implementation.
|
- * notes for any Xt implementation.
|
||||||
+
|
|
||||||
+
|
|
||||||
+/*
|
|
||||||
+ Return the default search path for the function
|
+ Return the default search path for the function
|
||||||
+ XtResolvePathname to use if XFILESEARCHPATH is
|
+ XtResolvePathname to use if XFILESEARCHPATH is
|
||||||
+ not defined.
|
+ not defined.
|
||||||
+
|
+
|
||||||
+ It returns the combination the set of values which are the 6 "stems" below,
|
+ It returns the combination the set of values which are the 6 "stems" below,
|
||||||
+ prepended with "/run/current-system/profile", and $GUIX_PROFILE and
|
+ prepended with "/run/current-system/profile", and $GUIX_PROFILE and
|
||||||
+ "$HOME/.guix-profile"
|
+ "$HOME/.guix-profile"
|
||||||
+
|
+
|
||||||
+ These values provide the default paths where Guix/GuixSD can expect
|
+ These values provide the default paths where Guix/GuixSD can expect
|
||||||
+ to find resources for installed packages.
|
+ to find resources for installed packages.
|
||||||
*/
|
*/
|
||||||
-static const char *implementation_default_path(void)
|
-static const char *implementation_default_path(void)
|
||||||
|
@ -28,11 +29,6 @@
|
||||||
{
|
{
|
||||||
-#if defined(WIN32)
|
-#if defined(WIN32)
|
||||||
- static char xfilesearchpath[] = "";
|
- static char xfilesearchpath[] = "";
|
||||||
-
|
|
||||||
- return xfilesearchpath;
|
|
||||||
-#else
|
|
||||||
- return XFILESEARCHPATHDEFAULT;
|
|
||||||
-#endif
|
|
||||||
+ static const char *search_path_default_stem[] = {
|
+ static const char *search_path_default_stem[] = {
|
||||||
+ "/lib/X11/%L/%T/%N%C%S",
|
+ "/lib/X11/%L/%T/%N%C%S",
|
||||||
+ "/lib/X11/%l/%T/%N%C%S",
|
+ "/lib/X11/%l/%T/%N%C%S",
|
||||||
|
@ -55,7 +51,7 @@
|
||||||
+ char *home = getenv ("HOME");
|
+ char *home = getenv ("HOME");
|
||||||
+ char *guix_profile = getenv ("GUIX_PROFILE");
|
+ char *guix_profile = getenv ("GUIX_PROFILE");
|
||||||
+
|
+
|
||||||
+ size_t bytesAllocd = SIZEOF_STEMS + 1;
|
+ size_t bytesAllocd = SIZEOF_STEMS + 1;
|
||||||
+
|
+
|
||||||
+ /* This function is evaluated multiple times and the calling
|
+ /* This function is evaluated multiple times and the calling
|
||||||
+ code assumes that it is idempotent. So we must not allow
|
+ code assumes that it is idempotent. So we must not allow
|
||||||
|
@ -72,7 +68,11 @@
|
||||||
+ bytesAllocd += SIZEOF_STEMS;
|
+ bytesAllocd += SIZEOF_STEMS;
|
||||||
+ bytesAllocd += 6 * (1 + strlen (guix_profile));
|
+ bytesAllocd += 6 * (1 + strlen (guix_profile));
|
||||||
+ }
|
+ }
|
||||||
+
|
|
||||||
|
- return xfilesearchpath;
|
||||||
|
-#else
|
||||||
|
- return XFILESEARCHPATHDEFAULT;
|
||||||
|
-#endif
|
||||||
+ if (home != NULL)
|
+ if (home != NULL)
|
||||||
+ {
|
+ {
|
||||||
+ bytesAllocd += SIZEOF_STEMS;
|
+ bytesAllocd += SIZEOF_STEMS;
|
||||||
|
@ -83,7 +83,7 @@
|
||||||
+ if (path == NULL) _XtAllocError(NULL);
|
+ if (path == NULL) _XtAllocError(NULL);
|
||||||
+
|
+
|
||||||
+ memset (path, 0, bytesAllocd);
|
+ memset (path, 0, bytesAllocd);
|
||||||
+
|
+
|
||||||
+ for (i = 0 ; i < 6 ; ++i)
|
+ for (i = 0 ; i < 6 ; ++i)
|
||||||
+ {
|
+ {
|
||||||
+ strcat (path, current_profile);
|
+ strcat (path, current_profile);
|
||||||
|
@ -110,17 +110,17 @@
|
||||||
+
|
+
|
||||||
+ /* Remove final : */
|
+ /* Remove final : */
|
||||||
+ path[strlen(path) - 1] = '\0';
|
+ path[strlen(path) - 1] = '\0';
|
||||||
+
|
+
|
||||||
+ return path;
|
+ return path;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
@@ -1345,7 +1425,7 @@
|
@@ -1354,7 +1434,7 @@ _XtString XtResolvePathname(
|
||||||
{
|
{
|
||||||
XtPerDisplay pd;
|
XtPerDisplay pd;
|
||||||
static const char *defaultPath = NULL;
|
static const char *defaultPath = NULL;
|
||||||
- const char *impl_default = implementation_default_path();
|
- const char *impl_default = implementation_default_path();
|
||||||
+ const char *impl_default = guix_default_path();
|
+ const char *impl_default = guix_default_path();
|
||||||
int idef_len = strlen(impl_default);
|
int idef_len = (int) strlen(impl_default);
|
||||||
char *massagedPath;
|
char *massagedPath;
|
||||||
int bytesAllocd, bytesLeft;
|
int bytesAllocd, bytesLeft;
|
||||||
|
|
|
@ -5304,7 +5304,7 @@ (define-public libxcursor
|
||||||
(define-public libxt
|
(define-public libxt
|
||||||
(package
|
(package
|
||||||
(name "libxt")
|
(name "libxt")
|
||||||
(version "1.1.5")
|
(version "1.2.0")
|
||||||
(source
|
(source
|
||||||
(origin
|
(origin
|
||||||
(method url-fetch)
|
(method url-fetch)
|
||||||
|
@ -5314,7 +5314,7 @@ (define-public libxt
|
||||||
".tar.bz2"))
|
".tar.bz2"))
|
||||||
(sha256
|
(sha256
|
||||||
(base32
|
(base32
|
||||||
"06lz6i7rbrp19kgikpaz4c97fw7n31k2h2aiikczs482g2zbdvj6"))
|
"0cbqlyssr8aia88c8i7z59z9d0kp3p2hp6683xhz9ndyv8qza7dk"))
|
||||||
(patches (search-patches "libxt-guix-search-paths.patch"))))
|
(patches (search-patches "libxt-guix-search-paths.patch"))))
|
||||||
(build-system gnu-build-system)
|
(build-system gnu-build-system)
|
||||||
(outputs '("out"
|
(outputs '("out"
|
||||||
|
|
Loading…
Reference in a new issue