From: Andrea Zagli Date: Sat, 6 Sep 2014 21:52:12 +0000 (+0200) Subject: gcr pacchettizzato. X-Git-Url: https://saetta.ns0.it/gitweb?a=commitdiff_plain;h=75501831f203f90cfa732f5b6ab283337e828bc4;p=msys2 gcr pacchettizzato. --- diff --git a/.gitignore b/.gitignore index 09d06c8..d26b5cd 100644 --- a/.gitignore +++ b/.gitignore @@ -1 +1,2 @@ repository +tmp diff --git a/packages/mingw-w64-gcr/001-3.12.2.patch b/packages/mingw-w64-gcr/001-3.12.2.patch index 9bc6c5b..44dd337 100644 --- a/packages/mingw-w64-gcr/001-3.12.2.patch +++ b/packages/mingw-w64-gcr/001-3.12.2.patch @@ -1,5 +1,5 @@ --- gcr-3.12.2-orig/configure.ac 2014-05-13 21:03:55.000000000 +0200 -+++ gcr-3.12.2/configure.ac 2014-08-11 15:41:29.916433400 +0200 ++++ gcr-3.12.2/configure.ac 2014-09-06 11:46:03.751895300 +0200 @@ -75,6 +75,16 @@ AC_SUBST(GETTEXT_PACKAGE) AM_GLIB_GNU_GETTEXT @@ -9,9 +9,9 @@ +# + +if test "$os_unix" = "yes"; then -+ GDK_GIO_PACKAGE=gio-2.0 gio-unix-2.0 ++ GIO_PACKAGE="gio-2.0 gio-unix-2.0" +else -+ GDK_GIO_PACKAGE=gio-2.0 ++ GIO_PACKAGE="gio-2.0" +fi + # ----------------------------------------------------------------------------- @@ -22,11 +22,11 @@ gthread-2.0 gobject-2.0 - gio-2.0 gio-unix-2.0) -+ $GDK_GIO_PACKAGE) ++ $GIO_PACKAGE) GLIB_CFLAGS="$GLIB_CFLAGS -DGLIB_VERSION_MIN_REQUIRED=$GLIB_MIN" GLIB_CFLAGS="$GLIB_CFLAGS -DGLIB_VERSION_MAX_ALLOWED=$GLIB_MAX" AC_SUBST(GLIB_CFLAGS) -@@ -140,7 +150,18 @@ +@@ -140,7 +150,17 @@ # AC_CHECK_FUNCS(timegm, AC_DEFINE(HAVE_TIMEGM,1,[Have timegm])) @@ -41,11 +41,42 @@ +AC_CHECK_HEADERS(err.h, AC_DEFINE(HAVE_ERR_H,1,[Have err.h])) +AC_CHECK_HEADERS(pwd.h, AC_DEFINE(HAVE_PWD_H,1,[Have pwd.h])) +AC_CHECK_HEADERS(syslog.h, AC_DEFINE(HAVE_SYSLOG_H,1,[Have syslog.h])) -+AC_CHECK_HEADERS(sys/mman.h, AC_DEFINE(HAVE_SYS_MMAN_H,1,[Have mman.h])) +AC_CHECK_HEADERS(sys/wait.h, AC_DEFINE(HAVE_SYS_WAIT_H,1,[Have wait.h])) # -------------------------------------------------------------------- # p11-kit +--- gcr-3.12.2-orig/Makefile.am 2014-04-17 08:51:07.000000000 +0200 ++++ gcr-3.12.2/Makefile.am 2014-09-06 22:33:28.916978100 +0200 +@@ -164,6 +164,7 @@ + INTROSPECTION_GIRS = + INTROSPECTION_SCANNER_ARGS = $(INTROSPECTION_FLAGS) --warn-all --add-include-path=. + INTROSPECTION_COMPILER_ARGS = --includedir=. ++INTROSPECTION_SCANNER_ENV = CC="$(CC)" + + girdir = $(datadir)/gir-1.0 + gir_DATA = +--- gcr-3.12.2-orig/egg/Makefile.am 2014-05-13 21:01:43.000000000 +0200 ++++ gcr-3.12.2/egg/Makefile.am 2014-09-06 12:50:02.014502900 +0200 +@@ -13,7 +13,8 @@ + + libegg_la_LIBADD = \ + $(GLIB_LIBS) \ +- $(LIBGCRYPT_LIBS) ++ $(LIBGCRYPT_LIBS) \ ++ -lmman + + libegg_la_SOURCES = \ + egg/egg-armor.c egg/egg-armor.h \ +@@ -72,7 +73,8 @@ + egg_LDADD = \ + libegg.la \ + $(LIBGCRYPT_LIBS) \ +- $(GLIB_LIBS) ++ $(GLIB_LIBS) \ ++ -lmman + + egg_TESTS = \ + test-asn1 \ --- gcr-3.12.2-orig/egg/egg-armor.c 2014-03-03 21:05:24.000000000 +0100 +++ gcr-3.12.2/egg/egg-armor.c 2014-08-11 15:34:41.041658400 +0200 @@ -59,6 +59,29 @@ @@ -109,65 +140,8 @@ /* * Check if it's within 40 years before the --- gcr-3.12.2-orig/egg/egg-secure-memory.c 2014-03-03 21:05:24.000000000 +0100 -+++ gcr-3.12.2/egg/egg-secure-memory.c 2014-08-11 15:36:54.240479000 +0200 -@@ -31,7 +31,9 @@ - #include "egg-secure-memory.h" - - #include -+#ifdef HAVE_SYS_MMAN_H - #include -+#endif - #include - #include - #include -@@ -187,9 +189,11 @@ - - /* Create a new pool */ - if (pool == NULL) { -+#if !defined(_WIN32) - len = getpagesize () * 2; - pages = mmap (0, len, PROT_READ | PROT_WRITE, MAP_PRIVATE | MAP_ANON, -1, 0); - if (pages == MAP_FAILED) -+#endif - return NULL; - - /* Fill in the block header, and inlude in block list */ -@@ -253,7 +257,9 @@ - VALGRIND_DESTROY_MEMPOOL (pool); - #endif - -+#if !defined(_WIN32) - munmap (pool, pool->length); -+#endif - return; - } - -@@ -859,11 +865,11 @@ - ASSERT (*sz); - ASSERT (during_tag); - -+#if defined(HAVE_MLOCK) - /* Make sure sz is a multiple of the page size */ - pgsize = getpagesize (); - *sz = (*sz + pgsize -1) & ~(pgsize - 1); - --#if defined(HAVE_MLOCK) - pages = mmap (0, *sz, PROT_READ | PROT_WRITE, MAP_PRIVATE | MAP_ANON, -1, 0); - if (pages == MAP_FAILED) { - if (show_warning && egg_secure_warnings) -@@ -901,9 +907,10 @@ - sec_release_pages (void *pages, size_t sz) - { - ASSERT (pages); -- ASSERT (sz % getpagesize () == 0); - - #if defined(HAVE_MLOCK) -+ ASSERT (sz % getpagesize () == 0); -+ - if (munlock (pages, sz) < 0 && egg_secure_warnings) - fprintf (stderr, "couldn't unlock private memory: %s\n", strerror (errno)); - -@@ -913,7 +920,7 @@ ++++ gcr-3.12.2/egg/egg-secure-memory.c 2014-09-06 11:11:19.489433700 +0200 +@@ -913,7 +913,7 @@ DEBUG_ALLOC ("gkr-secure-memory: freed block ", sz); #else @@ -176,18 +150,6 @@ #endif } -@@ -936,6 +943,11 @@ - if (getenv ("SECMEM_FORCE_FALLBACK")) - return NULL; - -+#ifdef _WIN32 -+ /* win32 does not have mlock(), so just fail in that case */ -+ return NULL; -+#endif -+ - block = pool_alloc (); - if (!block) - return NULL; --- gcr-3.12.2-orig/egg/test-asn1x.c 2014-03-03 21:05:24.000000000 +0100 +++ gcr-3.12.2/egg/test-asn1x.c 2014-08-11 15:34:41.047660400 +0200 @@ -26,7 +26,9 @@ @@ -200,6 +162,40 @@ #include #include +--- gcr-3.12.2-orig/gck/Makefile.am 2014-03-03 21:05:24.000000000 +0100 ++++ gcr-3.12.2/gck/Makefile.am 2014-09-06 12:11:38.941793800 +0200 +@@ -71,7 +71,8 @@ + libegg-secmem.la \ + $(P11_KIT_LIBS) \ + $(GIO_LIBS) \ +- $(GLIB_LIBS) ++ $(GLIB_LIBS) \ ++ -lmman + + noinst_LTLIBRARIES += libgck-testable.la + libgck_testable_la_SOURCES = \ +@@ -193,7 +194,8 @@ + libegg-hex.la \ + $(GLIB_LIBS) \ + $(P11_KIT_LIBS) \ +- $(GIO_LIBS) ++ $(GIO_LIBS) \ ++ -lmman + + gck_TESTS = \ + test-gck-attributes \ +--- gcr-3.12.2-orig/gck/gck-attributes.c 2014-03-03 21:05:24.000000000 +0100 ++++ gcr-3.12.2/gck/gck-attributes.c 2014-09-06 22:14:58.034848700 +0200 +@@ -44,7 +44,9 @@ + * this library will operate on such an attribute. + */ + ++#ifndef __MINGW64_VERSION_MAJOR + G_STATIC_ASSERT (sizeof (GckAttribute) == sizeof (CK_ATTRIBUTE)); ++#endif + + #define STATE_LOCKED 1 + #define STATE_FLOATING 8 --- gcr-3.12.2-orig/gck/gck-debug.c 2014-03-02 09:05:22.000000000 +0100 +++ gcr-3.12.2/gck/gck-debug.c 2014-08-11 15:34:41.096675100 +0200 @@ -33,6 +33,11 @@ @@ -400,74 +396,6 @@ g_assert_no_error (err); g_assert (GCK_IS_MODULE (test->module)); ---- gcr-3.12.2-orig/gcr/gcr-enum-types-base.h 2014-05-13 21:05:40.000000000 +0200 -+++ gcr-3.12.2/gcr/gcr-enum-types-base.h 2014-08-11 16:55:02.607094500 +0200 -@@ -6,7 +6,7 @@ - - G_BEGIN_DECLS - --/* enumerations from "../gcr/gcr-certificate-chain.h" */ -+/* enumerations from "gcr/gcr-certificate-chain.h" */ - #ifndef GCR_TYPE_CERTIFICATE_CHAIN_STATUS - GType gcr_certificate_chain_status_get_type (void) G_GNUC_CONST; - #define GCR_TYPE_CERTIFICATE_CHAIN_STATUS (gcr_certificate_chain_status_get_type ()) -@@ -18,49 +18,49 @@ - #endif - - --/* enumerations from "../gcr/gcr-certificate-request.h" */ -+/* enumerations from "gcr/gcr-certificate-request.h" */ - #ifndef GCR_TYPE_CERTIFICATE_REQUEST_FORMAT - GType gcr_certificate_request_format_get_type (void) G_GNUC_CONST; - #define GCR_TYPE_CERTIFICATE_REQUEST_FORMAT (gcr_certificate_request_format_get_type ()) - #endif - - --/* enumerations from "../gcr/gcr-column.h" */ -+/* enumerations from "gcr/gcr-column.h" */ - #ifndef GCR_TYPE_COLUMN_FLAGS - GType gcr_column_flags_get_type (void) G_GNUC_CONST; - #define GCR_TYPE_COLUMN_FLAGS (gcr_column_flags_get_type ()) - #endif - - --/* enumerations from "../gcr/gcr-deprecated-base.h" */ -+/* enumerations from "gcr/gcr-deprecated-base.h" */ - #ifndef GCR_TYPE_IMPORTER_PROMPT_BEHAVIOR - GType gcr_importer_prompt_behavior_get_type (void) G_GNUC_CONST; - #define GCR_TYPE_IMPORTER_PROMPT_BEHAVIOR (gcr_importer_prompt_behavior_get_type ()) - #endif - - --/* enumerations from "../gcr/gcr-prompt.h" */ -+/* enumerations from "gcr/gcr-prompt.h" */ - #ifndef GCR_TYPE_PROMPT_REPLY - GType gcr_prompt_reply_get_type (void) G_GNUC_CONST; - #define GCR_TYPE_PROMPT_REPLY (gcr_prompt_reply_get_type ()) - #endif - - --/* enumerations from "../gcr/gcr-system-prompt.h" */ -+/* enumerations from "gcr/gcr-system-prompt.h" */ - #ifndef GCR_TYPE_SYSTEM_PROMPT_ERROR - GType gcr_system_prompt_error_get_type (void) G_GNUC_CONST; - #define GCR_TYPE_SYSTEM_PROMPT_ERROR (gcr_system_prompt_error_get_type ()) - #endif - - --/* enumerations from "../gcr/gcr-system-prompter.h" */ -+/* enumerations from "gcr/gcr-system-prompter.h" */ - #ifndef GCR_TYPE_SYSTEM_PROMPTER_MODE - GType gcr_system_prompter_mode_get_type (void) G_GNUC_CONST; - #define GCR_TYPE_SYSTEM_PROMPTER_MODE (gcr_system_prompter_mode_get_type ()) - #endif - - --/* enumerations from "../gcr/gcr-types.h" */ -+/* enumerations from "gcr/gcr-types.h" */ - #ifndef GCR_TYPE_DATA_ERROR - GType gcr_data_error_get_type (void) G_GNUC_CONST; - #define GCR_TYPE_DATA_ERROR (gcr_data_error_get_type ()) --- gcr-3.12.2-orig/gcr/gcr-gnupg-collection.c 2014-03-03 21:05:24.000000000 +0100 +++ gcr-3.12.2/gcr/gcr-gnupg-collection.c 2014-08-11 15:34:41.058659700 +0200 @@ -34,7 +34,9 @@ @@ -481,7 +409,7 @@ enum { --- gcr-3.12.2-orig/gcr/gcr-gnupg-process.c 2014-03-03 21:05:24.000000000 +0100 -+++ gcr-3.12.2/gcr/gcr-gnupg-process.c 2014-08-11 15:39:09.924362200 +0200 ++++ gcr-3.12.2/gcr/gcr-gnupg-process.c 2014-09-06 11:13:31.599364500 +0200 @@ -30,12 +30,25 @@ #include @@ -521,14 +449,12 @@ g_spawn_close_pid (gnupg_source->child_pid); gnupg_source->child_pid = 0; -@@ -890,11 +908,16 @@ +@@ -890,11 +908,14 @@ } complete_source_is_done (gnupg_source); + -+#ifdef G_OS_WIN32 + g_spawn_close_pid (pid); -+#endif } static void @@ -538,7 +464,7 @@ int *child_fds = user_data; long val; guint i; -@@ -910,6 +933,7 @@ +@@ -910,6 +931,7 @@ fcntl (child_fds[i], F_SETFD, val & ~FD_CLOEXEC); } } @@ -546,7 +472,7 @@ } static void -@@ -928,9 +952,16 @@ +@@ -928,9 +950,16 @@ /* Try and kill the child process */ if (gnupg_source->child_pid) { @@ -563,7 +489,7 @@ } } -@@ -999,14 +1030,22 @@ +@@ -999,14 +1028,22 @@ child_fds[FD_ERROR] = 2; if (flags & GCR_GNUPG_PROCESS_WITH_STATUS) { @@ -586,22 +512,7 @@ g_return_if_reached (); child_fds[FD_ATTRIBUTE] = attribute_fds[1]; g_ptr_array_add (args, g_strdup ("--attribute-fd")); -@@ -1035,11 +1074,11 @@ - - if (_gcr_debugging) { - gchar *command = g_strjoinv (" ", (gchar**)args->pdata); -- gchar *environ = g_strjoinv (", ", (gchar**)envs->pdata); -+ gchar *environment = g_strjoinv (", ", (gchar**)envs->pdata); - _gcr_debug ("running command: %s", command); -- _gcr_debug ("process environment: %s", environ); -+ _gcr_debug ("process environment: %s", environment); - g_free (command); -- g_free (environ); -+ g_free (environment); - } - - g_spawn_async_with_pipes (self->pv->directory, (gchar**)args->pdata, -@@ -1067,7 +1106,12 @@ +@@ -1067,7 +1104,12 @@ return; } @@ -660,8 +571,28 @@ +} \ Manca newline alla fine del file --- gcr-3.12.2-orig/gcr/Makefile.am 2014-04-17 08:51:07.000000000 +0200 -+++ gcr-3.12.2/gcr/Makefile.am 2014-08-11 16:46:47.349973900 +0200 -@@ -274,14 +274,10 @@ ++++ gcr-3.12.2/gcr/Makefile.am 2014-09-06 13:20:31.506762300 +0200 +@@ -134,7 +134,8 @@ + libgck-@GCK_MAJOR@.la \ + $(GLIB_LIBS) \ + $(LIBGCRYPT_LIBS) \ +- $(P11_KIT_LIBS) ++ $(P11_KIT_LIBS) \ ++ -lmman + + gcr/gcr-marshal.h: gcr/gcr-marshal.list $(GLIB_GENMARSHAL) + $(AM_V_GEN) $(GLIB_GENMARSHAL) $< --header --prefix=_gcr_marshal > $@ +@@ -266,7 +267,8 @@ + libgck-testable.la \ + $(GLIB_LIBS) \ + $(LIBGCRYPT_LIBS) \ +- $(P11_KIT_LIBS) ++ $(P11_KIT_LIBS) \ ++ -lmman + + gcr_TESTS = \ + test-util \ +@@ -274,14 +276,10 @@ test-secret-exchange \ test-simple-certificate \ test-certificate \ @@ -676,7 +607,7 @@ test-parser \ test-record \ test-memory-icon \ -@@ -294,10 +290,6 @@ +@@ -294,10 +292,6 @@ test_certificate_CFLAGS = $(gcr_CFLAGS) test_certificate_LDADD = $(gcr_LIBS) @@ -687,7 +618,7 @@ test_filter_collection_SOURCES = gcr/test-filter-collection.c test_filter_collection_CFLAGS = $(gcr_CFLAGS) test_filter_collection_LDADD = $(gcr_LIBS) -@@ -334,10 +326,6 @@ +@@ -334,10 +328,6 @@ test_parser_CFLAGS = $(gcr_CFLAGS) test_parser_LDADD = $(gcr_LIBS) @@ -698,7 +629,7 @@ test_record_SOURCES = gcr/test-record.c test_record_CFLAGS = $(gcr_CFLAGS) test_record_LDADD = $(gcr_LIBS) -@@ -354,18 +342,10 @@ +@@ -354,18 +344,10 @@ test_simple_certificate_CFLAGS = $(gcr_CFLAGS) test_simple_certificate_LDADD = $(gcr_LIBS) diff --git a/packages/mingw-w64-gcr/PKGBUILD b/packages/mingw-w64-gcr/PKGBUILD index 236f284..2f37975 100644 --- a/packages/mingw-w64-gcr/PKGBUILD +++ b/packages/mingw-w64-gcr/PKGBUILD @@ -6,16 +6,22 @@ pkgver=3.12.2 pkgrel=1 arch=('any') pkgdesc="Library for Crypto UI related task (mingw-w64)" -depends=("${MINGW_PACKAGE_PREFIX}-glib2" - "${MINGW_PACKAGE_PREFIX}-mman") -makedepends=("${MINGW_PACKAGE_PREFIX}-gcc") +depends=("${MINGW_PACKAGE_PREFIX}-gtk3" + "${MINGW_PACKAGE_PREFIX}-p11-kit" + "${MINGW_PACKAGE_PREFIX}-libgcrypt" + "${MINGW_PACKAGE_PREFIX}-mman-win32") +makedepends=("${MINGW_PACKAGE_PREFIX}-gcc" + "${MINGW_PACKAGE_PREFIX}-gtk-doc" + "${MINGW_PACKAGE_PREFIX}-vala" + "${MINGW_PACKAGE_PREFIX}-gobject-introspection" + "gnupg") options=('strip' 'staticlibs') license=("LGPL 2.1") url="http://www.gnome.org/" source=(http://ftp.gnome.org/pub/gnome/sources/${_realname}/${pkgver:0:4}/${_realname}-$pkgver.tar.xz 001-3.12.2.patch) -sha256sums=('fb70ab60d355edabb05cb82737f322111496b835a0db9e03acee6425891cfd0c' - '818ea2e238c3da0ad29f660502433e0c635ea0dfee17fefc980310ee9fed8381') +sha256sums=('456e20615ab178aa92eeabdea64dcce535c10d5af189171d9375291a2447d21c' + '0adafaa9626e16ac5a447058b0aa38a6f4f075b00b0a70e3f8ab6003ab5ef2e6') prepare() { cd ${_realname}-${pkgver} @@ -33,7 +39,8 @@ build() { --target=${MINGW_CHOST} \ --build=${MINGW_CHOST} \ --prefix=${MINGW_PREFIX} \ - --libexecdir=${MINGW_PREFIX}/lib + --libexecdir=${MINGW_PREFIX}/lib \ + --enable-introspection=no make }