Github messages for voidlinux
 help / color / mirror / Atom feed
* [PR PATCH] mvwm-git: fix cross-build
@ 2020-12-26  1:55 ndowens
  2020-12-26  1:57 ` [PR PATCH] [Updated] " ndowens
                   ` (9 more replies)
  0 siblings, 10 replies; 11+ messages in thread
From: ndowens @ 2020-12-26  1:55 UTC (permalink / raw)
  To: ml

[-- Attachment #1: Type: text/plain, Size: 311 bytes --]

There is a new pull request by ndowens against master on the void-packages repository

https://github.com/ndowens/void-packages mvwm-git
https://github.com/void-linux/void-packages/pull/27436

mvwm-git: fix cross-build


A patch file from https://github.com/void-linux/void-packages/pull/27436.patch is attached

[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #2: github-pr-mvwm-git-27436.patch --]
[-- Type: text/x-diff, Size: 7190 bytes --]

From 9587ac0e5b19455e5014d59155c87a1894b1e962 Mon Sep 17 00:00:00 2001
From: Nathan Owens <ndowens@artixlinux.org>
Date: Fri, 25 Dec 2020 19:56:24 -0600
Subject: [PATCH] mvwm-git: fix cross-build

---
 .../patches/0001-Fix-cross-build.patch        | 177 ++++++++++++++++++
 srcpkgs/mvwm-git/template                     |   5 +-
 2 files changed, 178 insertions(+), 4 deletions(-)
 create mode 100644 srcpkgs/mvwm-git/patches/0001-Fix-cross-build.patch

diff --git a/srcpkgs/mvwm-git/patches/0001-Fix-cross-build.patch b/srcpkgs/mvwm-git/patches/0001-Fix-cross-build.patch
new file mode 100644
index 00000000000..453283be306
--- /dev/null
+++ b/srcpkgs/mvwm-git/patches/0001-Fix-cross-build.patch
@@ -0,0 +1,177 @@
+From 53b028752d6fdd96471be8cd4c3d1c8d490df2a5 Mon Sep 17 00:00:00 2001
+From: Nathan Owens <ndowens@artixlinux.org>
+Date: Fri, 25 Dec 2020 19:45:56 -0600
+Subject: [PATCH] Fix cross-build
+
+---
+ configure.ac | 77 ++++++++--------------------------------------------
+ 1 file changed, 12 insertions(+), 65 deletions(-)
+
+diff --git configure.ac configure.ac
+index 20e91fc..e7a544a 100644
+--- configure.ac
++++ configure.ac
+@@ -191,16 +191,6 @@ fi
+ AC_ISC_POSIX
+ AC_MINIX
+ 
+-# catch -Werror and similar options when running configure
+-AC_TRY_COMPILE([#include <stdio.h>],
+-[int i; static j; int *p; char *c;
+-  switch (*p = p = *c) { case 0: printf("%Q", c, p); }
+-  *c = &i; c = p;
+-  while (1 || (unsigned int)3 >= 0 || ((int)-1) == ((unsigned int)1));
+-  ], , AC_MSG_ERROR("
+-configure is not able to compile programs with warnings.  Please
+-remove all offending options like -Werror from the CFLAGS and
+-CPPFLAGS variables and run configure again."))
+ 
+ # check size of some types
+ ac_save_CFLAGS="$CFLAGS"
+@@ -540,22 +530,8 @@ if test ! x"$png_LIBS" = x; then
+   my_LIBS="$LIBS"
+   CPPFLAGS="$CPPFLAGS $png_CFLAGS"
+   LIBS="$LIBS $png_LIBS -lz -lm"
+-  AC_TRY_RUN([#include <png.h>
+-   int main(int c, char **v) {
+-   return c == 1 ? 0 : (PNG_LIBPNG_VER < 10005) ? 2 : 0 ;}],
+-    [./conftest dummy_arg; png_status=$?;
+-     if test x"$png_status" = x0; then
+-       with_png=yes;
+-     else
+-       with_png=no;
+-       if test x"$png_status" = x2; then
+-	 problem_png=": png library version is too old"
+-       else
+-	 problem_png=": Internal png detection logic error"
+-       fi
+-     fi],
+-   [with_png="no"; problem_png=": png test error, see config.log"],
+-   [echo $ac_n "cross compiling; assumed OK... $ac_c"])
++  AC_CHECK_HEADERS([png.h],
++       with_png=yes)
+   AC_MSG_RESULT($with_png)
+   CPPFLAGS="$my_CPPFLAGS"
+   LIBS="$my_LIBS"
+@@ -712,12 +688,9 @@ AH_VERBATIM([_HAVE_LIBCHARSET],
+ # ******** nl_langinfo and CODESET
+ AH_TEMPLATE([HAVE_CODESET],[Have nl_langinfo (CODESET)])
+ AC_MSG_CHECKING([for nl_langinfo (CODESET)])
+-AC_TRY_COMPILE([#include <langinfo.h>
+-#include <locale.h>],
+-[char *codeset = nl_langinfo(CODESET); setlocale(LC_CTYPE, "");],
+-   AC_DEFINE(HAVE_CODESET)
+-   have_codeset=yes,
+-   have_codeset=no)
++AC_CHECK_HEADERS([langinfo.h locale.h],
++   [AC_DEFINE(HAVE_CODESET),
++   have_codeset=yes])
+ AC_MSG_RESULT($have_codeset)
+ 
+ 
+@@ -762,39 +735,16 @@ if test ! x"$with_bidi" = xno; then
+   fribidi_in_path=yes
+   ac_save_LIBS="$LIBS"
+   LIBS="$LIBS $Bidi_LIBS"
+-  AC_TRY_RUN([#include <stdlib.h>
+-#include <fribidi/fribidi.h>
+-int main()
+-{
+-	FriBidiChar *logical_unicode_str =
+-		(FriBidiChar *)malloc((4 + 1) * sizeof(FriBidiChar));
+-	fribidi_charset_to_unicode(
+-		fribidi_parse_charset("iso8859-8"), "test", 4,
+-		logical_unicode_str);
+-	return 0;
+-}
+-], [:], [fribidi_in_path=no])
+-  LIBS="$ac_save_LIBS"
++  AC_CHECK_HEADERS([fribidi/fribidi.h],
++			fribidi_in_path=yes)
+   if test ! x"$fribidi_in_path" = xyes; then
+     ac_save_CFLAGS="$CFLAGS"
+     ac_save_LIBS="$LIBS"
+     CFLAGS="$CFLAGS $Bidi_CFLAGS"
+     LIBS="$LIBS $Bidi_LIBS"
+-  AC_TRY_RUN([#include <stdlib.h>
+-#include <fribidi/fribidi.h>
+-int main()
+-{
+-	FriBidiChar *logical_unicode_str =
+-		(FriBidiChar *)malloc((4 + 1) * sizeof(FriBidiChar));
+-	fribidi_charset_to_unicode(
+-		fribidi_parse_charset("iso8859-8"), "test", 4,
+-		logical_unicode_str);
+-	return 0;
+-}
+-], [:], [with_bidi=no; problem_bidi=": Bad fribidi version, see config.log"])
+-    CFLAGS="$ac_save_CFLAGS"
+-    LIBS="$ac_save_LIBS"
+-  fi
++  AC_CHECK_HEADERS([fribidi/fribidi.h],
++		fribidi_in_path=yes)
++	fi
+   if test ! x"$fribidi_in_path" = xno; then
+     Bidi_CFLAGS=
+     Bidi_LIBS=-lfribidi
+@@ -809,11 +759,8 @@ if test x"$with_bidi" = xno; then
+   Bidi_LIBS=
+ else
+   AC_DEFINE(HAVE_BIDI)
+-  AC_TRY_RUN([#include <fribidi/fribidi.h>
+-    int main(int c, char **v) {
+-      return FRIBIDI_CHARSET_NOT_FOUND * 0;
+-    }
+-  ], [AC_DEFINE(FRIBIDI_CHARSET_SPELLING)])
++  AC_CHECK_HEADERS([fribidi/fribidi.h],
++		[AC_DEFINE(FRIBIDI_CHARSET_SPELLING)])
+ fi
+ AH_VERBATIM([_FRIBIDI_CHARSET_SPELLING],
+ [#ifdef FRIBIDI_CHARSET_SPELLING
+-- 
+2.29.2
+
+diff --git configure.ac configure.ac
+index e7a544a..4004761 100644
+--- configure.ac
++++ configure.ac
+@@ -930,9 +930,6 @@ AC_REPLACE_FUNCS(gethostname strcasecmp strncasecmp strdup strerror usleep atexi
+ dnl dv: this is harmful with autoconf 2.53 and is done automatically anyway
+ dnl AC_SUBST(LIBOBJS)
+ 
+-# check for mkstemp, see the discution on this subject on the mvwm workers
+-# list (2001-02-16 and 2001-02-24)
+-AM_SAFETY_CHECK_MKSTEMP
+ 
+ # If we do not have atexit(), then check for on_exit()
+ if test x$ac_cv_func_atexit = xno; then
+-- 
+2.29.2
+
+From 3bf088b4364b007eb13a31d449cf41f7e3769ceb Mon Sep 17 00:00:00 2001
+From: Nathan Owens <ndowens@artixlinux.org>
+Date: Fri, 25 Dec 2020 19:54:24 -0600
+Subject: [PATCH] 1
+
+---
+ configure.ac | 4 ----
+ 1 file changed, 4 deletions(-)
+
+diff --git configure.ac configure.ac
+index 4004761..b3d51e4 100644
+--- configure.ac
++++ configure.ac
+@@ -940,10 +940,6 @@ fi
+ AC_CHECK_FUNCS(unsetenv)
+ 
+ # Define some compatibility macros needed for config.h.
+-mg_DEFINE_IF_NOT([#include <X11/keysym.h>],
+-  [defined XK_Page_Up && defined XK_Page_Down],
+-  [COMPAT_OLD_KEYSYMDEF], [$X_CFLAGS],
+-  [Old AIX systems (3.2.5) don't define some common keysyms.])
+ AH_VERBATIM([_COMPAT_OLD_KEYSYMDEF],
+ [#ifdef COMPAT_OLD_KEYSYMDEF
+ #  define XK_Page_Up   XK_Prior
+-- 
+2.29.2
+
diff --git a/srcpkgs/mvwm-git/template b/srcpkgs/mvwm-git/template
index 5bc72355c72..d99721e40ca 100644
--- a/srcpkgs/mvwm-git/template
+++ b/srcpkgs/mvwm-git/template
@@ -12,7 +12,7 @@ makedepends="fribidi-devel libXpm-devel librsvg-devel libXrandr-devel
 depends="perl"
 short_desc="An extremely powerful ICCCM-compliant window manager (FVWM rewrite)"
 maintainer="Thomas Adam <thomas@fvwm.org>"
-license="GPL-2,custom"
+license="GPL-2.0-or-later,custom"
 homepage="http://github.com/ThomasAdam/mvwm"
 provides="mvwm-${version}_${revision}"
 replaces="mvwm>=0"
@@ -21,6 +21,3 @@ distfiles="$homepage/archive/$_commit.tar.gz"
 checksum=34f6831d3e42b06d7af0ddf88ae43f353cd84f23563f090e7e4f0a13b75d7560
 
 CFLAGS="-fcommon"
-
-# cannot run test program while cross compiling
-nocross="https://build.voidlinux.org/builders/aarch64_builder/builds/2229/steps/shell_3/logs/stdio"

^ permalink raw reply	[flat|nested] 11+ messages in thread

* Re: [PR PATCH] [Updated] mvwm-git: fix cross-build
  2020-12-26  1:55 [PR PATCH] mvwm-git: fix cross-build ndowens
@ 2020-12-26  1:57 ` ndowens
  2020-12-26  2:01 ` ndowens
                   ` (8 subsequent siblings)
  9 siblings, 0 replies; 11+ messages in thread
From: ndowens @ 2020-12-26  1:57 UTC (permalink / raw)
  To: ml

[-- Attachment #1: Type: text/plain, Size: 316 bytes --]

There is an updated pull request by ndowens against master on the void-packages repository

https://github.com/ndowens/void-packages mvwm-git
https://github.com/void-linux/void-packages/pull/27436

mvwm-git: fix cross-build


A patch file from https://github.com/void-linux/void-packages/pull/27436.patch is attached

[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #2: github-pr-mvwm-git-27436.patch --]
[-- Type: text/x-diff, Size: 7613 bytes --]

From ae58b79e1da60ac0ab3337ac29a47f7a164226b5 Mon Sep 17 00:00:00 2001
From: Nathan Owens <ndowens@artixlinux.org>
Date: Fri, 25 Dec 2020 19:56:24 -0600
Subject: [PATCH] mvwm-git: fix cross-build

---
 .../patches/0001-Fix-cross-build.patch        | 177 ++++++++++++++++++
 srcpkgs/mvwm-git/template                     |  13 +-
 2 files changed, 182 insertions(+), 8 deletions(-)
 create mode 100644 srcpkgs/mvwm-git/patches/0001-Fix-cross-build.patch

diff --git a/srcpkgs/mvwm-git/patches/0001-Fix-cross-build.patch b/srcpkgs/mvwm-git/patches/0001-Fix-cross-build.patch
new file mode 100644
index 00000000000..453283be306
--- /dev/null
+++ b/srcpkgs/mvwm-git/patches/0001-Fix-cross-build.patch
@@ -0,0 +1,177 @@
+From 53b028752d6fdd96471be8cd4c3d1c8d490df2a5 Mon Sep 17 00:00:00 2001
+From: Nathan Owens <ndowens@artixlinux.org>
+Date: Fri, 25 Dec 2020 19:45:56 -0600
+Subject: [PATCH] Fix cross-build
+
+---
+ configure.ac | 77 ++++++++--------------------------------------------
+ 1 file changed, 12 insertions(+), 65 deletions(-)
+
+diff --git configure.ac configure.ac
+index 20e91fc..e7a544a 100644
+--- configure.ac
++++ configure.ac
+@@ -191,16 +191,6 @@ fi
+ AC_ISC_POSIX
+ AC_MINIX
+ 
+-# catch -Werror and similar options when running configure
+-AC_TRY_COMPILE([#include <stdio.h>],
+-[int i; static j; int *p; char *c;
+-  switch (*p = p = *c) { case 0: printf("%Q", c, p); }
+-  *c = &i; c = p;
+-  while (1 || (unsigned int)3 >= 0 || ((int)-1) == ((unsigned int)1));
+-  ], , AC_MSG_ERROR("
+-configure is not able to compile programs with warnings.  Please
+-remove all offending options like -Werror from the CFLAGS and
+-CPPFLAGS variables and run configure again."))
+ 
+ # check size of some types
+ ac_save_CFLAGS="$CFLAGS"
+@@ -540,22 +530,8 @@ if test ! x"$png_LIBS" = x; then
+   my_LIBS="$LIBS"
+   CPPFLAGS="$CPPFLAGS $png_CFLAGS"
+   LIBS="$LIBS $png_LIBS -lz -lm"
+-  AC_TRY_RUN([#include <png.h>
+-   int main(int c, char **v) {
+-   return c == 1 ? 0 : (PNG_LIBPNG_VER < 10005) ? 2 : 0 ;}],
+-    [./conftest dummy_arg; png_status=$?;
+-     if test x"$png_status" = x0; then
+-       with_png=yes;
+-     else
+-       with_png=no;
+-       if test x"$png_status" = x2; then
+-	 problem_png=": png library version is too old"
+-       else
+-	 problem_png=": Internal png detection logic error"
+-       fi
+-     fi],
+-   [with_png="no"; problem_png=": png test error, see config.log"],
+-   [echo $ac_n "cross compiling; assumed OK... $ac_c"])
++  AC_CHECK_HEADERS([png.h],
++       with_png=yes)
+   AC_MSG_RESULT($with_png)
+   CPPFLAGS="$my_CPPFLAGS"
+   LIBS="$my_LIBS"
+@@ -712,12 +688,9 @@ AH_VERBATIM([_HAVE_LIBCHARSET],
+ # ******** nl_langinfo and CODESET
+ AH_TEMPLATE([HAVE_CODESET],[Have nl_langinfo (CODESET)])
+ AC_MSG_CHECKING([for nl_langinfo (CODESET)])
+-AC_TRY_COMPILE([#include <langinfo.h>
+-#include <locale.h>],
+-[char *codeset = nl_langinfo(CODESET); setlocale(LC_CTYPE, "");],
+-   AC_DEFINE(HAVE_CODESET)
+-   have_codeset=yes,
+-   have_codeset=no)
++AC_CHECK_HEADERS([langinfo.h locale.h],
++   [AC_DEFINE(HAVE_CODESET),
++   have_codeset=yes])
+ AC_MSG_RESULT($have_codeset)
+ 
+ 
+@@ -762,39 +735,16 @@ if test ! x"$with_bidi" = xno; then
+   fribidi_in_path=yes
+   ac_save_LIBS="$LIBS"
+   LIBS="$LIBS $Bidi_LIBS"
+-  AC_TRY_RUN([#include <stdlib.h>
+-#include <fribidi/fribidi.h>
+-int main()
+-{
+-	FriBidiChar *logical_unicode_str =
+-		(FriBidiChar *)malloc((4 + 1) * sizeof(FriBidiChar));
+-	fribidi_charset_to_unicode(
+-		fribidi_parse_charset("iso8859-8"), "test", 4,
+-		logical_unicode_str);
+-	return 0;
+-}
+-], [:], [fribidi_in_path=no])
+-  LIBS="$ac_save_LIBS"
++  AC_CHECK_HEADERS([fribidi/fribidi.h],
++			fribidi_in_path=yes)
+   if test ! x"$fribidi_in_path" = xyes; then
+     ac_save_CFLAGS="$CFLAGS"
+     ac_save_LIBS="$LIBS"
+     CFLAGS="$CFLAGS $Bidi_CFLAGS"
+     LIBS="$LIBS $Bidi_LIBS"
+-  AC_TRY_RUN([#include <stdlib.h>
+-#include <fribidi/fribidi.h>
+-int main()
+-{
+-	FriBidiChar *logical_unicode_str =
+-		(FriBidiChar *)malloc((4 + 1) * sizeof(FriBidiChar));
+-	fribidi_charset_to_unicode(
+-		fribidi_parse_charset("iso8859-8"), "test", 4,
+-		logical_unicode_str);
+-	return 0;
+-}
+-], [:], [with_bidi=no; problem_bidi=": Bad fribidi version, see config.log"])
+-    CFLAGS="$ac_save_CFLAGS"
+-    LIBS="$ac_save_LIBS"
+-  fi
++  AC_CHECK_HEADERS([fribidi/fribidi.h],
++		fribidi_in_path=yes)
++	fi
+   if test ! x"$fribidi_in_path" = xno; then
+     Bidi_CFLAGS=
+     Bidi_LIBS=-lfribidi
+@@ -809,11 +759,8 @@ if test x"$with_bidi" = xno; then
+   Bidi_LIBS=
+ else
+   AC_DEFINE(HAVE_BIDI)
+-  AC_TRY_RUN([#include <fribidi/fribidi.h>
+-    int main(int c, char **v) {
+-      return FRIBIDI_CHARSET_NOT_FOUND * 0;
+-    }
+-  ], [AC_DEFINE(FRIBIDI_CHARSET_SPELLING)])
++  AC_CHECK_HEADERS([fribidi/fribidi.h],
++		[AC_DEFINE(FRIBIDI_CHARSET_SPELLING)])
+ fi
+ AH_VERBATIM([_FRIBIDI_CHARSET_SPELLING],
+ [#ifdef FRIBIDI_CHARSET_SPELLING
+-- 
+2.29.2
+
+diff --git configure.ac configure.ac
+index e7a544a..4004761 100644
+--- configure.ac
++++ configure.ac
+@@ -930,9 +930,6 @@ AC_REPLACE_FUNCS(gethostname strcasecmp strncasecmp strdup strerror usleep atexi
+ dnl dv: this is harmful with autoconf 2.53 and is done automatically anyway
+ dnl AC_SUBST(LIBOBJS)
+ 
+-# check for mkstemp, see the discution on this subject on the mvwm workers
+-# list (2001-02-16 and 2001-02-24)
+-AM_SAFETY_CHECK_MKSTEMP
+ 
+ # If we do not have atexit(), then check for on_exit()
+ if test x$ac_cv_func_atexit = xno; then
+-- 
+2.29.2
+
+From 3bf088b4364b007eb13a31d449cf41f7e3769ceb Mon Sep 17 00:00:00 2001
+From: Nathan Owens <ndowens@artixlinux.org>
+Date: Fri, 25 Dec 2020 19:54:24 -0600
+Subject: [PATCH] 1
+
+---
+ configure.ac | 4 ----
+ 1 file changed, 4 deletions(-)
+
+diff --git configure.ac configure.ac
+index 4004761..b3d51e4 100644
+--- configure.ac
++++ configure.ac
+@@ -940,10 +940,6 @@ fi
+ AC_CHECK_FUNCS(unsetenv)
+ 
+ # Define some compatibility macros needed for config.h.
+-mg_DEFINE_IF_NOT([#include <X11/keysym.h>],
+-  [defined XK_Page_Up && defined XK_Page_Down],
+-  [COMPAT_OLD_KEYSYMDEF], [$X_CFLAGS],
+-  [Old AIX systems (3.2.5) don't define some common keysyms.])
+ AH_VERBATIM([_COMPAT_OLD_KEYSYMDEF],
+ [#ifdef COMPAT_OLD_KEYSYMDEF
+ #  define XK_Page_Up   XK_Prior
+-- 
+2.29.2
+
diff --git a/srcpkgs/mvwm-git/template b/srcpkgs/mvwm-git/template
index 5bc72355c72..28de8224010 100644
--- a/srcpkgs/mvwm-git/template
+++ b/srcpkgs/mvwm-git/template
@@ -2,6 +2,7 @@
 pkgname=mvwm-git
 version=20150409
 revision=3
+wrksrc="mvwm-$_commit"
 _commit=f23f011fcd711422645043a215d5638a4965b187
 build_style=gnu-configure
 configure_script="./autogen.sh"
@@ -10,17 +11,13 @@ makedepends="fribidi-devel libXpm-devel librsvg-devel libXrandr-devel
  libXcursor-devel libXt-devel libXft-devel
  fontconfig-devel readline-devel perl"
 depends="perl"
-short_desc="An extremely powerful ICCCM-compliant window manager (FVWM rewrite)"
+short_desc="Extremely powerful ICCCM-compliant window manager (FVWM rewrite)"
 maintainer="Thomas Adam <thomas@fvwm.org>"
-license="GPL-2,custom"
+license="GPL-2.0-or-later"
 homepage="http://github.com/ThomasAdam/mvwm"
-provides="mvwm-${version}_${revision}"
-replaces="mvwm>=0"
-wrksrc="mvwm-$_commit"
 distfiles="$homepage/archive/$_commit.tar.gz"
 checksum=34f6831d3e42b06d7af0ddf88ae43f353cd84f23563f090e7e4f0a13b75d7560
+provides="mvwm-${version}_${revision}"
+replaces="mvwm>=0"
 
 CFLAGS="-fcommon"
-
-# cannot run test program while cross compiling
-nocross="https://build.voidlinux.org/builders/aarch64_builder/builds/2229/steps/shell_3/logs/stdio"

^ permalink raw reply	[flat|nested] 11+ messages in thread

* Re: [PR PATCH] [Updated] mvwm-git: fix cross-build
  2020-12-26  1:55 [PR PATCH] mvwm-git: fix cross-build ndowens
  2020-12-26  1:57 ` [PR PATCH] [Updated] " ndowens
@ 2020-12-26  2:01 ` ndowens
  2020-12-26  2:43 ` [PR REVIEW] " ericonr
                   ` (7 subsequent siblings)
  9 siblings, 0 replies; 11+ messages in thread
From: ndowens @ 2020-12-26  2:01 UTC (permalink / raw)
  To: ml

[-- Attachment #1: Type: text/plain, Size: 316 bytes --]

There is an updated pull request by ndowens against master on the void-packages repository

https://github.com/ndowens/void-packages mvwm-git
https://github.com/void-linux/void-packages/pull/27436

mvwm-git: fix cross-build


A patch file from https://github.com/void-linux/void-packages/pull/27436.patch is attached

[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #2: github-pr-mvwm-git-27436.patch --]
[-- Type: text/x-diff, Size: 7664 bytes --]

From 4a6bb6ba1731546c880e5615afe2fb35f3344c76 Mon Sep 17 00:00:00 2001
From: Nathan Owens <ndowens@artixlinux.org>
Date: Fri, 25 Dec 2020 19:56:24 -0600
Subject: [PATCH] mvwm-git: fix cross-build

---
 .../patches/0001-Fix-cross-build.patch        | 177 ++++++++++++++++++
 srcpkgs/mvwm-git/template                     |  13 +-
 2 files changed, 182 insertions(+), 8 deletions(-)
 create mode 100644 srcpkgs/mvwm-git/patches/0001-Fix-cross-build.patch

diff --git a/srcpkgs/mvwm-git/patches/0001-Fix-cross-build.patch b/srcpkgs/mvwm-git/patches/0001-Fix-cross-build.patch
new file mode 100644
index 00000000000..453283be306
--- /dev/null
+++ b/srcpkgs/mvwm-git/patches/0001-Fix-cross-build.patch
@@ -0,0 +1,177 @@
+From 53b028752d6fdd96471be8cd4c3d1c8d490df2a5 Mon Sep 17 00:00:00 2001
+From: Nathan Owens <ndowens@artixlinux.org>
+Date: Fri, 25 Dec 2020 19:45:56 -0600
+Subject: [PATCH] Fix cross-build
+
+---
+ configure.ac | 77 ++++++++--------------------------------------------
+ 1 file changed, 12 insertions(+), 65 deletions(-)
+
+diff --git configure.ac configure.ac
+index 20e91fc..e7a544a 100644
+--- configure.ac
++++ configure.ac
+@@ -191,16 +191,6 @@ fi
+ AC_ISC_POSIX
+ AC_MINIX
+ 
+-# catch -Werror and similar options when running configure
+-AC_TRY_COMPILE([#include <stdio.h>],
+-[int i; static j; int *p; char *c;
+-  switch (*p = p = *c) { case 0: printf("%Q", c, p); }
+-  *c = &i; c = p;
+-  while (1 || (unsigned int)3 >= 0 || ((int)-1) == ((unsigned int)1));
+-  ], , AC_MSG_ERROR("
+-configure is not able to compile programs with warnings.  Please
+-remove all offending options like -Werror from the CFLAGS and
+-CPPFLAGS variables and run configure again."))
+ 
+ # check size of some types
+ ac_save_CFLAGS="$CFLAGS"
+@@ -540,22 +530,8 @@ if test ! x"$png_LIBS" = x; then
+   my_LIBS="$LIBS"
+   CPPFLAGS="$CPPFLAGS $png_CFLAGS"
+   LIBS="$LIBS $png_LIBS -lz -lm"
+-  AC_TRY_RUN([#include <png.h>
+-   int main(int c, char **v) {
+-   return c == 1 ? 0 : (PNG_LIBPNG_VER < 10005) ? 2 : 0 ;}],
+-    [./conftest dummy_arg; png_status=$?;
+-     if test x"$png_status" = x0; then
+-       with_png=yes;
+-     else
+-       with_png=no;
+-       if test x"$png_status" = x2; then
+-	 problem_png=": png library version is too old"
+-       else
+-	 problem_png=": Internal png detection logic error"
+-       fi
+-     fi],
+-   [with_png="no"; problem_png=": png test error, see config.log"],
+-   [echo $ac_n "cross compiling; assumed OK... $ac_c"])
++  AC_CHECK_HEADERS([png.h],
++       with_png=yes)
+   AC_MSG_RESULT($with_png)
+   CPPFLAGS="$my_CPPFLAGS"
+   LIBS="$my_LIBS"
+@@ -712,12 +688,9 @@ AH_VERBATIM([_HAVE_LIBCHARSET],
+ # ******** nl_langinfo and CODESET
+ AH_TEMPLATE([HAVE_CODESET],[Have nl_langinfo (CODESET)])
+ AC_MSG_CHECKING([for nl_langinfo (CODESET)])
+-AC_TRY_COMPILE([#include <langinfo.h>
+-#include <locale.h>],
+-[char *codeset = nl_langinfo(CODESET); setlocale(LC_CTYPE, "");],
+-   AC_DEFINE(HAVE_CODESET)
+-   have_codeset=yes,
+-   have_codeset=no)
++AC_CHECK_HEADERS([langinfo.h locale.h],
++   [AC_DEFINE(HAVE_CODESET),
++   have_codeset=yes])
+ AC_MSG_RESULT($have_codeset)
+ 
+ 
+@@ -762,39 +735,16 @@ if test ! x"$with_bidi" = xno; then
+   fribidi_in_path=yes
+   ac_save_LIBS="$LIBS"
+   LIBS="$LIBS $Bidi_LIBS"
+-  AC_TRY_RUN([#include <stdlib.h>
+-#include <fribidi/fribidi.h>
+-int main()
+-{
+-	FriBidiChar *logical_unicode_str =
+-		(FriBidiChar *)malloc((4 + 1) * sizeof(FriBidiChar));
+-	fribidi_charset_to_unicode(
+-		fribidi_parse_charset("iso8859-8"), "test", 4,
+-		logical_unicode_str);
+-	return 0;
+-}
+-], [:], [fribidi_in_path=no])
+-  LIBS="$ac_save_LIBS"
++  AC_CHECK_HEADERS([fribidi/fribidi.h],
++			fribidi_in_path=yes)
+   if test ! x"$fribidi_in_path" = xyes; then
+     ac_save_CFLAGS="$CFLAGS"
+     ac_save_LIBS="$LIBS"
+     CFLAGS="$CFLAGS $Bidi_CFLAGS"
+     LIBS="$LIBS $Bidi_LIBS"
+-  AC_TRY_RUN([#include <stdlib.h>
+-#include <fribidi/fribidi.h>
+-int main()
+-{
+-	FriBidiChar *logical_unicode_str =
+-		(FriBidiChar *)malloc((4 + 1) * sizeof(FriBidiChar));
+-	fribidi_charset_to_unicode(
+-		fribidi_parse_charset("iso8859-8"), "test", 4,
+-		logical_unicode_str);
+-	return 0;
+-}
+-], [:], [with_bidi=no; problem_bidi=": Bad fribidi version, see config.log"])
+-    CFLAGS="$ac_save_CFLAGS"
+-    LIBS="$ac_save_LIBS"
+-  fi
++  AC_CHECK_HEADERS([fribidi/fribidi.h],
++		fribidi_in_path=yes)
++	fi
+   if test ! x"$fribidi_in_path" = xno; then
+     Bidi_CFLAGS=
+     Bidi_LIBS=-lfribidi
+@@ -809,11 +759,8 @@ if test x"$with_bidi" = xno; then
+   Bidi_LIBS=
+ else
+   AC_DEFINE(HAVE_BIDI)
+-  AC_TRY_RUN([#include <fribidi/fribidi.h>
+-    int main(int c, char **v) {
+-      return FRIBIDI_CHARSET_NOT_FOUND * 0;
+-    }
+-  ], [AC_DEFINE(FRIBIDI_CHARSET_SPELLING)])
++  AC_CHECK_HEADERS([fribidi/fribidi.h],
++		[AC_DEFINE(FRIBIDI_CHARSET_SPELLING)])
+ fi
+ AH_VERBATIM([_FRIBIDI_CHARSET_SPELLING],
+ [#ifdef FRIBIDI_CHARSET_SPELLING
+-- 
+2.29.2
+
+diff --git configure.ac configure.ac
+index e7a544a..4004761 100644
+--- configure.ac
++++ configure.ac
+@@ -930,9 +930,6 @@ AC_REPLACE_FUNCS(gethostname strcasecmp strncasecmp strdup strerror usleep atexi
+ dnl dv: this is harmful with autoconf 2.53 and is done automatically anyway
+ dnl AC_SUBST(LIBOBJS)
+ 
+-# check for mkstemp, see the discution on this subject on the mvwm workers
+-# list (2001-02-16 and 2001-02-24)
+-AM_SAFETY_CHECK_MKSTEMP
+ 
+ # If we do not have atexit(), then check for on_exit()
+ if test x$ac_cv_func_atexit = xno; then
+-- 
+2.29.2
+
+From 3bf088b4364b007eb13a31d449cf41f7e3769ceb Mon Sep 17 00:00:00 2001
+From: Nathan Owens <ndowens@artixlinux.org>
+Date: Fri, 25 Dec 2020 19:54:24 -0600
+Subject: [PATCH] 1
+
+---
+ configure.ac | 4 ----
+ 1 file changed, 4 deletions(-)
+
+diff --git configure.ac configure.ac
+index 4004761..b3d51e4 100644
+--- configure.ac
++++ configure.ac
+@@ -940,10 +940,6 @@ fi
+ AC_CHECK_FUNCS(unsetenv)
+ 
+ # Define some compatibility macros needed for config.h.
+-mg_DEFINE_IF_NOT([#include <X11/keysym.h>],
+-  [defined XK_Page_Up && defined XK_Page_Down],
+-  [COMPAT_OLD_KEYSYMDEF], [$X_CFLAGS],
+-  [Old AIX systems (3.2.5) don't define some common keysyms.])
+ AH_VERBATIM([_COMPAT_OLD_KEYSYMDEF],
+ [#ifdef COMPAT_OLD_KEYSYMDEF
+ #  define XK_Page_Up   XK_Prior
+-- 
+2.29.2
+
diff --git a/srcpkgs/mvwm-git/template b/srcpkgs/mvwm-git/template
index 5bc72355c72..0aa55def716 100644
--- a/srcpkgs/mvwm-git/template
+++ b/srcpkgs/mvwm-git/template
@@ -3,6 +3,7 @@ pkgname=mvwm-git
 version=20150409
 revision=3
 _commit=f23f011fcd711422645043a215d5638a4965b187
+wrksrc="mvwm-$_commit"
 build_style=gnu-configure
 configure_script="./autogen.sh"
 hostmakedepends="pkg-config git automake autoconf"
@@ -10,17 +11,13 @@ makedepends="fribidi-devel libXpm-devel librsvg-devel libXrandr-devel
  libXcursor-devel libXt-devel libXft-devel
  fontconfig-devel readline-devel perl"
 depends="perl"
-short_desc="An extremely powerful ICCCM-compliant window manager (FVWM rewrite)"
+short_desc="Extremely powerful ICCCM-compliant window manager (FVWM rewrite)"
 maintainer="Thomas Adam <thomas@fvwm.org>"
-license="GPL-2,custom"
+license="GPL-2.0-or-later"
 homepage="http://github.com/ThomasAdam/mvwm"
-provides="mvwm-${version}_${revision}"
-replaces="mvwm>=0"
-wrksrc="mvwm-$_commit"
 distfiles="$homepage/archive/$_commit.tar.gz"
 checksum=34f6831d3e42b06d7af0ddf88ae43f353cd84f23563f090e7e4f0a13b75d7560
+provides="mvwm-${version}_${revision}"
+replaces="mvwm>=0"
 
 CFLAGS="-fcommon"
-
-# cannot run test program while cross compiling
-nocross="https://build.voidlinux.org/builders/aarch64_builder/builds/2229/steps/shell_3/logs/stdio"

^ permalink raw reply	[flat|nested] 11+ messages in thread

* Re: [PR REVIEW] mvwm-git: fix cross-build
  2020-12-26  1:55 [PR PATCH] mvwm-git: fix cross-build ndowens
  2020-12-26  1:57 ` [PR PATCH] [Updated] " ndowens
  2020-12-26  2:01 ` ndowens
@ 2020-12-26  2:43 ` ericonr
  2020-12-26  2:44 ` ndowens
                   ` (6 subsequent siblings)
  9 siblings, 0 replies; 11+ messages in thread
From: ericonr @ 2020-12-26  2:43 UTC (permalink / raw)
  To: ml

[-- Attachment #1: Type: text/plain, Size: 259 bytes --]

New review comment by ericonr on void-packages repository

https://github.com/void-linux/void-packages/pull/27436#discussion_r548934522

Comment:
Have you tried to upstream this? Would be nice to not have to rebase and add new changes when there are updates.

^ permalink raw reply	[flat|nested] 11+ messages in thread

* Re: [PR REVIEW] mvwm-git: fix cross-build
  2020-12-26  1:55 [PR PATCH] mvwm-git: fix cross-build ndowens
                   ` (2 preceding siblings ...)
  2020-12-26  2:43 ` [PR REVIEW] " ericonr
@ 2020-12-26  2:44 ` ndowens
  2020-12-26  2:45 ` ericonr
                   ` (5 subsequent siblings)
  9 siblings, 0 replies; 11+ messages in thread
From: ndowens @ 2020-12-26  2:44 UTC (permalink / raw)
  To: ml

[-- Attachment #1: Type: text/plain, Size: 183 bytes --]

New review comment by ndowens on void-packages repository

https://github.com/void-linux/void-packages/pull/27436#discussion_r548934595

Comment:
Not yet. Add this to my TODO list :)

^ permalink raw reply	[flat|nested] 11+ messages in thread

* Re: [PR REVIEW] mvwm-git: fix cross-build
  2020-12-26  1:55 [PR PATCH] mvwm-git: fix cross-build ndowens
                   ` (3 preceding siblings ...)
  2020-12-26  2:44 ` ndowens
@ 2020-12-26  2:45 ` ericonr
  2020-12-26  2:51 ` ericonr
                   ` (4 subsequent siblings)
  9 siblings, 0 replies; 11+ messages in thread
From: ericonr @ 2020-12-26  2:45 UTC (permalink / raw)
  To: ml

[-- Attachment #1: Type: text/plain, Size: 211 bytes --]

New review comment by ericonr on void-packages repository

https://github.com/void-linux/void-packages/pull/27436#discussion_r548934694

Comment:
Eh, upstream seems inactive since 2015... I'd consider dropping.

^ permalink raw reply	[flat|nested] 11+ messages in thread

* Re: [PR REVIEW] mvwm-git: fix cross-build
  2020-12-26  1:55 [PR PATCH] mvwm-git: fix cross-build ndowens
                   ` (4 preceding siblings ...)
  2020-12-26  2:45 ` ericonr
@ 2020-12-26  2:51 ` ericonr
  2020-12-26  2:51 ` sgn
                   ` (3 subsequent siblings)
  9 siblings, 0 replies; 11+ messages in thread
From: ericonr @ 2020-12-26  2:51 UTC (permalink / raw)
  To: ml

[-- Attachment #1: Type: text/plain, Size: 226 bytes --]

New review comment by ericonr on void-packages repository

https://github.com/void-linux/void-packages/pull/27436#discussion_r548935089

Comment:
Still, the patch likely won't become stale, so it wouldn't be so bad to add it.

^ permalink raw reply	[flat|nested] 11+ messages in thread

* Re: [PR REVIEW] mvwm-git: fix cross-build
  2020-12-26  1:55 [PR PATCH] mvwm-git: fix cross-build ndowens
                   ` (5 preceding siblings ...)
  2020-12-26  2:51 ` ericonr
@ 2020-12-26  2:51 ` sgn
  2020-12-26  2:51 ` sgn
                   ` (2 subsequent siblings)
  9 siblings, 0 replies; 11+ messages in thread
From: sgn @ 2020-12-26  2:51 UTC (permalink / raw)
  To: ml

[-- Attachment #1: Type: text/plain, Size: 244 bytes --]

New review comment by sgn on void-packages repository

https://github.com/void-linux/void-packages/pull/27436#discussion_r548935092

Comment:
I would try to minimize that patch we have. Let's say by just change `AC_TRY_RUN` to `AC_TRY_COMPILE`

^ permalink raw reply	[flat|nested] 11+ messages in thread

* Re: [PR REVIEW] mvwm-git: fix cross-build
  2020-12-26  1:55 [PR PATCH] mvwm-git: fix cross-build ndowens
                   ` (6 preceding siblings ...)
  2020-12-26  2:51 ` sgn
@ 2020-12-26  2:51 ` sgn
  2020-12-26  2:55 ` ndowens
  2020-12-28 13:19 ` [PR PATCH] [Closed]: " sgn
  9 siblings, 0 replies; 11+ messages in thread
From: sgn @ 2020-12-26  2:51 UTC (permalink / raw)
  To: ml

[-- Attachment #1: Type: text/plain, Size: 244 bytes --]

New review comment by sgn on void-packages repository

https://github.com/void-linux/void-packages/pull/27436#discussion_r548935092

Comment:
I would try to minimize that patch we have. Let's say by only change `AC_TRY_RUN` to `AC_TRY_COMPILE`

^ permalink raw reply	[flat|nested] 11+ messages in thread

* Re: [PR REVIEW] mvwm-git: fix cross-build
  2020-12-26  1:55 [PR PATCH] mvwm-git: fix cross-build ndowens
                   ` (7 preceding siblings ...)
  2020-12-26  2:51 ` sgn
@ 2020-12-26  2:55 ` ndowens
  2020-12-28 13:19 ` [PR PATCH] [Closed]: " sgn
  9 siblings, 0 replies; 11+ messages in thread
From: ndowens @ 2020-12-26  2:55 UTC (permalink / raw)
  To: ml

[-- Attachment #1: Type: text/plain, Size: 306 bytes --]

New review comment by ndowens on void-packages repository

https://github.com/void-linux/void-packages/pull/27436#discussion_r548935380

Comment:
Doing that causes:
`configure.ac:113: error: possibly undefined macro: AC_DEFINE
      If this token and others are legitimate, please use m4_pattern_allow.`

^ permalink raw reply	[flat|nested] 11+ messages in thread

* Re: [PR PATCH] [Closed]: mvwm-git: fix cross-build
  2020-12-26  1:55 [PR PATCH] mvwm-git: fix cross-build ndowens
                   ` (8 preceding siblings ...)
  2020-12-26  2:55 ` ndowens
@ 2020-12-28 13:19 ` sgn
  9 siblings, 0 replies; 11+ messages in thread
From: sgn @ 2020-12-28 13:19 UTC (permalink / raw)
  To: ml

[-- Attachment #1: Type: text/plain, Size: 159 bytes --]

There's a closed pull request on the void-packages repository

mvwm-git: fix cross-build
https://github.com/void-linux/void-packages/pull/27436

Description:


^ permalink raw reply	[flat|nested] 11+ messages in thread

end of thread, other threads:[~2020-12-28 13:19 UTC | newest]

Thread overview: 11+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2020-12-26  1:55 [PR PATCH] mvwm-git: fix cross-build ndowens
2020-12-26  1:57 ` [PR PATCH] [Updated] " ndowens
2020-12-26  2:01 ` ndowens
2020-12-26  2:43 ` [PR REVIEW] " ericonr
2020-12-26  2:44 ` ndowens
2020-12-26  2:45 ` ericonr
2020-12-26  2:51 ` ericonr
2020-12-26  2:51 ` sgn
2020-12-26  2:51 ` sgn
2020-12-26  2:55 ` ndowens
2020-12-28 13:19 ` [PR PATCH] [Closed]: " sgn

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).