summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--Makefile.am146
-rw-r--r--Makefile.decl60
-rw-r--r--build/Makefile.am33
-rwxr-xr-xbuild/tap-compiler174
-rwxr-xr-xbuild/tap-driver284
-rw-r--r--configure.ac15
-rw-r--r--docs/Makefile.am2
-rw-r--r--docs/reference/Makefile.am2
-rw-r--r--docs/reference/gck/Makefile.am4
-rw-r--r--docs/reference/gcr/Makefile.am8
-rw-r--r--egg/Makefile.am142
-rw-r--r--egg/egg-asn1x.c10
-rw-r--r--egg/egg-timegm.c2
-rw-r--r--egg/egg-timegm.h2
-rw-r--r--egg/fixtures/dh-params.pem (renamed from egg/tests/files/dh-params.pem)0
-rw-r--r--egg/fixtures/echo-script.sh (renamed from egg/tests/files/echo-script.sh)0
-rw-r--r--egg/fixtures/pem-rsa-enc.key (renamed from egg/tests/files/pem-rsa-enc.key)0
-rw-r--r--egg/fixtures/test-certificate-1.der (renamed from egg/tests/files/test-certificate-1.der)bin813 -> 813 bytes
-rw-r--r--egg/fixtures/test-personalname-1.der (renamed from egg/tests/files/test-personalname-1.der)0
-rw-r--r--egg/fixtures/test-personalname-invalid.der (renamed from egg/tests/files/test-personalname-invalid.der)0
-rw-r--r--egg/fixtures/test-pkcs12-1.der (renamed from egg/tests/files/test-pkcs12-1.der)bin2824 -> 2824 bytes
-rw-r--r--egg/fixtures/test-pkcs12-2.der (renamed from egg/tests/files/test-pkcs12-2.der)bin2142 -> 2142 bytes
-rwxr-xr-xegg/fixtures/test-pkcs7-1.der (renamed from egg/tests/files/test-pkcs7-1.der)bin1002 -> 1002 bytes
-rwxr-xr-xegg/fixtures/test-pkcs7-2.der (renamed from egg/tests/files/test-pkcs7-2.der)bin1002 -> 1002 bytes
-rw-r--r--egg/fixtures/test-pkcs8-1.der (renamed from egg/tests/files/test-pkcs8-1.der)bin335 -> 335 bytes
-rw-r--r--egg/fixtures/test-rsakey-1.der (renamed from egg/tests/files/test-rsakey-1.der)bin609 -> 609 bytes
-rw-r--r--egg/test-armor.c (renamed from egg/tests/test-armor.c)0
-rw-r--r--egg/test-asn1.c (renamed from egg/tests/test-asn1.c)2
-rw-r--r--egg/test-asn1x.c (renamed from egg/tests/test-asn1x.c)14
-rw-r--r--egg/test-decimal.c (renamed from egg/tests/test-decimal.c)0
-rw-r--r--egg/test-dh.c (renamed from egg/tests/test-dh.c)0
-rw-r--r--egg/test-dn.c (renamed from egg/tests/test-dn.c)2
-rw-r--r--egg/test-hex.c (renamed from egg/tests/test-hex.c)0
-rw-r--r--egg/test-hkdf.c (renamed from egg/tests/test-hkdf.c)0
-rw-r--r--egg/test-oid.c (renamed from egg/tests/test-oid.c)0
-rw-r--r--egg/test-openssl.c (renamed from egg/tests/test-openssl.c)2
-rw-r--r--egg/test-padding.c (renamed from egg/tests/test-padding.c)0
-rw-r--r--egg/test-secmem.c (renamed from egg/tests/test-secmem.c)0
-rw-r--r--egg/test-symkey.c (renamed from egg/tests/test-symkey.c)0
-rw-r--r--egg/test.asn (renamed from egg/tests/test.asn)0
-rw-r--r--egg/test.asn.h (renamed from egg/tests/test.asn.h)0
-rw-r--r--egg/tests/Makefile.am54
-rw-r--r--gck/Makefile.am293
-rw-r--r--gck/gck-module.c3
-rw-r--r--gck/gck-modules.c3
-rw-r--r--gck/gck-session.c3
-rw-r--r--gck/gck-uri.c3
-rw-r--r--gck/mock-interaction.c (renamed from gck/tests/mock-interaction.c)0
-rw-r--r--gck/mock-interaction.h (renamed from gck/tests/mock-interaction.h)0
-rw-r--r--gck/mock-test-module.c (renamed from gck/tests/mock-test-module.c)0
-rw-r--r--gck/test-gck-attributes.c (renamed from gck/tests/test-gck-attributes.c)0
-rw-r--r--gck/test-gck-crypto.c (renamed from gck/tests/test-gck-crypto.c)0
-rw-r--r--gck/test-gck-enumerator.c (renamed from gck/tests/test-gck-enumerator.c)0
-rw-r--r--gck/test-gck-module.c (renamed from gck/tests/test-gck-module.c)0
-rw-r--r--gck/test-gck-modules.c (renamed from gck/tests/test-gck-modules.c)0
-rw-r--r--gck/test-gck-object.c (renamed from gck/tests/test-gck-object.c)0
-rw-r--r--gck/test-gck-session.c (renamed from gck/tests/test-gck-session.c)0
-rw-r--r--gck/test-gck-slot.c (renamed from gck/tests/test-gck-slot.c)0
-rw-r--r--gck/test-gck-uri.c (renamed from gck/tests/test-gck-uri.c)0
-rw-r--r--gck/tests/Makefile.am67
-rw-r--r--gcr/Makefile.am488
-rw-r--r--gcr/console-interaction.c (renamed from gcr/tests/console-interaction.c)0
-rw-r--r--gcr/console-interaction.h (renamed from gcr/tests/console-interaction.h)0
-rw-r--r--gcr/fixtures/RSA_Root_Certificate_1.pem (renamed from gcr/tests/files/RSA_Root_Certificate_1.pem)0
-rw-r--r--gcr/fixtures/RSA_Security_1024_v3.pem (renamed from gcr/tests/files/RSA_Security_1024_v3.pem)0
-rw-r--r--gcr/fixtures/RSA_Security_2048_v3.pem (renamed from gcr/tests/files/RSA_Security_2048_v3.pem)0
-rw-r--r--gcr/fixtures/Thawte_Personal_Basic_CA.pem (renamed from gcr/tests/files/Thawte_Personal_Basic_CA.pem)0
-rw-r--r--gcr/fixtures/Thawte_Personal_Freemail_CA.pem (renamed from gcr/tests/files/Thawte_Personal_Freemail_CA.pem)0
-rw-r--r--gcr/fixtures/Thawte_Personal_Premium_CA.pem (renamed from gcr/tests/files/Thawte_Personal_Premium_CA.pem)0
-rw-r--r--gcr/fixtures/Thawte_Premium_Server_CA.pem (renamed from gcr/tests/files/Thawte_Premium_Server_CA.pem)0
-rw-r--r--gcr/fixtures/Thawte_Server_CA.pem (renamed from gcr/tests/files/Thawte_Server_CA.pem)0
-rw-r--r--gcr/fixtures/Thawte_Time_Stamping_CA.pem (renamed from gcr/tests/files/Thawte_Time_Stamping_CA.pem)0
-rw-r--r--gcr/fixtures/base64-rsa-2048.spkac (renamed from gcr/tests/files/base64-rsa-2048.spkac)0
-rw-r--r--gcr/fixtures/ca-certificates.crt (renamed from gcr/tests/files/ca-certificates.crt)0
-rw-r--r--gcr/fixtures/cacert.org.cer (renamed from gcr/tests/files/cacert.org.cer)bin1857 -> 1857 bytes
-rw-r--r--gcr/fixtures/cacert.org.pem (renamed from gcr/tests/files/cacert.org.pem)0
-rw-r--r--gcr/fixtures/client.crt (renamed from gcr/tests/files/client.crt)bin736 -> 736 bytes
-rw-r--r--gcr/fixtures/client.key (renamed from gcr/tests/files/client.key)0
-rw-r--r--gcr/fixtures/client.pem (renamed from gcr/tests/files/client.pem)0
-rw-r--r--gcr/fixtures/client.spk (renamed from gcr/tests/files/client.spk)bin294 -> 294 bytes
-rw-r--r--gcr/fixtures/collabora-ca.cer (renamed from gcr/tests/files/collabora-ca.cer)bin1536 -> 1536 bytes
-rwxr-xr-xgcr/fixtures/der-certificate-dsa.cer (renamed from gcr/tests/files/der-certificate-dsa.cer)bin1639 -> 1639 bytes
-rw-r--r--gcr/fixtures/der-certificate.crt (renamed from gcr/tests/files/der-certificate.crt)bin747 -> 747 bytes
-rw-r--r--gcr/fixtures/der-dsa-1024.key (renamed from gcr/tests/files/der-dsa-1024.key)bin447 -> 447 bytes
-rw-r--r--gcr/fixtures/der-key-PBE-MD5-DES.p8 (renamed from gcr/tests/files/der-key-PBE-MD5-DES.p8)bin677 -> 677 bytes
-rw-r--r--gcr/fixtures/der-key-PBE-SHA1-3DES.p8 (renamed from gcr/tests/files/der-key-PBE-SHA1-3DES.p8)bin678 -> 678 bytes
-rw-r--r--gcr/fixtures/der-key-PBE-SHA1-DES.p8 (renamed from gcr/tests/files/der-key-PBE-SHA1-DES.p8)bin677 -> 677 bytes
-rw-r--r--gcr/fixtures/der-key-PBE-SHA1-RC2-40.p8 (renamed from gcr/tests/files/der-key-PBE-SHA1-RC2-40.p8)bin678 -> 678 bytes
-rw-r--r--gcr/fixtures/der-key-PBE-SHA1-RC4-128.p8 (renamed from gcr/tests/files/der-key-PBE-SHA1-RC4-128.p8)bin673 -> 673 bytes
-rw-r--r--gcr/fixtures/der-key-dsa.p8 (renamed from gcr/tests/files/der-key-dsa.p8)bin335 -> 335 bytes
-rw-r--r--gcr/fixtures/der-key-encrypted-pkcs5.p8 (renamed from gcr/tests/files/der-key-encrypted-pkcs5.p8)bin677 -> 677 bytes
-rw-r--r--gcr/fixtures/der-key-v2-des.p8 (renamed from gcr/tests/files/der-key-v2-des.p8)bin711 -> 711 bytes
-rw-r--r--gcr/fixtures/der-key-v2-des3.p8 (renamed from gcr/tests/files/der-key-v2-des3.p8)bin714 -> 714 bytes
-rw-r--r--gcr/fixtures/der-key.p8 (renamed from gcr/tests/files/der-key.p8)bin635 -> 635 bytes
-rw-r--r--gcr/fixtures/der-rsa-1024.key (renamed from gcr/tests/files/der-rsa-1024.key)bin609 -> 609 bytes
-rw-r--r--gcr/fixtures/der-rsa-2048.p10 (renamed from gcr/tests/files/der-rsa-2048.p10)bin681 -> 681 bytes
-rw-r--r--gcr/fixtures/der-rsa-2048.spkac (renamed from gcr/tests/files/der-rsa-2048.spkac)bin592 -> 592 bytes
-rw-r--r--gcr/fixtures/dhansak-collabora.cer (renamed from gcr/tests/files/dhansak-collabora.cer)bin1200 -> 1200 bytes
-rw-r--r--gcr/fixtures/email.p12 (renamed from gcr/tests/files/email.p12)bin2488 -> 2488 bytes
-rw-r--r--gcr/fixtures/generic-dsa.crt (renamed from gcr/tests/files/generic-dsa.crt)bin918 -> 918 bytes
-rw-r--r--gcr/fixtures/generic-dsa.key (renamed from gcr/tests/files/generic-dsa.key)0
-rw-r--r--gcr/fixtures/generic-dsa.pem (renamed from gcr/tests/files/generic-dsa.pem)0
-rw-r--r--gcr/fixtures/generic-dsa.spk (renamed from gcr/tests/files/generic-dsa.spk)bin443 -> 443 bytes
-rw-r--r--gcr/fixtures/gnupg-homedir/gpg.conf (renamed from gcr/tests/files/gnupg-homedir/gpg.conf)1
-rw-r--r--gcr/fixtures/gnupg-homedir/pubring.gpg (renamed from gcr/tests/files/gnupg-homedir/pubring.gpg)bin21969 -> 21969 bytes
-rw-r--r--gcr/fixtures/gnupg-homedir/secring.gpg (renamed from gcr/tests/files/gnupg-homedir/secring.gpg)bin4398 -> 4398 bytes
-rw-r--r--gcr/fixtures/gnupg-homedir/trustdb.gpg (renamed from gcr/tests/files/gnupg-homedir/trustdb.gpg)bin1400 -> 1400 bytes
-rwxr-xr-xgcr/fixtures/gnupg-mock/mock-arguments-environ (renamed from gcr/tests/files/gnupg-mock/mock-arguments-environ)0
-rwxr-xr-xgcr/fixtures/gnupg-mock/mock-echo (renamed from gcr/tests/files/gnupg-mock/mock-echo)0
-rwxr-xr-xgcr/fixtures/gnupg-mock/mock-fail-exit (renamed from gcr/tests/files/gnupg-mock/mock-fail-exit)0
-rwxr-xr-xgcr/fixtures/gnupg-mock/mock-fail-signal (renamed from gcr/tests/files/gnupg-mock/mock-fail-signal)0
-rwxr-xr-xgcr/fixtures/gnupg-mock/mock-simple-error (renamed from gcr/tests/files/gnupg-mock/mock-simple-error)0
-rwxr-xr-xgcr/fixtures/gnupg-mock/mock-simple-output (renamed from gcr/tests/files/gnupg-mock/mock-simple-output)0
-rwxr-xr-xgcr/fixtures/gnupg-mock/mock-status-and-attribute (renamed from gcr/tests/files/gnupg-mock/mock-status-and-attribute)0
-rwxr-xr-xgcr/fixtures/gnupg-mock/mock-status-and-output (renamed from gcr/tests/files/gnupg-mock/mock-status-and-output)0
-rwxr-xr-xgcr/fixtures/gnupg-mock/mock-with-homedir (renamed from gcr/tests/files/gnupg-mock/mock-with-homedir)0
-rw-r--r--gcr/fixtures/jabber-server.cer (renamed from gcr/tests/files/jabber-server.cer)bin2095 -> 2095 bytes
-rw-r--r--gcr/fixtures/openssh_keys.pub (renamed from gcr/tests/files/openssh_keys.pub)0
-rw-r--r--gcr/fixtures/pem-dsa-1024.key (renamed from gcr/tests/files/pem-dsa-1024.key)0
-rw-r--r--gcr/fixtures/pem-pkcs8.key (renamed from gcr/tests/files/pem-pkcs8.key)0
-rw-r--r--gcr/fixtures/pem-rsa-2048.req (renamed from gcr/tests/files/pem-rsa-2048.req)0
-rw-r--r--gcr/fixtures/pem-rsa-enc.key (renamed from gcr/tests/files/pem-rsa-enc.key)0
-rw-r--r--gcr/fixtures/pem-with-attributes.req (renamed from gcr/tests/files/pem-with-attributes.req)0
-rw-r--r--gcr/fixtures/personal.p12 (renamed from gcr/tests/files/personal.p12)bin3396 -> 3396 bytes
-rw-r--r--gcr/fixtures/prompt-tests/multiple.prompt (renamed from gcr/tests/files/prompt-tests/multiple.prompt)0
-rw-r--r--gcr/fixtures/prompt-tests/password-choice.prompt (renamed from gcr/tests/files/prompt-tests/password-choice.prompt)0
-rw-r--r--gcr/fixtures/pubring.gpg (renamed from gcr/tests/files/pubring.gpg)bin21969 -> 21969 bytes
-rw-r--r--gcr/fixtures/secring.gpg (renamed from gcr/tests/files/secring.gpg)bin4398 -> 4398 bytes
-rw-r--r--gcr/fixtures/startcom-ca.cer (renamed from gcr/tests/files/startcom-ca.cer)bin1997 -> 1997 bytes
-rw-r--r--gcr/fixtures/startcom-intermediate.cer (renamed from gcr/tests/files/startcom-intermediate.cer)bin1592 -> 1592 bytes
-rwxr-xr-xgcr/fixtures/test-x509-swiss.p7b (renamed from gcr/tests/files/test-x509-swiss.p7b)bin1002 -> 1002 bytes
-rw-r--r--gcr/fixtures/unclient.p12 (renamed from gcr/tests/files/unclient.p12)bin1476 -> 1476 bytes
-rw-r--r--gcr/fixtures/usr0052-firefox.p12 (renamed from gcr/tests/files/usr0052-firefox.p12)bin2142 -> 2142 bytes
-rw-r--r--gcr/fixtures/werner-koch.asc (renamed from gcr/tests/files/werner-koch.asc)0
-rw-r--r--gcr/frob-certificate-request.c (renamed from gcr/tests/frob-certificate-request.c)0
-rw-r--r--gcr/frob-openpgp.c (renamed from gcr/tests/frob-openpgp.c)0
-rw-r--r--gcr/frob-parser.c (renamed from gcr/tests/frob-parser.c)0
-rw-r--r--gcr/gcr-certificate-chain.c3
-rw-r--r--gcr/gcr-certificate-extensions.c3
-rw-r--r--gcr/gcr-certificate-request.c5
-rw-r--r--gcr/gcr-certificate.c3
-rw-r--r--gcr/gcr-fingerprint.c3
-rw-r--r--gcr/gcr-gnupg-process.c3
-rw-r--r--gcr/gcr-importer.c3
-rw-r--r--gcr/gcr-parser.c5
-rw-r--r--gcr/gcr-subject-public-key.c3
-rw-r--r--gcr/gcr-system-prompt.c3
-rw-r--r--gcr/gcr-system-prompter.c7
-rw-r--r--gcr/test-certificate-chain.c (renamed from gcr/tests/test-certificate-chain.c)12
-rw-r--r--gcr/test-certificate.c (renamed from gcr/tests/test-certificate.c)6
-rw-r--r--gcr/test-filter-collection.c (renamed from gcr/tests/test-filter-collection.c)0
-rw-r--r--gcr/test-fingerprint.c (renamed from gcr/tests/test-fingerprint.c)8
-rw-r--r--gcr/test-gnupg-collection.c (renamed from gcr/tests/test-gnupg-collection.c)23
-rw-r--r--gcr/test-gnupg-key.c (renamed from gcr/tests/test-gnupg-key.c)0
-rw-r--r--gcr/test-gnupg-process.c (renamed from gcr/tests/test-gnupg-process.c)2
-rw-r--r--gcr/test-memory-icon.c (renamed from gcr/tests/test-memory-icon.c)0
-rw-r--r--gcr/test-openpgp.c (renamed from gcr/tests/test-openpgp.c)8
-rw-r--r--gcr/test-openssh.c (renamed from gcr/tests/test-openssh.c)0
-rw-r--r--gcr/test-parser.c (renamed from gcr/tests/test-parser.c)12
-rw-r--r--gcr/test-pkcs11-certificate.c (renamed from gcr/tests/test-pkcs11-certificate.c)4
-rw-r--r--gcr/test-record.c (renamed from gcr/tests/test-record.c)0
-rw-r--r--gcr/test-secret-exchange.c (renamed from gcr/tests/test-secret-exchange.c)0
-rw-r--r--gcr/test-secure-memory.c (renamed from gcr/tests/test-secure-memory.c)0
-rw-r--r--gcr/test-simple-certificate.c (renamed from gcr/tests/test-simple-certificate.c)2
-rw-r--r--gcr/test-subject-public-key.c (renamed from gcr/tests/test-subject-public-key.c)6
-rw-r--r--gcr/test-system-prompt.c (renamed from gcr/tests/test-system-prompt.c)0
-rw-r--r--gcr/test-trust.c (renamed from gcr/tests/test-trust.c)2
-rw-r--r--gcr/test-util.c (renamed from gcr/tests/test-util.c)0
-rw-r--r--gcr/tests/Makefile.am71
-rw-r--r--schema/Makefile.am8
-rw-r--r--testing/Makefile.am3
-rw-r--r--ui/Makefile.am377
-rw-r--r--ui/fixtures/ca-certificates.crt (renamed from ui/tests/files/ca-certificates.crt)0
-rw-r--r--ui/fixtures/der-certificate.crt (renamed from ui/tests/files/der-certificate.crt)bin747 -> 747 bytes
-rw-r--r--ui/fixtures/der-rsa-2048.p10 (renamed from ui/tests/files/der-rsa-2048.p10)bin681 -> 681 bytes
-rw-r--r--ui/fixtures/email.p12 (renamed from ui/tests/files/email.p12)bin2488 -> 2488 bytes
-rw-r--r--ui/fixtures/pem-dsa-1024.key (renamed from ui/tests/files/pem-dsa-1024.key)0
-rw-r--r--ui/frob-certificate.c (renamed from ui/tests/frob-certificate.c)2
-rw-r--r--ui/frob-combo-selector.c (renamed from ui/tests/frob-combo-selector.c)2
-rw-r--r--ui/frob-gnupg-selector.c (renamed from ui/tests/frob-gnupg-selector.c)0
-rw-r--r--ui/frob-import-button.c (renamed from ui/tests/frob-import-button.c)2
-rw-r--r--ui/frob-key.c (renamed from ui/tests/frob-key.c)2
-rw-r--r--ui/frob-prompt.c (renamed from ui/tests/frob-prompt.c)0
-rw-r--r--ui/frob-request.c (renamed from ui/tests/frob-request.c)2
-rw-r--r--ui/frob-system-prompt.c (renamed from ui/tests/frob-system-prompt.c)0
-rw-r--r--ui/frob-tree-selector.c (renamed from ui/tests/frob-tree-selector.c)2
-rw-r--r--ui/frob-unlock-options.c (renamed from ui/tests/frob-unlock-options.c)0
-rw-r--r--ui/frob-unlock.c (renamed from ui/tests/frob-unlock.c)2
-rw-r--r--ui/gcr-collection-model.c3
-rw-r--r--ui/gcr-live-search.c4
-rw-r--r--ui/gcr-ui.h2
-rw-r--r--ui/icons/Makefile.am22
-rw-r--r--ui/tests/Makefile.am42
193 files changed, 1517 insertions, 974 deletions
diff --git a/Makefile.am b/Makefile.am
index 8769a74..73b7f44 100644
--- a/Makefile.am
+++ b/Makefile.am
@@ -1,22 +1,10 @@
-include $(top_srcdir)/Makefile.decl
-
-if WITH_GTK
-UI_DIR = ui
-else
-UI_DIR =
-endif
+NULL =
SUBDIRS = \
. \
- build \
- egg \
- gck \
- gcr \
- $(UI_DIR) \
- schema \
- testing \
po \
- docs
+ docs/reference/gck \
+ docs/reference/gcr
ACLOCAL_AMFLAGS = -I build/m4 ${ACLOCAL_FLAGS}
@@ -29,7 +17,7 @@ EXTRA_DIST = \
DISTCHECK_CONFIGURE_FLAGS = \
--enable-gtk-doc \
--enable-strict \
- --disable-code-coverage \
+ --disable-coverage \
--disable-update-mime \
--disable-update-icon-cache \
--with-gtk \
@@ -55,10 +43,132 @@ dist-hook:
fi
check-memory:
- make -C egg check-memory
- make -C gck check-memory
make -C gcr check-memory
+check-local: check-gck-symbols check-gcr-symbols check-ui-symbols
+
upload-release: $(DIST_ARCHIVES)
scp $(DIST_ARCHIVES) master.gnome.org:
ssh master.gnome.org ftpadmin install $(DIST_ARCHIVES)
+
+AM_CPPFLAGS = \
+ -I$(srcdir) \
+ -I$(builddir) \
+ -I$(srcdir)/build \
+ -DSRCDIR="\"@abs_srcdir@\"" \
+ -DBUILDDIR="\"@abs_builddir@\"" \
+ -DLOCALEDIR=\""$(datadir)/locale"\" \
+ $(GLIB_CFLAGS)
+
+LDADD = \
+ $(GLIB_LIBS)
+
+LOG_DRIVER = $(srcdir)/build/tap-driver
+LOG_COMPILER = $(srcdir)/build/tap-compiler
+
+BUILT_SOURCES =
+TESTS =
+
+check_PROGRAMS =
+check_LTLIBRARIES =
+lib_LTLIBRARIES =
+noinst_LTLIBRARIES =
+noinst_PROGRAMS = $(check_PROGRAMS)
+
+pkgconfig_DATA =
+pkgconfigdir = $(libdir)/pkgconfig
+
+CLEANFILES = \
+ $(pkgconfig_DATA)
+
+TEST_SUPPRESSIONS = $(top_builddir)/build/valgrind-suppressions
+
+V_SED = $(V_SED_$(V))
+V_SED_ = $(V_SED_$(AM_DEFAULT_VERBOSITY))
+V_SED_0 = @echo " SED " $@;
+
+SED_SUBST = sed \
+ -e 's,[@]datadir[@],$(datadir),g' \
+ -e 's,[@]libexecdir[@],$(libexecdir),g' \
+ -e 's,[@]libdir[@],$(libdir),g' \
+ -e 's,[@]includedir[@],$(includedir),g' \
+ -e 's,[@]datarootdir[@],$(datarootdir),g' \
+ -e 's,[@]sysconfdir[@],$(sysconfdir),g' \
+ -e 's,[@]bindir[@],$(bindir),g' \
+ -e 's,[@]exec_prefix[@],$(exec_prefix),g' \
+ -e 's,[@]prefix[@],$(prefix),g' \
+ -e 's,[@]PACKAGE[@],$(PACKAGE),g' \
+ -e 's,[@]VERSION[@],$(VERSION),g' \
+ $(NULL)
+
+.desktop.in.in.desktop.in:
+ $(V_SED) $(SED_SUBST) $< > $@
+
+@INTLTOOL_DESKTOP_RULE@
+
+.service.in.service:
+ $(V_SED) $(SED_SUBST) $< > $@
+
+ENUM_TEMPLATE_C = $(top_srcdir)/build/enum-template.c
+ENUM_TEMPLATE_H = $(top_srcdir)/build/enum-template.h
+
+V_XSLTPROC = $(V_XSLTPROC_$(V))
+V_XSLTPROC_ = $(V_XSLTPROC_$(AM_DEFAULT_VERBOSITY))
+V_XSLTPROC_0 = @echo " XSLTPROC" $@;
+
+FIX_GIR = $(top_srcdir)/build/g-ir-unbreak.xsl
+
+.broken.gir.gir:
+ $(V_XSLTPROC) xsltproc -o $@ $(FIX_GIR) $<
+.broken.typelib.typelib:
+ $(AM_V_GEN) cp $< $@
+
+SUFFIXES = .desktop.in .desktop.in.in .service .service.in .broken.typelib .broken.gir .gir
+
+if HAVE_INTROSPECTION
+
+include $(INTROSPECTION_MAKEFILE)
+
+INTROSPECTION_GIRS =
+INTROSPECTION_SCANNER_ARGS = $(INTROSPECTION_FLAGS) --warn-all --add-include-path=.
+INTROSPECTION_COMPILER_ARGS = --includedir=.
+
+girdir = $(datadir)/gir-1.0
+gir_DATA =
+
+typelibsdir = $(libdir)/girepository-1.0
+typelibs_DATA = $(gir_DATA:.gir=.typelib)
+
+CLEANFILES += \
+ $(gir_DATA) \
+ $(typelibs_DATA) \
+ $(BUILT_SOURCES)
+
+if ENABLE_VAPIGEN
+
+include $(VAPIGEN_MAKEFILE)
+
+VAPIGEN_VAPIS =
+VAPI_DEPS = $(VAPIGEN_VAPIS:.vapi=.deps)
+
+vapidir = $(datadir)/vala/vapi
+vapi_DATA = $(VAPI_DEPS)
+
+CLEANFILES += \
+ $(VAPIGEN_VAPIS) \
+ $(VAPI_DEPS)
+
+endif
+
+endif
+
+include build/Makefile.am
+include egg/Makefile.am
+include gck/Makefile.am
+include gcr/Makefile.am
+include schema/Makefile.am
+
+if WITH_GTK
+include ui/Makefile.am
+include ui/icons/Makefile.am
+endif
diff --git a/Makefile.decl b/Makefile.decl
deleted file mode 100644
index 531cb72..0000000
--- a/Makefile.decl
+++ /dev/null
@@ -1,60 +0,0 @@
-NULL =
-
-TEST_ARGS =
-
-TEST_SUPPRESSIONS = $(top_builddir)/build/valgrind-suppressions
-
-perform-memcheck: $(TEST_PROGS)
- make -C $(top_builddir)/build all
- @for test in $(TEST_PROGS); do \
- G_SLICE=always-malloc libtool --mode=execute \
- valgrind --trace-children=no --gen-suppressions=all \
- --suppressions=$(TEST_SUPPRESSIONS) \
- --leak-check=full --show-reachable=yes --num-callers=16 \
- --quiet --error-exitcode=3 \
- $(builddir)/$$test $(TEST_ARGS) || exit 3; \
- done
-
-V_SED = $(V_SED_$(V))
-V_SED_ = $(V_SED_$(AM_DEFAULT_VERBOSITY))
-V_SED_0 = @echo " SED " $@;
-
-SED_SUBST = sed \
- -e 's,[@]datadir[@],$(datadir),g' \
- -e 's,[@]libexecdir[@],$(libexecdir),g' \
- -e 's,[@]libdir[@],$(libdir),g' \
- -e 's,[@]includedir[@],$(includedir),g' \
- -e 's,[@]datarootdir[@],$(datarootdir),g' \
- -e 's,[@]sysconfdir[@],$(sysconfdir),g' \
- -e 's,[@]bindir[@],$(bindir),g' \
- -e 's,[@]exec_prefix[@],$(exec_prefix),g' \
- -e 's,[@]prefix[@],$(prefix),g' \
- -e 's,[@]PACKAGE[@],$(PACKAGE),g' \
- -e 's,[@]VERSION[@],$(VERSION),g' \
- $(NULL)
-
-.desktop.in.in.desktop.in:
- $(V_SED) $(SED_SUBST) $< > $@
-
-@INTLTOOL_DESKTOP_RULE@
-
-.service.in.service:
- $(V_SED) $(SED_SUBST) $< > $@
-
-pkgconfigdir = $(libdir)/pkgconfig
-
-ENUM_TEMPLATE_C = $(top_srcdir)/build/enum-template.c
-ENUM_TEMPLATE_H = $(top_srcdir)/build/enum-template.h
-
-V_XSLTPROC = $(V_XSLTPROC_$(V))
-V_XSLTPROC_ = $(V_XSLTPROC_$(AM_DEFAULT_VERBOSITY))
-V_XSLTPROC_0 = @echo " XSLTPROC" $@;
-
-FIX_GIR = $(top_srcdir)/build/g-ir-unbreak.xsl
-
-.broken.gir.gir:
- $(V_XSLTPROC) xsltproc -o $@ $(FIX_GIR) $<
-.broken.typelib.typelib:
- $(AM_V_GEN) cp $< $@
-
-SUFFIXES = .desktop.in .desktop.in.in .service .service.in .broken.typelib .broken.gir .gir
diff --git a/build/Makefile.am b/build/Makefile.am
index 1b89dea..20cfa35 100644
--- a/build/Makefile.am
+++ b/build/Makefile.am
@@ -1,31 +1,34 @@
+# included in top-level Makefile.am
VALGRIND_CONTRIB = \
- valgrind/valgrind.h \
- valgrind/memcheck.h
+ build/valgrind/valgrind.h \
+ build/valgrind/memcheck.h
SUPPRESSIONS = \
- gcr.supp \
- gcrypt.supp \
- glib.supp \
- glibc.supp \
- p11-kit.supp \
- pixman.supp \
- pthread.supp \
- unknown.supp
+ build/gcr.supp \
+ build/gcrypt.supp \
+ build/glib.supp \
+ build/glibc.supp \
+ build/p11-kit.supp \
+ build/pixman.supp \
+ build/pthread.supp \
+ build/unknown.supp
valgrind-suppressions: $(SUPPRESSIONS)
$(AM_V_GEN) sh -c "cd $(srcdir) && cat $(SUPPRESSIONS)" > $@
-EXTRA_DIST = \
+EXTRA_DIST += \
$(VALGRIND_CONTRIB) \
$(SUPPRESSIONS) \
- enum-template.c \
- enum-template.h \
- g-ir-unbreak.xsl
+ build/enum-template.c \
+ build/enum-template.h \
+ build/g-ir-unbreak.xsl \
+ build/tap-driver \
+ build/tap-compiler
all-local: valgrind-suppressions
-CLEANFILES = \
+CLEANFILES += \
coverage \
coverage.info \
valgrind-suppressions
diff --git a/build/tap-compiler b/build/tap-compiler
new file mode 100755
index 0000000..76b3171
--- /dev/null
+++ b/build/tap-compiler
@@ -0,0 +1,174 @@
+#!/usr/bin/python
+
+# Copyright (C) 2014 Red Hat, Inc.
+#
+# Cockpit is free software; you can redistribute it and/or modify it
+# under the terms of the GNU Lesser General Public License as published by
+# the Free Software Foundation; either version 2.1 of the License, or
+# (at your option) any later version.
+#
+# Cockpit is distributed in the hope that it will be useful, but
+# WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+# Lesser General Public License for more details.
+#
+# You should have received a copy of the GNU Lesser General Public License
+# along with Cockpit; If not, see <http://www.gnu.org/licenses/>.
+
+#
+# This is a test output compiler which produces TAP from GTest output
+# if GTest output is detected.
+#
+# Versions of glib later than 2.38.x output TAP natively when tests are
+# run with the --tap option. However we can't depend on such a recent
+# version of glib for our purposes.
+#
+# This implements the Test Anything Protocol (ie: TAP)
+# https://metacpan.org/pod/release/PETDANCE/Test-Harness-2.64/lib/Test/Harness/TAP.pod
+#
+
+import argparse
+import os
+import select
+import subprocess
+import sys
+
+class NullCompiler:
+ def __init__(self, command):
+ self.command = command
+
+ def input(self, line):
+ sys.stdout.write(line)
+
+ def process(self, proc):
+ while True:
+ line = proc.stdout.readline()
+ if not line:
+ break
+ self.input(line)
+ proc.wait()
+ return proc.returncode
+
+ def run(self, proc, line=None):
+ if line:
+ self.input(line)
+ return self.process(proc)
+
+
+class GTestCompiler(NullCompiler):
+ def __init__(self, filename):
+ NullCompiler.__init__(self, filename)
+ self.test_num = 0
+ self.test_name = None
+ self.test_remaining = []
+
+ def input(self, line):
+ line = line.strip()
+ if line.startswith("GTest: "):
+ (cmd, unused, data) = line[7:].partition(": ")
+ cmd = cmd.strip()
+ data = data.strip()
+ if cmd == "run":
+ self.test_name = data
+ assert self.test_name in self.test_remaining, "%s %s" % (self.test_name, repr(self.test_remaining))
+ self.test_remaining.remove(self.test_name)
+ self.test_num += 1
+ elif cmd == "result":
+ if data == "OK":
+ print "ok %d %s" % (self.test_num, self.test_name)
+ if data == "FAIL":
+ print "not ok %d %s", (self.test_num, self.test_name)
+ self.test_name = None
+ elif cmd == "skipping":
+ print "ok %d # skip -- %s" % (self.test_num, self.test_name)
+ self.test_name = None
+ elif data:
+ print "# %s: %s" % (cmd, data)
+ else:
+ print "# %s" % cmd
+ elif line.startswith("(MSG: "):
+ print "# %s" % line[6:-1]
+ elif line:
+ print "# %s" % line
+ sys.stdout.flush()
+
+ def run(self, proc, output=""):
+ # Complete retrieval of the list of tests
+ output += proc.stdout.read()
+ proc.wait()
+ if proc.returncode:
+ raise subprocess.CalledProcessError(proc.returncode, self.command)
+ self.test_remaining = []
+ for line in output.split("\n"):
+ if line.startswith("/"):
+ self.test_remaining.append(line.strip())
+ if not self.test_remaining:
+ print "Bail out! No tests found in GTest: %s" % self.command[0]
+ return 0
+
+ print "1..%d" % len(self.test_remaining)
+
+ # First try to run all the tests in a batch
+ proc = subprocess.Popen(self.command + ["--verbose" ], close_fds=True, stdout=subprocess.PIPE)
+ result = self.process(proc)
+ if result == 0:
+ return 0
+
+ # Now pick up any stragglers due to failures
+ while True:
+ # Assume that the last test failed
+ if self.test_name:
+ print "not ok %d %s" % (self.test_num, self.test_name)
+ self.test_name = None
+
+ # Run any tests which didn't get run
+ if not self.test_remaining:
+ break
+
+ proc = subprocess.Popen(self.command + ["--verbose", "-p", self.test_remaining[0]],
+ close_fds=True, stdout=subprocess.PIPE)
+ result = self.process(proc)
+
+ # The various exit codes and signals we continue for
+ if result not in [ 0, 1, -4, -5, -6, -7, -8, -11 ]:
+ break
+
+ return result
+
+def main(argv):
+ parser = argparse.ArgumentParser(description='Automake TAP compiler')
+ parser.add_argument('--format', metavar='FORMAT', choices=[ "auto", "GTest", "TAP" ],
+ default="auto", help='The input format to compile')
+ parser.add_argument('--verbose', action='store_true',
+ default=True, help='Verbose mode (ignored)')
+ parser.add_argument('command', nargs='+', help="A test command to run")
+ args = parser.parse_args(argv[1:])
+
+ output = None
+ format = args.format
+ cmd = args.command
+ proc = None
+
+ if format in ["auto", "GTest"]:
+ list_cmd = cmd + ["-l", "--verbose"]
+ proc = subprocess.Popen(list_cmd, close_fds=True, stdout=subprocess.PIPE)
+ output = proc.stdout.readline()
+ # Smell whether we're dealing with GTest list output from first line
+ if "random seed" in output or "GTest" in output or output.startswith("/"):
+ format = "GTest"
+ else:
+ format = "TAP"
+ else:
+ proc = subprocess.Popen(cmd, close_fds=True, stdout=subprocess.PIPE)
+
+ if format == "GTest":
+ compiler = GTestCompiler(cmd)
+ elif format == "TAP":
+ compiler = NullCompiler(cmd)
+ else:
+ assert False, "not reached"
+
+ return compiler.run(proc, output)
+
+if __name__ == "__main__":
+ sys.exit(main(sys.argv))
diff --git a/build/tap-driver b/build/tap-driver
new file mode 100755
index 0000000..eb22462
--- /dev/null
+++ b/build/tap-driver
@@ -0,0 +1,284 @@
+#!/usr/bin/python
+
+# Copyright (C) 2013 Red Hat, Inc.
+#
+# Cockpit is free software; you can redistribute it and/or modify it
+# under the terms of the GNU Lesser General Public License as published by
+# the Free Software Foundation; either version 2.1 of the License, or
+# (at your option) any later version.
+#
+# Cockpit is distributed in the hope that it will be useful, but
+# WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+# Lesser General Public License for more details.
+#
+# You should have received a copy of the GNU Lesser General Public License
+# along with Cockpit; If not, see <http://www.gnu.org/licenses/>.
+
+#
+# This is a TAP driver for automake
+#
+# In particular it leaves stderr untouched, and is cleaner than the
+# one implemented in shell that is making the rounds.
+#
+# This implements the automake "Custom Test Driver" protocol:
+# https://www.gnu.org/software/automake/manual/html_node/Custom-Test-Drivers.html
+#
+# This consumes the Test Anything Protocol (ie: TAP)
+# https://metacpan.org/pod/release/PETDANCE/Test-Harness-2.64/lib/Test/Harness/TAP.pod
+#
+
+import argparse
+import os
+import select
+import subprocess
+import sys
+
+class Driver:
+ def __init__(self, command, args):
+ self.argv = command
+ self.output = ""
+ self.test_name = args.test_name
+ self.log = open(args.log_file, "w")
+ self.trs = open(args.trs_file, "w")
+ self.color_tests = args.color_tests
+ self.expect_failure = args.expect_failure
+ self.reported = { }
+ self.test_plan = None
+ self.late_plan = False
+ self.errored = False
+ self.bail_out = False
+
+ def report(self, code, num, *args):
+ CODES = {
+ "XPASS": '\x1b[0;31m', # red
+ "FAIL": '\x1b[0;31m', # red
+ "PASS": '\x1b[0;32m', # grn
+ "XFAIL": '\x1b[1;32m', # lgn
+ "SKIP": '\x1b[1;34m', # blu
+ "ERROR": '\x1b[0;35m', # mgn
+ }
+
+ # Print out to console
+ if self.color_tests:
+ if code in CODES:
+ sys.stdout.write(CODES[code])
+ sys.stdout.write(code)
+ if self.color_tests:
+ sys.stdout.write('\x1b[m')
+ sys.stdout.write(": ")
+ sys.stdout.write(self.test_name)
+ sys.stdout.write(" ")
+ if num:
+ sys.stdout.write(str(num))
+ sys.stdout.write(" ")
+ for arg in args:
+ sys.stdout.write(str(arg))
+ sys.stdout.write("\n")
+ sys.stdout.flush()
+
+ # Book keeping
+ if code in CODES:
+ if num != None:
+ self.reported[num] = code
+ self.trs.write(":test-result: %s\n" % code)
+ if code == "ERROR":
+ self.errored = True
+
+ def result_pass(self, num, description):
+ if self.expect_failure:
+ self.report("XPASS", num, description)
+ else:
+ self.report("PASS", num, description)
+
+ def result_fail(self, num, description):
+ if self.expect_failure:
+ self.report("XFAIL", num, description)
+ else:
+ self.report("FAIL", num, description)
+
+ def result_skip(self, num, description, ok):
+ if self.expect_failure:
+ self.report("XFAIL", num, description)
+ else:
+ self.report("SKIP", num, description)
+
+ def report_error(self, problem):
+ self.report("ERROR", None, problem)
+
+ def consume_test_line(self, ok, data):
+ # It's an error if the caller sends a test plan in the middle of tests
+ if self.late_plan:
+ self.report_error("Got tests after late TAP test plan")
+ self.late_plan = False
+
+ # Parse out a number and then description
+ (num, unused, description) = data.partition(" ")
+ try:
+ num = int(num)
+ except ValueError:
+ self.report_error("Invalid test number: %s" % data)
+ return
+ description = description.lstrip()
+
+ # Special case if description starts with this, then skip
+ if description.lower().startswith("# skip"):
+ self.result_skip(num, description, ok)
+ elif ok:
+ self.result_pass(num, description)
+ else:
+ self.result_fail(num, description)
+
+ def consume_test_plan(self, first, last):
+ # Only one test plan is supported
+ if self.test_plan:
+ self.report_error("Get a second TAP test plan")
+ return
+
+ try:
+ first = int(first)
+ last = int(last)
+ except ValueError:
+ self.report_error("Invalid test plan: %s..%s" % (first, last))
+ return
+
+ self.test_plan = (first, last)
+ self.late_plan = self.reported and True or False
+
+ def consume_bail_out(self, line):
+ self.bail_out = True
+ self.report("SKIP", 0, line)
+
+ def drain(self):
+ (ready, unused, self.output) = self.output.rpartition("\n")
+ for line in ready.split("\n"):
+ self.log.write(line)
+ self.log.write("\n")
+
+ if line.startswith("ok "):
+ self.consume_test_line(True, line[3:])
+ elif line.startswith("not ok "):
+ self.consume_test_line(False, line[7:])
+ elif line and line[0].isdigit() and ".." in line:
+ (first, unused, last) = line.partition("..")
+ self.consume_test_plan(first, last)
+ elif line.lower().startswith("bail out!"):
+ self.consume_bail_out(line)
+
+ def execute(self):
+ try:
+ proc = subprocess.Popen(self.argv, close_fds=True,
+ stdout=subprocess.PIPE,
+ stderr=subprocess.PIPE)
+ except OSError, ex:
+ self.report_error("Couldn't run %s: %s" % (self.argv[0], str(ex)))
+ return
+
+ outf = proc.stdout.fileno()
+ errf = proc.stderr.fileno()
+ rset = [outf, errf]
+ while len(rset) > 0:
+ ret = select.select(rset, [], [], 10)
+ if outf in ret[0]:
+ data = os.read(outf, 1024)
+ if data == "":
+ if self.output:
+ self.output += "\n"
+ rset.remove(outf)
+ else:
+ self.output += data
+ self.drain()
+ if errf in ret[0]:
+ data = os.read(errf, 1024)
+ if data == "":
+ rset.remove(errf)
+ self.log.write(data)
+ sys.stderr.write(data)
+
+ proc.wait()
+ self.returncode = proc.returncode
+
+ def run(self):
+ self.execute()
+
+ failed = False
+ skipped = True
+
+ # Basic collation of results
+ for (num, code) in self.reported.items():
+ if code == "ERROR":
+ self.errored = True
+ elif code == "FAIL" or code == "XPASS":
+ failed = True
+ if code != "SKIP":
+ skipped = False
+
+ # Check the plan
+ if not self.errored:
+ if not self.test_plan:
+ if not self.bail_out:
+ self.report_error("Didn't receive a TAP test plan")
+ else:
+ for i in range(self.test_plan[0], self.test_plan[1] + 1):
+ if i not in self.reported:
+ if self.bail_out:
+ self.report("SKIP", i, "- bailed out")
+ else:
+ self.report("ERROR", i, "- missing test")
+ skipped = False
+ self.errored = True
+
+ if self.errored:
+ self.trs.write(":global-test-result: ERROR\n")
+ self.trs.write(":test-global-result: ERROR\n")
+ self.trs.write(":recheck: no\n")
+ elif failed:
+ self.trs.write(":global-test-result: FAIL\n")
+ self.trs.write(":test-global-result: FAIL\n")
+ self.trs.write(":recheck: yes\n")
+ elif skipped:
+ self.trs.write(":global-test-result: SKIP\n")
+ self.trs.write(":test-global-result: SKIP\n")
+ self.trs.write(":recheck: no\n")
+ if self.errored or failed:
+ self.trs.write(":copy-in-global-log: yes\n")
+
+ # Process result code
+ return self.errored and 1 or 0
+
+class YesNoAction(argparse.Action):
+ def __init__(self, option_strings, dest, **kwargs):
+ argparse.Action.__init__(self, option_strings, dest, **kwargs)
+ self.metavar = "[yes|no]"
+ def __call__(self, parser, namespace, values, option_string=None):
+ if not values or "yes" in values:
+ setattr(namespace, self.dest, True)
+ else:
+ setattr(namespace, self.dest, False)
+
+def main(argv):
+ parser = argparse.ArgumentParser(description='Automake TAP driver')
+ parser.add_argument('--test-name', metavar='NAME',
+ help='The name of the test')
+ parser.add_argument('--log-file', metavar='PATH.log', required=True,
+ help='The .log file the driver creates')
+ parser.add_argument('--trs-file', metavar='PATH.trs', required=True,
+ help='The .trs file the driver creates')
+ parser.add_argument('--color-tests', default=True, action=YesNoAction,
+ help='Whether the console output should be colorized or not')
+ parser.add_argument('--expect-failure', default=False, action=YesNoAction,
+ help="Whether the tested program is expected to fail")
+ parser.add_argument('--enable-hard-errors', default=False, action=YesNoAction,
+ help="Whether hard errors in the tested program are treated differently")
+ parser.add_argument('command', nargs='+',
+ help="A test command line to run")
+ args = parser.parse_args(argv[1:])
+
+ if not args.test_name:
+ args.test_name = os.path.basename(args.command[0])
+
+ driver = Driver(args.command, args)
+ return driver.run()
+
+if __name__ == "__main__":
+ sys.exit(main(sys.argv))
diff --git a/configure.ac b/configure.ac
index 2e48d29..23bce0a 100644
--- a/configure.ac
+++ b/configure.ac
@@ -47,6 +47,7 @@ GCR_AGE=0
dnl ****************************************************************************
AC_CONFIG_MACRO_DIR([build/m4])
+AC_CONFIG_AUX_DIR([build])
AM_INIT_AUTOMAKE([1.11 tar-ustar foreign -Wno-portability])
AM_SANITY_CHECK
AC_CONFIG_HEADERS(config.h)
@@ -386,37 +387,23 @@ AC_SUBST(GCR_MICRO)
AC_OUTPUT([
Makefile
-build/Makefile
-docs/Makefile
-docs/reference/Makefile
docs/reference/gck/Makefile
docs/reference/gck/version.xml
docs/reference/gcr/Makefile
docs/reference/gcr/version.xml
-egg/Makefile
-egg/tests/Makefile
gck/gck.pc
gck/gck-version.h
-gck/Makefile
-gck/tests/Makefile
gcr/gcr-base.pc
gcr/gcr-version.h
-gcr/Makefile
-gcr/tests/Makefile
po/Makefile.in
-schema/Makefile
-testing/Makefile
ui/gcr.pc
ui/gcr-ui.pc
-ui/icons/Makefile
ui/icons/16x16/Makefile
ui/icons/22x22/Makefile
ui/icons/24x24/Makefile
ui/icons/32x32/Makefile
ui/icons/48x48/Makefile
ui/icons/256x256/Makefile
-ui/Makefile
-ui/tests/Makefile
])
# ------------------------------------------------------------------------------
diff --git a/docs/Makefile.am b/docs/Makefile.am
deleted file mode 100644
index cac25f2..0000000
--- a/docs/Makefile.am
+++ /dev/null
@@ -1,2 +0,0 @@
-
-SUBDIRS = reference
diff --git a/docs/reference/Makefile.am b/docs/reference/Makefile.am
deleted file mode 100644
index 6a9b2af..0000000
--- a/docs/reference/Makefile.am
+++ /dev/null
@@ -1,2 +0,0 @@
-
-SUBDIRS = gcr gck
diff --git a/docs/reference/gck/Makefile.am b/docs/reference/gck/Makefile.am
index d7351d4..5733c3d 100644
--- a/docs/reference/gck/Makefile.am
+++ b/docs/reference/gck/Makefile.am
@@ -17,7 +17,7 @@ DOC_MAIN_SGML_FILE=$(DOC_MODULE)-docs.sgml
# gtk-doc will search all .c & .h files beneath here for inline comments
# documenting the functions and macros.
# e.g. DOC_SOURCE_DIR=../../../gtk
-DOC_SOURCE_DIR=$(top_srcdir)/gck
+DOC_SOURCE_DIR=$(top_srcdir)/gck $(top_builddir)/gck
# Extra options to pass to gtkdoc-scangobj. Not normally needed.
SCANGOBJ_OPTIONS=
@@ -88,7 +88,7 @@ expand_content_files=
GTKDOC_CFLAGS= -I$(top_srcdir) -I$(top_builddir) $(GLIB_CFLAGS) -Wno-error \
-Wno-deprecated-declarations
GTKDOC_LIBS= $(GLIB_LIBS) \
- $(top_builddir)/$(DOC_MODULE)/lib$(DOC_MODULE)-@GCK_MAJOR@.la
+ $(top_builddir)/lib$(DOC_MODULE)-@GCK_MAJOR@.la
# This includes the standard gtk-doc make rules, copied by gtkdocize.
include $(top_srcdir)/gtk-doc.make
diff --git a/docs/reference/gcr/Makefile.am b/docs/reference/gcr/Makefile.am
index 37c1fc9..1c6a9ee 100644
--- a/docs/reference/gcr/Makefile.am
+++ b/docs/reference/gcr/Makefile.am
@@ -21,7 +21,7 @@ DOC_MAIN_SGML_FILE=$(DOC_MODULE)-docs.sgml
# gtk-doc will search all .c & .h files beneath here for inline comments
# documenting the functions and macros.
# e.g. DOC_SOURCE_DIR=../../../gtk
-DOC_SOURCE_DIR=$(top_srcdir)/$(DOC_MODULE) $(top_srcdir)/ui
+DOC_SOURCE_DIR=$(top_srcdir)/$(DOC_MODULE) $(top_srcdir)/ui $(top_builddir)/$(DOC_MODULE) $(top_builddir)/ui
# Extra options to pass to gtkdoc-scangobj. Not normally needed.
SCANGOBJ_OPTIONS=
@@ -121,9 +121,9 @@ expand_content_files=
GTKDOC_CFLAGS= -I$(top_srcdir) -I$(top_builddir) $(GLIB_CFLAGS) -Wno-error \
-Wno-deprecated-declarations
GTKDOC_LIBS= $(GLIB_LIBS) \
- $(top_builddir)/ui/libgcr-ui-@GCR_MAJOR@.la \
- $(top_builddir)/gcr/libgcr-base-@GCR_MAJOR@.la \
- $(top_builddir)/gck/libgck-@GCK_MAJOR@.la
+ $(top_builddir)/libgcr-ui-@GCR_MAJOR@.la \
+ $(top_builddir)/libgcr-base-@GCR_MAJOR@.la \
+ $(top_builddir)/libgck-@GCK_MAJOR@.la
# This includes the standard gtk-doc make rules, copied by gtkdocize.
include $(top_srcdir)/gtk-doc.make
diff --git a/egg/Makefile.am b/egg/Makefile.am
index e826a2c..9006b39 100644
--- a/egg/Makefile.am
+++ b/egg/Makefile.am
@@ -1,17 +1,12 @@
-include $(top_srcdir)/Makefile.decl
+# included in top-level Makefile.am
-noinst_LTLIBRARIES = \
+noinst_LTLIBRARIES += \
libegg.la \
libegg-asn1x.la \
libegg-hex.la \
libegg-secmem.la \
libegg-test.la
-AM_CPPFLAGS = \
- -I$(top_srcdir) \
- -I$(top_builddir) \
- -I$(top_srcdir)/build
-
libegg_la_CFLAGS = \
$(GLIB_CFLAGS) \
$(LIBGCRYPT_CFLAGS)
@@ -21,44 +16,38 @@ libegg_la_LIBADD = \
$(LIBGCRYPT_LIBS)
libegg_la_SOURCES = \
- egg-armor.c egg-armor.h \
- egg-asn1x.c egg-asn1x.h \
- egg-asn1-defs.c egg-asn1-defs.h \
- egg-buffer.c egg-buffer.h \
- egg-dh.c egg-dh.h \
- egg-dn.c egg-dn.h \
- egg-error.h \
- egg-decimal.c egg-decimal.h \
- egg-hex.c egg-hex.h \
- egg-hkdf.c egg-hkdf.h \
- egg-libgcrypt.c egg-libgcrypt.h \
- egg-oid.c egg-oid.h \
- egg-padding.c egg-padding.h \
- egg-openssl.c egg-openssl.h \
- egg-secure-memory.c egg-secure-memory.h \
- egg-symkey.c egg-symkey.h \
- egg-testing.c egg-testing.h \
- egg-timegm.c egg-timegm.h \
- pk.asn.h pkix.asn.h \
- $(NULL)
-
-EXTRA_DIST = \
- pk.asn \
- pkix.asn \
+ egg/egg-armor.c egg/egg-armor.h \
+ egg/egg-asn1x.c egg/egg-asn1x.h \
+ egg/egg-asn1-defs.c egg/egg-asn1-defs.h \
+ egg/egg-buffer.c egg/egg-buffer.h \
+ egg/egg-dh.c egg/egg-dh.h \
+ egg/egg-dn.c egg/egg-dn.h \
+ egg/egg-error.h \
+ egg/egg-decimal.c egg/egg-decimal.h \
+ egg/egg-hex.c egg/egg-hex.h \
+ egg/egg-hkdf.c egg/egg-hkdf.h \
+ egg/egg-libgcrypt.c egg/egg-libgcrypt.h \
+ egg/egg-oid.c egg/egg-oid.h \
+ egg/egg-padding.c egg/egg-padding.h \
+ egg/egg-openssl.c egg/egg-openssl.h \
+ egg/egg-secure-memory.c egg/egg-secure-memory.h \
+ egg/egg-symkey.c egg/egg-symkey.h \
+ egg/egg-testing.c egg/egg-testing.h \
+ egg/egg-timegm.c egg/egg-timegm.h \
+ egg/pk.asn.h egg/pkix.asn.h \
$(NULL)
# --------------------------------------------------------------------
# COMMON STUFF COMPILED INTO SMALLER COMPONENTS
libegg_asn1x_la_SOURCES = \
- egg-asn1x.c egg-asn1x.h \
- $(BUILT_SOURCES)
+ egg/egg-asn1x.c egg/egg-asn1x.h
libegg_asn1x_la_CFLAGS = \
$(GLIB_CFLAGS)
libegg_hex_la_SOURCES = \
- egg-hex.c egg-hex.h
+ egg/egg-hex.c egg/egg-hex.h
libegg_hex_la_CFLAGS = \
$(GLIB_CFLAGS)
@@ -67,10 +56,10 @@ libegg_hex_la_LIBADD = \
$(GLIB_LIBS)
libegg_secmem_la_SOURCES = \
- egg-secure-memory.c egg-secure-memory.h
+ egg/egg-secure-memory.c egg/egg-secure-memory.h
libegg_test_la_SOURCES = \
- egg-testing.c egg-testing.h
+ egg/egg-testing.c egg/egg-testing.h
libegg_test_la_CFLAGS = \
$(GLIB_CFLAGS)
@@ -80,12 +69,81 @@ libegg_test_la_LIBADD = \
# -------------------------------------------------------------------
-SUBDIRS = . tests
+egg_LDADD = \
+ libegg.la \
+ $(LIBGCRYPT_LIBS) \
+ $(GLIB_LIBS)
+
+egg_TESTS = \
+ test-asn1 \
+ test-asn1x \
+ test-dn \
+ test-decimal \
+ test-hex \
+ test-hkdf \
+ test-oid \
+ test-secmem \
+ test-padding \
+ test-symkey \
+ test-armor \
+ test-openssl \
+ test-dh
+
+test_armor_SOURCES = egg/test-armor.c
+test_armor_LDADD = $(egg_LDADD)
+
+test_asn1_SOURCES = egg/test-asn1.c egg/test.asn.h
+test_asn1_LDADD = $(egg_LDADD)
+
+test_asn1x_SOURCES = egg/test-asn1x.c
+test_asn1x_LDADD = $(egg_LDADD)
+
+test_decimal_SOURCES = egg/test-decimal.c
+test_decimal_LDADD = $(egg_LDADD)
+
+test_dh_SOURCES = egg/test-dh.c
+test_dh_LDADD = $(egg_LDADD)
-check-memory:
- make -C tests check-memory
+test_dn_SOURCES = egg/test-dn.c
+test_dn_LDADD = $(egg_LDADD)
+
+test_hex_SOURCES = egg/test-hex.c
+test_hex_LDADD = $(egg_LDADD)
+
+test_hkdf_SOURCES = egg/test-hkdf.c
+test_hkdf_LDADD = $(egg_LDADD)
+
+test_oid_SOURCES = egg/test-oid.c
+test_oid_LDADD = $(egg_LDADD)
+
+test_openssl_SOURCES = egg/test-openssl.c
+test_openssl_LDADD = $(egg_LDADD)
+
+test_padding_SOURCES = egg/test-padding.c
+test_padding_LDADD = $(egg_LDADD)
+
+test_secmem_SOURCES = egg/test-secmem.c
+test_secmem_LDADD = $(egg_LDADD)
+
+test_symkey_SOURCES = egg/test-symkey.c
+test_symkey_LDADD = $(egg_LDADD)
+
+check_PROGRAMS += $(egg_TESTS)
+TESTS += $(egg_TESTS)
+
+ASN_SRCS = \
+ egg/pk.asn \
+ egg/pkix.asn \
+ egg/test.asn \
+ $(NULL)
asn:
- asn1Parser -o pk.asn.h pk.asn
- asn1Parser -o pkix.asn.h pkix.asn
- sed -i 's|#include.*|/* \0 */|' pk.asn.h pkix.asn.h
+ for asn in $(ASN_SRCS); do \
+ asn1Parser -o $(srcdir)/$$asn.h $$asn \
+ sed -i 's|#include.*|/* \0 */|' $$asn.h \
+ done
+
+EXTRA_DIST += \
+ egg/fixtures \
+ $(ASN_SRCS) \
+ $(NULL)
diff --git a/egg/egg-asn1x.c b/egg/egg-asn1x.c
index 7ea1685..0daf2ef 100644
--- a/egg/egg-asn1x.c
+++ b/egg/egg-asn1x.c
@@ -4513,7 +4513,7 @@ traverse_and_dump (GNode *node, gpointer unused)
depth = g_node_depth (node);
for (i = 0; i < depth - 1; ++i)
- g_printerr (" ");
+ g_print (" ");
an = node->data;
output = g_string_new ("");
@@ -4521,14 +4521,14 @@ traverse_and_dump (GNode *node, gpointer unused)
dump_append_flags (output, anode_def_flags (node));
string = g_utf8_casefold (output->str, output->len - 1);
g_string_free (output, TRUE);
- g_printerr ("+ %s: %s [%s]%s\n", anode_def_name (node), anode_def_value (node),
- string, an->parsed || an->value ? " *" : "");
+ g_print ("+ %s: %s [%s]%s\n", anode_def_name (node), anode_def_value (node),
+ string, an->parsed || an->value ? " *" : "");
g_free (string);
/* Print out all the options */
for (l = an->opts; l; l = g_list_next (l)) {
for (i = 0; i < depth; ++i)
- g_printerr (" ");
+ g_print (" ");
def = l->data;
output = g_string_new ("");
@@ -4536,7 +4536,7 @@ traverse_and_dump (GNode *node, gpointer unused)
dump_append_flags (output, def->type);
string = g_utf8_casefold (output->str, output->len - 1);
g_string_free (output, TRUE);
- g_printerr ("- %s: %s [%s]\n", def->name, (const gchar*)def->value, string);
+ g_print ("- %s: %s [%s]\n", def->name, (const gchar*)def->value, string);
g_free (string);
}
diff --git a/egg/egg-timegm.c b/egg/egg-timegm.c
index a075d25..24faa4c 100644
--- a/egg/egg-timegm.c
+++ b/egg/egg-timegm.c
@@ -15,8 +15,6 @@
License along with the GNU C Library; see the file COPYING.LIB. If not,
see <http://www.gnu.org/licenses/>. */
-/* Extracted from misc/mkdtemp.c and sysdeps/posix/tempname.c. */
-
#ifdef HAVE_CONFIG_H
# include "config.h"
#endif
diff --git a/egg/egg-timegm.h b/egg/egg-timegm.h
index ad68d23..02bec8f 100644
--- a/egg/egg-timegm.h
+++ b/egg/egg-timegm.h
@@ -16,8 +16,6 @@
License along with the GNU C Library; see the file COPYING.LIB. If not,
see <http://www.gnu.org/licenses/>. */
-/* Extracted from misc/mkdtemp.c and sysdeps/posix/tempname.c. */
-
#ifndef EGG_TIMEGM_H_
#define EGG_TIMEGM_H_
diff --git a/egg/tests/files/dh-params.pem b/egg/fixtures/dh-params.pem
index cc0afd8..cc0afd8 100644
--- a/egg/tests/files/dh-params.pem
+++ b/egg/fixtures/dh-params.pem
diff --git a/egg/tests/files/echo-script.sh b/egg/fixtures/echo-script.sh
index aa0f7a9..aa0f7a9 100644
--- a/egg/tests/files/echo-script.sh
+++ b/egg/fixtures/echo-script.sh
diff --git a/egg/tests/files/pem-rsa-enc.key b/egg/fixtures/pem-rsa-enc.key
index 65439fe..65439fe 100644
--- a/egg/tests/files/pem-rsa-enc.key
+++ b/egg/fixtures/pem-rsa-enc.key
diff --git a/egg/tests/files/test-certificate-1.der b/egg/fixtures/test-certificate-1.der
index 1c08437..1c08437 100644
--- a/egg/tests/files/test-certificate-1.der
+++ b/egg/fixtures/test-certificate-1.der
Binary files differ
diff --git a/egg/tests/files/test-personalname-1.der b/egg/fixtures/test-personalname-1.der
index 13ba718..13ba718 100644
--- a/egg/tests/files/test-personalname-1.der
+++ b/egg/fixtures/test-personalname-1.der
diff --git a/egg/tests/files/test-personalname-invalid.der b/egg/fixtures/test-personalname-invalid.der
index 60d5d8c..60d5d8c 100644
--- a/egg/tests/files/test-personalname-invalid.der
+++ b/egg/fixtures/test-personalname-invalid.der
diff --git a/egg/tests/files/test-pkcs12-1.der b/egg/fixtures/test-pkcs12-1.der
index 285d8dd..285d8dd 100644
--- a/egg/tests/files/test-pkcs12-1.der
+++ b/egg/fixtures/test-pkcs12-1.der
Binary files differ
diff --git a/egg/tests/files/test-pkcs12-2.der b/egg/fixtures/test-pkcs12-2.der
index eff8c1e..eff8c1e 100644
--- a/egg/tests/files/test-pkcs12-2.der
+++ b/egg/fixtures/test-pkcs12-2.der
Binary files differ
diff --git a/egg/tests/files/test-pkcs7-1.der b/egg/fixtures/test-pkcs7-1.der
index d45b9e0..d45b9e0 100755
--- a/egg/tests/files/test-pkcs7-1.der
+++ b/egg/fixtures/test-pkcs7-1.der
Binary files differ
diff --git a/egg/tests/files/test-pkcs7-2.der b/egg/fixtures/test-pkcs7-2.der
index d45b9e0..d45b9e0 100755
--- a/egg/tests/files/test-pkcs7-2.der
+++ b/egg/fixtures/test-pkcs7-2.der
Binary files differ
diff --git a/egg/tests/files/test-pkcs8-1.der b/egg/fixtures/test-pkcs8-1.der
index 8b61684..8b61684 100644
--- a/egg/tests/files/test-pkcs8-1.der
+++ b/egg/fixtures/test-pkcs8-1.der
Binary files differ
diff --git a/egg/tests/files/test-rsakey-1.der b/egg/fixtures/test-rsakey-1.der
index 878fda5..878fda5 100644
--- a/egg/tests/files/test-rsakey-1.der
+++ b/egg/fixtures/test-rsakey-1.der
Binary files differ
diff --git a/egg/tests/test-armor.c b/egg/test-armor.c
index eecb285..eecb285 100644
--- a/egg/tests/test-armor.c
+++ b/egg/test-armor.c
diff --git a/egg/tests/test-asn1.c b/egg/test-asn1.c
index 36912f8..883c92b 100644
--- a/egg/tests/test-asn1.c
+++ b/egg/test-asn1.c
@@ -1745,7 +1745,7 @@ setup (Test *test, gconstpointer unused)
{
GBytes *bytes;
- if (!g_file_get_contents (SRCDIR "/files/test-certificate-1.der",
+ if (!g_file_get_contents (SRCDIR "/egg/fixtures/test-certificate-1.der",
(gchar**)&test->data, &test->n_data, NULL))
g_assert_not_reached ();
diff --git a/egg/tests/test-asn1x.c b/egg/test-asn1x.c
index f4d8e33..fec410e 100644
--- a/egg/tests/test-asn1x.c
+++ b/egg/test-asn1x.c
@@ -74,11 +74,11 @@ typedef struct {
} Fixture;
static const Fixture parse_test_fixtures[] = {
- { pkix_asn1_tab, SRCDIR "/files/test-certificate-1.der", "Certificate" },
- { pkix_asn1_tab, SRCDIR "/files/test-pkcs8-1.der", "pkcs-8-PrivateKeyInfo" },
- { pk_asn1_tab, SRCDIR "/files/test-rsakey-1.der", "RSAPrivateKey" },
- { pkix_asn1_tab, SRCDIR "/files/test-pkcs7-1.der", "pkcs-7-ContentInfo" },
- { pkix_asn1_tab, SRCDIR "/files/test-pkcs7-2.der", "pkcs-7-ContentInfo" },
+ { pkix_asn1_tab, SRCDIR "/egg/fixtures/test-certificate-1.der", "Certificate" },
+ { pkix_asn1_tab, SRCDIR "/egg/fixtures/test-pkcs8-1.der", "pkcs-8-PrivateKeyInfo" },
+ { pk_asn1_tab, SRCDIR "/egg/fixtures/test-rsakey-1.der", "RSAPrivateKey" },
+ { pkix_asn1_tab, SRCDIR "/egg/fixtures/test-pkcs7-1.der", "pkcs-7-ContentInfo" },
+ { pkix_asn1_tab, SRCDIR "/egg/fixtures/test-pkcs7-2.der", "pkcs-7-ContentInfo" },
};
static void
@@ -191,9 +191,9 @@ main (int argc, char **argv)
g_free (name);
}
- g_test_add ("/asn1x/pkcs12-decode/1", Test, SRCDIR "/files/test-pkcs12-1.der",
+ g_test_add ("/asn1x/pkcs12-decode/1", Test, SRCDIR "/egg/fixtures/test-pkcs12-1.der",
setup, test_pkcs12_decode, teardown);
- g_test_add ("/asn1x/pkcs5-personal-name/invalid", Test, SRCDIR "/files/test-personalname-invalid.der",
+ g_test_add ("/asn1x/pkcs5-personal-name/invalid", Test, SRCDIR "/egg/fixtures/test-personalname-invalid.der",
setup, test_personal_name_invalid, teardown);
return g_test_run ();
diff --git a/egg/tests/test-decimal.c b/egg/test-decimal.c
index 051a95e..051a95e 100644
--- a/egg/tests/test-decimal.c
+++ b/egg/test-decimal.c
diff --git a/egg/tests/test-dh.c b/egg/test-dh.c
index c95f479..c95f479 100644
--- a/egg/tests/test-dh.c
+++ b/egg/test-dh.c
diff --git a/egg/tests/test-dn.c b/egg/test-dn.c
index 3cc0561..f209068 100644
--- a/egg/tests/test-dn.c
+++ b/egg/test-dn.c
@@ -46,7 +46,7 @@ setup (Test *test, gconstpointer unused)
{
GBytes *bytes;
- if (!g_file_get_contents (SRCDIR "/files/test-certificate-1.der",
+ if (!g_file_get_contents (SRCDIR "/egg/fixtures/test-certificate-1.der",
(gchar**)&test->data, &test->n_data, NULL))
g_assert_not_reached ();
diff --git a/egg/tests/test-hex.c b/egg/test-hex.c
index 6bb8c5b..6bb8c5b 100644
--- a/egg/tests/test-hex.c
+++ b/egg/test-hex.c
diff --git a/egg/tests/test-hkdf.c b/egg/test-hkdf.c
index 14d7fd2..14d7fd2 100644
--- a/egg/tests/test-hkdf.c
+++ b/egg/test-hkdf.c
diff --git a/egg/tests/test-oid.c b/egg/test-oid.c
index 21ae128..21ae128 100644
--- a/egg/tests/test-oid.c
+++ b/egg/test-oid.c
diff --git a/egg/tests/test-openssl.c b/egg/test-openssl.c
index cf3fd4c..b18565f 100644
--- a/egg/tests/test-openssl.c
+++ b/egg/test-openssl.c
@@ -53,7 +53,7 @@ setup (Test *test, gconstpointer unused)
gchar *contents;
gsize length;
- if (!g_file_get_contents (SRCDIR "/files/pem-rsa-enc.key", &contents, &length, NULL))
+ if (!g_file_get_contents (SRCDIR "/egg/fixtures/pem-rsa-enc.key", &contents, &length, NULL))
g_assert_not_reached ();
test->input = g_bytes_new_take (contents, length);
diff --git a/egg/tests/test-padding.c b/egg/test-padding.c
index d6c0443..d6c0443 100644
--- a/egg/tests/test-padding.c
+++ b/egg/test-padding.c
diff --git a/egg/tests/test-secmem.c b/egg/test-secmem.c
index 8a63983..8a63983 100644
--- a/egg/tests/test-secmem.c
+++ b/egg/test-secmem.c
diff --git a/egg/tests/test-symkey.c b/egg/test-symkey.c
index f363681..f363681 100644
--- a/egg/tests/test-symkey.c
+++ b/egg/test-symkey.c
diff --git a/egg/tests/test.asn b/egg/test.asn
index 05676d7..05676d7 100644
--- a/egg/tests/test.asn
+++ b/egg/test.asn
diff --git a/egg/tests/test.asn.h b/egg/test.asn.h
index f2983e9..f2983e9 100644
--- a/egg/tests/test.asn.h
+++ b/egg/test.asn.h
diff --git a/egg/tests/Makefile.am b/egg/tests/Makefile.am
deleted file mode 100644
index e96a722..0000000
--- a/egg/tests/Makefile.am
+++ /dev/null
@@ -1,54 +0,0 @@
-include $(top_srcdir)/Makefile.decl
-
-AM_CPPFLAGS = \
- -I$(top_builddir) \
- -I$(top_srcdir) \
- -DSRCDIR="\"@abs_srcdir@\"" \
- $(GLIB_CFLAGS) \
- $(LIBGCRYPT_CFLAGS)
-
-LDADD = \
- $(top_builddir)/egg/libegg.la \
- $(LIBGCRYPT_LIBS) \
- $(GTHREAD_LIBS) \
- $(GLIB_LIBS)
-
-TEST_PROGS = \
- test-asn1 \
- test-asn1x \
- test-dn \
- test-decimal \
- test-hex \
- test-hkdf \
- test-oid \
- test-secmem \
- test-padding \
- test-symkey \
- test-armor \
- test-openssl \
- test-dh
-
-test_asn1_SOURCES = \
- test-asn1.c \
- test.asn.h \
- $(NULL)
-
-check_PROGRAMS = $(TEST_PROGS)
-
-test: $(TEST_PROGS)
- gtester --verbose -m $(TEST_MODE) --g-fatal-warnings $(TEST_PROGS)
-
-check-local: test
-
-check-memory: perform-memcheck
-
-all-local: $(check_PROGRAMS)
-
-EXTRA_DIST = \
- test.asn \
- files \
- $(NULL)
-
-asn:
- asn1Parser -o test.asn.h test.asn
- sed -i 's|#include.*|/* \0 */|' test.asn.h
diff --git a/gck/Makefile.am b/gck/Makefile.am
index 4779c37..8c4951c 100644
--- a/gck/Makefile.am
+++ b/gck/Makefile.am
@@ -1,116 +1,113 @@
-include $(top_srcdir)/Makefile.decl
+# included in top-level Makefile.am
+
+gck_incdir = $(includedir)/gck-@GCK_MAJOR@/gck
+
+gck_HEADER_FILES = \
+ gck/gck.h \
+ gck/gck-deprecated.h
+
+gck_inc_HEADERS = \
+ $(gck_HEADER_FILES) \
+ gck/gck-enum-types.h \
+ gck/gck-version.h \
+ gck/pkcs11.h \
+ gck/pkcs11n.h \
+ gck/pkcs11x.h
+
+gck_BUILT_SOURCES = \
+ gck/gck-marshal.c gck/gck-marshal.h \
+ gck/gck-enum-types.c gck/gck-enum-types.h
+
+BUILT_SOURCES += $(gck_BUILT_SOURCES)
+
+lib_LTLIBRARIES += libgck-@GCK_MAJOR@.la
+
+gck_PUBLIC_FILES = \
+ gck/gck.h \
+ gck/gck-enum-types.h \
+ gck/gck-attributes.c \
+ gck/gck-dump.c \
+ gck/gck-enumerator.c \
+ gck/gck-misc.c \
+ gck/gck-module.c \
+ gck/gck-modules.c \
+ gck/gck-object.c \
+ gck/gck-object-cache.c \
+ gck/gck-password.c \
+ gck/gck-session.c \
+ gck/gck-slot.c \
+ gck/gck-uri.c \
+ gck/gck-version.h
+
+gck_INTERNAL_FILES = \
+ gck/gck-call.c \
+ gck/gck-debug.c gck/gck-debug.h \
+ gck/gck-deprecated.h \
+ gck/gck-interaction.c \
+ gck/gck-private.h \
+ gck/pkcs11.h
-SUBDIRS = . tests
-
-incdir = $(includedir)/gck-@GCK_MAJOR@/gck
-
-HEADER_FILES = \
- gck.h \
- gck-deprecated.h
+libgck_@GCK_MAJOR@_la_SOURCES = \
+ $(gck_PUBLIC_FILES) \
+ $(gck_INTERNAL_FILES)
-inc_HEADERS = \
- $(HEADER_FILES) \
- gck-enum-types.h \
- gck-version.h \
- pkcs11.h \
- pkcs11n.h \
- pkcs11x.h
+nodist_libgck_@GCK_MAJOR@_la_SOURCES = \
+ $(gck_BUILT_SOURCES)
-AM_CPPFLAGS = \
- -I$(top_builddir) \
- -I$(top_srcdir)/gcr \
- -I$(top_srcdir) \
+libgck_@GCK_MAJOR@_la_CFLAGS = \
$(P11_KIT_CFLAGS) \
- $(GTHREAD_CFLAGS) \
- $(GLIB_CFLAGS) \
-DG_LOG_DOMAIN=\"Gck\" \
-DGCK_API_SUBJECT_TO_CHANGE \
-DP11_KIT_API_SUBJECT_TO_CHANGE \
-DPKCS11_REGISTRY_DIR=\"$(libdir)/pkcs11\"
-BUILT_SOURCES = \
- gck-marshal.c gck-marshal.h \
- gck-enum-types.c gck-enum-types.h
-
-lib_LTLIBRARIES = libgck-@GCK_MAJOR@.la
-
-PUBLIC_FILES = \
- gck.h \
- gck-enum-types.h \
- gck-attributes.c \
- gck-dump.c \
- gck-enumerator.c \
- gck-misc.c \
- gck-module.c \
- gck-modules.c \
- gck-object.c \
- gck-object-cache.c \
- gck-password.c \
- gck-session.c \
- gck-slot.c \
- gck-uri.c \
- gck-version.h
-
-INTERNAL_FILES = \
- gck-call.c \
- gck-debug.c gck-debug.h \
- gck-deprecated.h \
- gck-interaction.c \
- gck-private.h \
- pkcs11.h
-
-libgck_@GCK_MAJOR@_la_SOURCES = \
- $(PUBLIC_FILES) \
- $(INTERNAL_FILES)
-
-nodist_libgck_@GCK_MAJOR@_la_SOURCES = \
- $(BUILT_SOURCES)
-
libgck_@GCK_MAJOR@_la_LDFLAGS = \
-version-info $(GCK_LT_RELEASE) \
-no-undefined \
-export-symbols-regex '^gck_.*|^SECMEM_.*'
libgck_@GCK_MAJOR@_la_LIBADD = \
- $(top_builddir)/egg/libegg-hex.la \
- $(top_builddir)/egg/libegg-secmem.la \
+ libegg-hex.la \
+ libegg-secmem.la \
$(P11_KIT_LIBS) \
- $(GTHREAD_LIBS) \
$(GIO_LIBS) \
$(GLIB_LIBS)
-noinst_LTLIBRARIES = libgck-testable.la
+noinst_LTLIBRARIES += libgck-testable.la
libgck_testable_la_SOURCES = \
- gck-mock.c \
- gck-mock.h \
- gck-test.c \
- gck-test.h
-libgck_testable_la_LIBADD = $(libgck_@GCK_MAJOR@_la_OBJECTS) \
+ gck/gck-mock.c gck/gck-mock.h \
+ gck/gck-test.c gck/gck-test.h
+
+libgck_testable_la_CFLAGS = \
+ $(libgck_@GCK_MAJOR@_la_CFLAGS)
+
+libgck_testable_la_LIBADD = \
+ $(libgck_@GCK_MAJOR@_la_OBJECTS) \
$(libgck_@GCK_MAJOR@_la_LIBADD)
libgck_testable_la_DEPENDENCIES = $(libgck_@GCK_MAJOR@_la_OBJECTS)
-gck-marshal.h: gck-marshal.list $(GLIB_GENMARSHAL)
+gck/gck-marshal.h: gck/gck-marshal.list $(GLIB_GENMARSHAL)
$(AM_V_GEN) $(GLIB_GENMARSHAL) $< --header --prefix=_gck_marshal > $@
-gck-marshal.c: gck-marshal.list $(GLIB_GENMARSHAL)
- $(AM_V_GEN) echo "#include \"gck-marshal.h\"" > $@ && \
+gck/gck-marshal.c: gck/gck-marshal.list $(GLIB_GENMARSHAL)
+ $(AM_V_GEN) echo "#include \"gck/gck-marshal.h\"" > $@ && \
$(GLIB_GENMARSHAL) $< --body --prefix=_gck_marshal >> $@
-gck-enum-types.h: $(ENUM_TEMPLATE_H) $(HEADER_FILES)
+gck/gck-enum-types.h: $(ENUM_TEMPLATE_H) $(gck_HEADER_FILES)
$(AM_V_GEN) $(GLIB_MKENUMS) --template $^ > $@
-gck-enum-types.c: $(ENUM_TEMPLATE_C) $(HEADER_FILES)
+gck/gck-enum-types.c: $(ENUM_TEMPLATE_C) $(gck_HEADER_FILES)
$(AM_V_GEN) $(GLIB_MKENUMS) --template $^ > $@
-EXTRA_DIST = \
- gck.pc.in \
- gck-marshal.list \
- gck-version.h \
- gck.symbols \
- pkcs11-trust-assertions.h \
- pkcs11i.h
+EXTRA_DIST += \
+ gck/gck.pc.in \
+ gck/gck-marshal.list \
+ gck/gck-version.h \
+ gck/gck.symbols \
+ gck/pkcs11-trust-assertions.h \
+ gck/pkcs11i.h
-CLEANFILES = \
+CLEANFILES += \
gck-$(GCK_MAJOR).pc \
$(gir_DATA) \
$(typelibs_DATA) \
@@ -123,11 +120,7 @@ CLEANFILES = \
if HAVE_INTROSPECTION
-include $(INTROSPECTION_MAKEFILE)
-
-INTROSPECTION_GIRS = Gck-@GCK_MAJOR@.gir
-INTROSPECTION_SCANNER_ARGS = $(INTROSPECTION_FLAGS) --warn-all --add-include-path=$(srcdir) --add-include-path=.
-INTROSPECTION_COMPILER_ARGS = --includedir=$(srcdir) --includedir=.
+INTROSPECTION_GIRS += Gck-@GCK_MAJOR@.gir
Gck-@GCK_MAJOR@.gir: libgck-@GCK_MAJOR@.la
@@ -135,45 +128,30 @@ Gck_@GCK_MAJOR@_gir_PACKAGES = gobject-2.0 gio-2.0 p11-kit-1
Gck_@GCK_MAJOR@_gir_EXPORT_PACKAGES = gck-@GCK_MAJOR@
Gck_@GCK_MAJOR@_gir_INCLUDES = GObject-2.0 Gio-2.0
Gck_@GCK_MAJOR@_gir_LIBS = libgck-@GCK_MAJOR@.la
-Gck_@GCK_MAJOR@_gir_CFLAGS = -I$(top_srcdir) -I$(top_builddir) -DGCK_COMPILATION -DGCK_API_SUBJECT_TO_CHANGE
-Gck_@GCK_MAJOR@_gir_FILES = $(PUBLIC_FILES)
-Gck_@GCK_MAJOR@_gir_SCANNERFLAGS = --c-include "gck/gck.h"
+Gck_@GCK_MAJOR@_gir_CFLAGS = -I$(srcdir) -I$(builddir) -DGCK_COMPILATION -DGCK_API_SUBJECT_TO_CHANGE
+Gck_@GCK_MAJOR@_gir_FILES = $(gck_PUBLIC_FILES)
+Gck_@GCK_MAJOR@_gir_SCANNERFLAGS = --add-include-path=$(srcdir)/gck --c-include "gck/gck.h"
-girdir = $(datadir)/gir-1.0
-gir_DATA = $(INTROSPECTION_GIRS)
-
-typelibsdir = $(libdir)/girepository-1.0
-typelibs_DATA = $(INTROSPECTION_GIRS:.gir=.typelib)
+gir_DATA += Gck-@GCK_MAJOR@.gir
if ENABLE_VAPIGEN
-include $(VAPIGEN_MAKEFILE)
-gck-@GCK_MAJOR@.vapi: Gck-@GCK_MAJOR@.gir Gck-@GCK_MAJOR@.metadata gck-@GCK_MAJOR@.deps
+gck-@GCK_MAJOR@.vapi: Gck-@GCK_MAJOR@.gir gck/Gck-@GCK_MAJOR@.metadata gck-@GCK_MAJOR@.deps
-VAPIGEN_VAPIS = gck-@GCK_MAJOR@.vapi
+VAPIGEN_VAPIS += gck-@GCK_MAJOR@.vapi
gck_@GCK_MAJOR@_vapi_DEPS = glib-2.0 gio-2.0
gck_@GCK_MAJOR@_vapi_METADATADIRS = $(srcdir)
gck_@GCK_MAJOR@_vapi_FILES = Gck-@GCK_MAJOR@.gir
-VAPI_DEPS = $(VAPIGEN_VAPIS:.vapi=.deps)
-
gck-$(GCK_MAJOR).deps: Makefile.am
$(AM_V_GEN) echo $(gck_@GCK_MAJOR@_vapi_DEPS) | tr ' ' '\n' > $@
-vapidir = $(datadir)/vala/vapi
-vapi_DATA = \
- pkcs11.vapi \
- $(VAPIGEN_VAPIS) \
- $(VAPI_DEPS)
+vapi_DATA += gck/pkcs11.vapi
EXTRA_DIST += \
- Gck-@GCK_MAJOR@.metadata \
- pkcs11.vapi
-
-CLEANFILES += \
- $(VAPIGEN_VAPIS) \
- $(VAPI_DEPS)
+ gck/Gck-@GCK_MAJOR@.metadata \
+ gck/pkcs11.vapi
endif # ENABLE_VAPIGEN
@@ -181,24 +159,103 @@ endif
# ----------------------------------------------------------------
-pkgconfig_DATA = gck-$(GCK_MAJOR).pc
+pkgconfig_DATA += gck-$(GCK_MAJOR).pc
-gck-$(GCK_MAJOR).pc: gck.pc
- $(AM_V_GEN) cp gck.pc gck-$(GCK_MAJOR).pc
+gck-$(GCK_MAJOR).pc: gck/gck.pc
+ $(AM_V_GEN) cp gck/gck.pc gck-$(GCK_MAJOR).pc
-gck-expected.abi: gck.symbols
+gck-expected.abi: gck/gck.symbols
$(AM_V_GEN) cpp -P $< | sort > $@
gck-actual.abi: $(builddir)/.libs/libgck-@GCK_MAJOR@.so
$(AM_V_GEN) $(NM) -D -g --defined-only $< | \
cut -d ' ' -f 3 | grep -Ev '^(__bss_start|_edata|_end)' | sort > $@
-check-symbols: gck-expected.abi gck-actual.abi
+check-gck-symbols: gck-expected.abi gck-actual.abi
$(AM_V_GEN) diff -U0 --ignore-blank-lines gck-expected.abi gck-actual.abi || \
(echo "check-symbols: Symbols have CHANGED. Fix gck.symbols"; exit 1)
-check-local: check-symbols
+gck_CFLAGS = \
+ -I$(top_builddir) \
+ -I$(top_srcdir) \
+ -DGCK_API_SUBJECT_TO_CHANGE \
+ -DG_LOG_DOMAIN=\"Gck\" \
+ $(P11_KIT_CFLAGS) \
+ $(GLIB_CFLAGS)
+
+gck_LIBS = \
+ libgck-testable.la \
+ libegg-test.la \
+ libegg-hex.la \
+ $(GLIB_LIBS) \
+ $(P11_KIT_LIBS) \
+ $(GIO_LIBS)
+
+gck_TESTS = \
+ test-gck-attributes \
+ test-gck-module \
+ test-gck-slot \
+ test-gck-session \
+ test-gck-object \
+ test-gck-crypto \
+ test-gck-uri \
+ test-gck-enumerator \
+ test-gck-modules
+
+test_gck_attributes_SOURCES = gck/test-gck-attributes.c
+test_gck_attributes_CFLAGS = $(gck_CFLAGS)
+test_gck_attributes_LDADD = $(gck_LIBS)
+
+test_gck_crypto_SOURCES = gck/test-gck-crypto.c
+test_gck_crypto_CFLAGS = $(gck_CFLAGS)
+test_gck_crypto_LDADD = $(gck_LIBS)
+
+test_gck_enumerator_SOURCES = \
+ gck/test-gck-enumerator.c \
+ gck/mock-interaction.c gck/mock-interaction.h
+test_gck_enumerator_CFLAGS = $(gck_CFLAGS)
+test_gck_enumerator_LDADD = $(gck_LIBS)
+
+test_gck_object_SOURCES = gck/test-gck-object.c
+test_gck_object_CFLAGS = $(gck_CFLAGS)
+test_gck_object_LDADD = $(gck_LIBS)
+
+test_gck_module_SOURCES = gck/test-gck-module.c
+test_gck_module_CFLAGS = $(gck_CFLAGS)
+test_gck_module_LDADD = $(gck_LIBS)
+
+test_gck_modules_SOURCES = gck/test-gck-modules.c
+test_gck_modules_CFLAGS = $(gck_CFLAGS)
+test_gck_modules_LDADD = $(gck_LIBS)
+
+test_gck_session_SOURCES = \
+ gck/test-gck-session.c \
+ gck/mock-interaction.c gck/mock-interaction.h
+test_gck_session_CFLAGS = $(gck_CFLAGS)
+test_gck_session_LDADD = $(gck_LIBS)
+
+test_gck_slot_SOURCES = gck/test-gck-slot.c
+test_gck_slot_CFLAGS = $(gck_CFLAGS)
+test_gck_slot_LDADD = $(gck_LIBS)
+
+test_gck_uri_SOURCES = gck/test-gck-uri.c
+test_gck_uri_CFLAGS = $(gck_CFLAGS)
+test_gck_uri_LDADD = $(gck_LIBS)
+
+check_PROGRAMS += $(gck_TESTS)
+TESTS += $(gck_TESTS)
+
+check_LTLIBRARIES += libmock-test-module.la
+
+libmock_test_module_la_LDFLAGS = \
+ -module -avoid-version -shared -rpath $(abs_builddir)
+
+libmock_test_module_la_CFLAGS = \
+ -DGCK_API_SUBJECT_TO_CHANGE \
+ $(gck_CFLAGS)
-check-memory:
- make -C tests check-memory
+libmock_test_module_la_SOURCES = \
+ gck/mock-test-module.c
+libmock_test_module_la_LIBADD = \
+ libgck-testable.la
diff --git a/gck/gck-module.c b/gck/gck-module.c
index 257e88b..71c2832 100644
--- a/gck/gck-module.c
+++ b/gck/gck-module.c
@@ -24,7 +24,8 @@
#include "gck.h"
#include "gck-private.h"
-#include "gck-marshal.h"
+
+#include "gck/gck-marshal.h"
#include <glib/gi18n-lib.h>
diff --git a/gck/gck-modules.c b/gck/gck-modules.c
index 64ee63d..9b59ba8 100644
--- a/gck/gck-modules.c
+++ b/gck/gck-modules.c
@@ -24,7 +24,8 @@
#include "gck.h"
#include "gck-private.h"
-#include "gck-marshal.h"
+
+#include "gck/gck-marshal.h"
#include <glib/gi18n-lib.h>
diff --git a/gck/gck-session.c b/gck/gck-session.c
index 5df0020..7e635c3 100644
--- a/gck/gck-session.c
+++ b/gck/gck-session.c
@@ -25,9 +25,10 @@
#include "gck.h"
#define DEBUG_FLAG GCK_DEBUG_SESSION
#include "gck-debug.h"
-#include "gck-marshal.h"
#include "gck-private.h"
+#include "gck/gck-marshal.h"
+
#include <string.h>
#include <glib/gi18n-lib.h>
diff --git a/gck/gck-uri.c b/gck/gck-uri.c
index 6ab71b7..29caeba 100644
--- a/gck/gck-uri.c
+++ b/gck/gck-uri.c
@@ -24,7 +24,8 @@
#include "gck.h"
#include "gck-private.h"
-#include "gck-marshal.h"
+
+#include "gck/gck-marshal.h"
#include <glib/gi18n-lib.h>
diff --git a/gck/tests/mock-interaction.c b/gck/mock-interaction.c
index c431454..c431454 100644
--- a/gck/tests/mock-interaction.c
+++ b/gck/mock-interaction.c
diff --git a/gck/tests/mock-interaction.h b/gck/mock-interaction.h
index 5053cd2..5053cd2 100644
--- a/gck/tests/mock-interaction.h
+++ b/gck/mock-interaction.h
diff --git a/gck/tests/mock-test-module.c b/gck/mock-test-module.c
index 7d6ba2c..7d6ba2c 100644
--- a/gck/tests/mock-test-module.c
+++ b/gck/mock-test-module.c
diff --git a/gck/tests/test-gck-attributes.c b/gck/test-gck-attributes.c
index 0cfd95e..0cfd95e 100644
--- a/gck/tests/test-gck-attributes.c
+++ b/gck/test-gck-attributes.c
diff --git a/gck/tests/test-gck-crypto.c b/gck/test-gck-crypto.c
index f2bd7f9..f2bd7f9 100644
--- a/gck/tests/test-gck-crypto.c
+++ b/gck/test-gck-crypto.c
diff --git a/gck/tests/test-gck-enumerator.c b/gck/test-gck-enumerator.c
index 9d01c4c..9d01c4c 100644
--- a/gck/tests/test-gck-enumerator.c
+++ b/gck/test-gck-enumerator.c
diff --git a/gck/tests/test-gck-module.c b/gck/test-gck-module.c
index 068423f..068423f 100644
--- a/gck/tests/test-gck-module.c
+++ b/gck/test-gck-module.c
diff --git a/gck/tests/test-gck-modules.c b/gck/test-gck-modules.c
index 4307408..4307408 100644
--- a/gck/tests/test-gck-modules.c
+++ b/gck/test-gck-modules.c
diff --git a/gck/tests/test-gck-object.c b/gck/test-gck-object.c
index 9622bb2..9622bb2 100644
--- a/gck/tests/test-gck-object.c
+++ b/gck/test-gck-object.c
diff --git a/gck/tests/test-gck-session.c b/gck/test-gck-session.c
index 19c3361..19c3361 100644
--- a/gck/tests/test-gck-session.c
+++ b/gck/test-gck-session.c
diff --git a/gck/tests/test-gck-slot.c b/gck/test-gck-slot.c
index 4661d49..4661d49 100644
--- a/gck/tests/test-gck-slot.c
+++ b/gck/test-gck-slot.c
diff --git a/gck/tests/test-gck-uri.c b/gck/test-gck-uri.c
index 39ef9f1..39ef9f1 100644
--- a/gck/tests/test-gck-uri.c
+++ b/gck/test-gck-uri.c
diff --git a/gck/tests/Makefile.am b/gck/tests/Makefile.am
deleted file mode 100644
index 60da135..0000000
--- a/gck/tests/Makefile.am
+++ /dev/null
@@ -1,67 +0,0 @@
-include $(top_srcdir)/Makefile.decl
-
-AM_CPPFLAGS = \
- -I$(top_builddir) \
- -I$(top_srcdir) \
- -DSRCDIR="\"@abs_srcdir@\"" \
- -DBUILDDIR="\"@abs_builddir@\"" \
- -DGCK_API_SUBJECT_TO_CHANGE \
- -DG_LOG_DOMAIN=\"Gck\" \
- $(P11_KIT_CFLAGS) \
- $(GLIB_CFLAGS)
-
-LDADD = \
- $(top_builddir)/gck/libgck-testable.la \
- $(top_builddir)/egg/libegg-test.la \
- $(top_builddir)/egg/libegg-hex.la \
- $(GTHREAD_LIBS) \
- $(GLIB_LIBS) \
- $(P11_KIT_LIBS) \
- $(GIO_LIBS)
-
-TEST_PROGS = \
- test-gck-attributes \
- test-gck-module \
- test-gck-slot \
- test-gck-session \
- test-gck-object \
- test-gck-crypto \
- test-gck-uri \
- test-gck-enumerator \
- test-gck-modules
-
-test_gck_enumerator_SOURCES = \
- test-gck-enumerator.c \
- mock-interaction.c mock-interaction.h
-
-test_gck_session_SOURCES = \
- test-gck-session.c \
- mock-interaction.c mock-interaction.h
-
-check_PROGRAMS = $(TEST_PROGS)
-
-test: $(TEST_PROGS)
- gtester --verbose -m $(TEST_MODE) --g-fatal-warnings $(TEST_PROGS)
-
-check-local: test
-
-check-memory: perform-memcheck
-
-all-local: $(check_PROGRAMS) $(check_LTLIBRARIES)
-
-check_LTLIBRARIES = libmock-test-module.la
-
-libmock_test_module_la_LDFLAGS = \
- -module -avoid-version -shared -rpath $(abs_builddir)
-
-libmock_test_module_la_CFLAGS = \
- -I$(top_srcdir)/gck \
- -I$(top_srcdir) \
- $(GLIB_CFLAGS) \
- -DGCK_API_SUBJECT_TO_CHANGE
-
-libmock_test_module_la_SOURCES = \
- mock-test-module.c
-
-libmock_test_module_la_LIBADD = \
- $(top_builddir)/gck/libgck-testable.la
diff --git a/gcr/Makefile.am b/gcr/Makefile.am
index e88f8ec..d3469d7 100644
--- a/gcr/Makefile.am
+++ b/gcr/Makefile.am
@@ -1,140 +1,128 @@
-include $(top_srcdir)/Makefile.decl
-
-SUBDIRS = . tests
-
-incdir = $(includedir)/gcr-@GCR_MAJOR@/gcr
-
-AM_CPPFLAGS = \
- -I$(top_builddir) \
- -I$(top_srcdir) \
- $(GLIB_CFLAGS) \
- $(LIBGCRYPT_CFLAGS) \
- $(P11_KIT_CFLAGS) \
- -DG_LOG_DOMAIN=\"Gcr\" \
- -DGCR_API_SUBJECT_TO_CHANGE \
- -DLOCALEDIR=\""$(datadir)/locale"\"
-
-check-local: check-symbols
-
-check-memory:
- make -C tests check-memory
-
-HEADER_FILES = \
- gcr-base.h \
- gcr-certificate.h \
- gcr-certificate-chain.h \
- gcr-certificate-request.h \
- gcr-collection.h \
- gcr-column.h \
- gcr-comparable.h \
- gcr-deprecated-base.h \
- gcr-fingerprint.h \
- gcr-filter-collection.h \
- gcr-icons.h \
- gcr-importer.h \
- gcr-import-interaction.h \
- gcr-library.h \
- gcr-mock-prompter.h \
- gcr-parser.h \
- gcr-pkcs11-certificate.h \
- gcr-prompt.h \
- gcr-secret-exchange.h \
- gcr-secure-memory.h \
- gcr-simple-certificate.h \
- gcr-simple-collection.h \
- gcr-system-prompt.h \
- gcr-system-prompter.h \
- gcr-trust.h \
- gcr-types.h \
- gcr-union-collection.h \
- gcr-unlock-options.h \
- gcr-version.h
-
-inc_HEADERS = \
- $(HEADER_FILES) \
- gcr-enum-types-base.h
+# included in top-level Makefile.am
+
+gcr_incdir = $(includedir)/gcr-@GCR_MAJOR@/gcr
+
+gcr_HEADER_FILES = \
+ gcr/gcr-base.h \
+ gcr/gcr-certificate.h \
+ gcr/gcr-certificate-chain.h \
+ gcr/gcr-certificate-request.h \
+ gcr/gcr-collection.h \
+ gcr/gcr-column.h \
+ gcr/gcr-comparable.h \
+ gcr/gcr-deprecated-base.h \
+ gcr/gcr-fingerprint.h \
+ gcr/gcr-filter-collection.h \
+ gcr/gcr-icons.h \
+ gcr/gcr-importer.h \
+ gcr/gcr-import-interaction.h \
+ gcr/gcr-library.h \
+ gcr/gcr-mock-prompter.h \
+ gcr/gcr-parser.h \
+ gcr/gcr-pkcs11-certificate.h \
+ gcr/gcr-prompt.h \
+ gcr/gcr-secret-exchange.h \
+ gcr/gcr-secure-memory.h \
+ gcr/gcr-simple-certificate.h \
+ gcr/gcr-simple-collection.h \
+ gcr/gcr-system-prompt.h \
+ gcr/gcr-system-prompter.h \
+ gcr/gcr-trust.h \
+ gcr/gcr-types.h \
+ gcr/gcr-union-collection.h \
+ gcr/gcr-unlock-options.h \
+ gcr/gcr-version.h
+
+gcr_inc_HEADERS = \
+ $(gcr/HEADER_FILES) \
+ gcr/gcr-enum-types-base.h
if WITH_GTK
-inc_HEADERS += gcr.h
+gcr_inc_HEADERS += gcr/gcr.h
endif
-lib_LTLIBRARIES = \
+lib_LTLIBRARIES += \
libgcr-base-@GCR_MAJOR@.la
-BUILT_SOURCES = \
- gcr-marshal.c gcr-marshal.h \
- gcr-enum-types-base.c gcr-enum-types-base.h \
- gcr-oids.c gcr-oids.h \
- gcr-dbus-generated.c gcr-dbus-generated.h
-
-PUBLIC_FILES = \
- gcr-base.h \
- gcr-certificate.c gcr-certificate.h \
- gcr-certificate-chain.c gcr-certificate-chain.h \
- gcr-certificate-request.c gcr-certificate-request.h \
- gcr-collection.c gcr-collection.h \
- gcr-column.h \
- gcr-comparable.c gcr-comparable.h \
- gcr-filter-collection.c gcr-filter-collection.h \
- gcr-fingerprint.c gcr-fingerprint.h \
- gcr-icons.c gcr-icons.h \
- gcr-importer.c gcr-importer.h \
- gcr-import-interaction.c gcr-import-interaction.h \
- gcr-library.c gcr-library.h \
- gcr-mock-prompter.c gcr-mock-prompter.h \
- gcr-parser.c gcr-parser.h \
- gcr-pkcs11-certificate.c gcr-pkcs11-certificate.h \
- gcr-prompt.c gcr-prompt.h \
- gcr-secret-exchange.c gcr-secret-exchange.h \
- gcr-secure-memory.c gcr-secure-memory.h \
- gcr-simple-certificate.c gcr-simple-certificate.h \
- gcr-simple-collection.c gcr-simple-collection.h \
- gcr-system-prompt.c gcr-system-prompt.h \
- gcr-system-prompter.c gcr-system-prompter.h \
- gcr-types.h \
- gcr-union-collection.c gcr-union-collection.h \
- gcr-unlock-options.h \
- gcr-version.h \
+gcr_BUILT_SOURCES = \
+ gcr/gcr-marshal.c gcr/gcr-marshal.h \
+ gcr/gcr-enum-types-base.c gcr/gcr-enum-types-base.h \
+ gcr/gcr-oids.c gcr/gcr-oids.h \
+ gcr/gcr-dbus-generated.c gcr/gcr-dbus-generated.h
+
+BUILT_SOURCES += $(gcr_BUILT_SOURCES)
+
+gcr_PUBLIC_FILES = \
+ gcr/gcr-base.h \
+ gcr/gcr-certificate.c gcr/gcr-certificate.h \
+ gcr/gcr-certificate-chain.c gcr/gcr-certificate-chain.h \
+ gcr/gcr-certificate-request.c gcr/gcr-certificate-request.h \
+ gcr/gcr-collection.c gcr/gcr-collection.h \
+ gcr/gcr-column.h \
+ gcr/gcr-comparable.c gcr/gcr-comparable.h \
+ gcr/gcr-filter-collection.c gcr/gcr-filter-collection.h \
+ gcr/gcr-fingerprint.c gcr/gcr-fingerprint.h \
+ gcr/gcr-icons.c gcr/gcr-icons.h \
+ gcr/gcr-importer.c gcr/gcr-importer.h \
+ gcr/gcr-import-interaction.c gcr/gcr-import-interaction.h \
+ gcr/gcr-library.c gcr/gcr-library.h \
+ gcr/gcr-mock-prompter.c gcr/gcr-mock-prompter.h \
+ gcr/gcr-parser.c gcr/gcr-parser.h \
+ gcr/gcr-pkcs11-certificate.c gcr/gcr-pkcs11-certificate.h \
+ gcr/gcr-prompt.c gcr/gcr-prompt.h \
+ gcr/gcr-secret-exchange.c gcr/gcr-secret-exchange.h \
+ gcr/gcr-secure-memory.c gcr/gcr-secure-memory.h \
+ gcr/gcr-simple-certificate.c gcr/gcr-simple-certificate.h \
+ gcr/gcr-simple-collection.c gcr/gcr-simple-collection.h \
+ gcr/gcr-system-prompt.c gcr/gcr-system-prompt.h \
+ gcr/gcr-system-prompter.c gcr/gcr-system-prompter.h \
+ gcr/gcr-types.h \
+ gcr/gcr-union-collection.c gcr/gcr-union-collection.h \
+ gcr/gcr-unlock-options.h \
+ gcr/gcr-version.h \
$(NULL)
-PRIVATE_FILES = \
- gcr-callback-output-stream.c gcr-callback-output-stream.h \
- gcr-certificate-extensions.c gcr-certificate-extensions.h \
- gcr-column.c \
- gcr-dbus-constants.h \
- gcr-debug.c gcr-debug.h \
- gcr-deprecated-base.h \
- gcr-gnupg-collection.c gcr-gnupg-collection.h \
- gcr-gnupg-importer.c gcr-gnupg-importer.h \
- gcr-gnupg-key.c gcr-gnupg-key.h \
- gcr-gnupg-process.c gcr-gnupg-process.h \
- gcr-gnupg-records.c gcr-gnupg-records.h \
- gcr-gnupg-util.c gcr-gnupg-util.h \
- gcr-internal.h \
- gcr-key-mechanisms.h gcr-key-mechanisms.c \
- gcr-memory-icon.c gcr-memory-icon.h \
- gcr-openpgp.c gcr-openpgp.h \
- gcr-openssh.c gcr-openssh.h \
- gcr-pkcs11-importer.c gcr-pkcs11-importer.h \
- gcr-record.c gcr-record.h \
- gcr-single-collection.c gcr-single-collection.h \
- gcr-subject-public-key.c gcr-subject-public-key.h \
- gcr-trust.c gcr-trust.h \
- gcr-util.c gcr-util.h \
+gcr_PRIVATE_FILES = \
+ gcr/gcr-callback-output-stream.c gcr/gcr-callback-output-stream.h \
+ gcr/gcr-certificate-extensions.c gcr/gcr-certificate-extensions.h \
+ gcr/gcr-column.c \
+ gcr/gcr-dbus-constants.h \
+ gcr/gcr-debug.c gcr/gcr-debug.h \
+ gcr/gcr-deprecated-base.h \
+ gcr/gcr-gnupg-collection.c gcr/gcr-gnupg-collection.h \
+ gcr/gcr-gnupg-importer.c gcr/gcr-gnupg-importer.h \
+ gcr/gcr-gnupg-key.c gcr/gcr-gnupg-key.h \
+ gcr/gcr-gnupg-process.c gcr/gcr-gnupg-process.h \
+ gcr/gcr-gnupg-records.c gcr/gcr-gnupg-records.h \
+ gcr/gcr-gnupg-util.c gcr/gcr-gnupg-util.h \
+ gcr/gcr-internal.h \
+ gcr/gcr-key-mechanisms.h gcr/gcr-key-mechanisms.c \
+ gcr/gcr-memory-icon.c gcr/gcr-memory-icon.h \
+ gcr/gcr-openpgp.c gcr/gcr-openpgp.h \
+ gcr/gcr-openssh.c gcr/gcr-openssh.h \
+ gcr/gcr-pkcs11-importer.c gcr/gcr-pkcs11-importer.h \
+ gcr/gcr-record.c gcr/gcr-record.h \
+ gcr/gcr-single-collection.c gcr/gcr-single-collection.h \
+ gcr/gcr-subject-public-key.c gcr/gcr-subject-public-key.h \
+ gcr/gcr-trust.c gcr/gcr-trust.h \
+ gcr/gcr-util.c gcr/gcr-util.h \
$(NULL)
libgcr_base_@GCR_MAJOR@_la_SOURCES = \
- $(PUBLIC_FILES) \
- $(PRIVATE_FILES) \
+ $(gcr_PUBLIC_FILES) \
+ $(gcr_PRIVATE_FILES) \
$(NULL)
nodist_libgcr_base_@GCR_MAJOR@_la_SOURCES = \
- $(BUILT_SOURCES)
+ $(gcr_BUILT_SOURCES)
libgcr_base_@GCR_MAJOR@_la_CFLAGS = \
+ $(LIBGCRYPT_CFLAGS) \
+ $(P11_KIT_CFLAGS) \
-DGCK_API_SUBJECT_TO_CHANGE \
-DP11_KIT_API_SUBJECT_TO_CHANGE \
- -DGCR_COMPILATION
+ -DGCR_COMPILATION \
+ -DG_LOG_DOMAIN=\"Gcr\"
libgcr_base_@GCR_MAJOR@_la_LDFLAGS = \
-version-info $(GCR_LT_RELEASE) \
@@ -142,86 +130,70 @@ libgcr_base_@GCR_MAJOR@_la_LDFLAGS = \
-export-symbols-regex '^_gcr_.*|^gcr_.*|^SECMEM_.*'
libgcr_base_@GCR_MAJOR@_la_LIBADD = \
- $(top_builddir)/egg/libegg.la \
- $(top_builddir)/gck/libgck-@GCK_MAJOR@.la \
+ libegg.la \
+ libgck-@GCK_MAJOR@.la \
$(GLIB_LIBS) \
$(LIBGCRYPT_LIBS) \
$(P11_KIT_LIBS)
-gcr-marshal.h: gcr-marshal.list $(GLIB_GENMARSHAL)
+gcr/gcr-marshal.h: gcr/gcr-marshal.list $(GLIB_GENMARSHAL)
$(AM_V_GEN) $(GLIB_GENMARSHAL) $< --header --prefix=_gcr_marshal > $@
-gcr-marshal.c: gcr-marshal.list $(GLIB_GENMARSHAL)
- $(AM_V_GEN) ( echo "#include \"gcr-marshal.h\"" > $@ && \
+gcr/gcr-marshal.c: gcr/gcr-marshal.list $(GLIB_GENMARSHAL)
+ $(AM_V_GEN) ( echo "#include \"gcr/gcr-marshal.h\"" > $@ && \
$(GLIB_GENMARSHAL) $< --body --prefix=_gcr_marshal >> $@ )
-gcr-enum-types-base.h: $(ENUM_TEMPLATE_H) $(HEADER_FILES)
+gcr/gcr-enum-types-base.h: $(ENUM_TEMPLATE_H) $(gcr_HEADER_FILES)
$(AM_V_GEN) $(GLIB_MKENUMS) --template $^ > $@
-gcr-enum-types-base.c: $(ENUM_TEMPLATE_C) $(HEADER_FILES)
+gcr/gcr-enum-types-base.c: $(ENUM_TEMPLATE_C) $(gcr_HEADER_FILES)
$(AM_V_GEN) $(GLIB_MKENUMS) --template $^ > $@
-# $(AM_V_GEN)
-
-gcr-oids.c: gcr-oids.list gcr-mkoids
- $(AM_V_GEN) sh $(srcdir)/gcr-mkoids -p GCR -c gcr-oids.c -h gcr-oids.h $(srcdir)/gcr-oids.list
+gcr/gcr-oids.c: gcr/gcr-oids.list gcr/gcr-mkoids
+ $(AM_V_GEN) sh $(srcdir)/gcr/gcr-mkoids -p GCR -c gcr/gcr-oids.c -h gcr/gcr-oids.h $(srcdir)/gcr/gcr-oids.list
-gcr-oids.h: gcr-oids.c
+gcr/gcr-oids.h: gcr/gcr-oids.c
DBUS_XML_DEFINITIONS = \
- org.gnome.keyring.Prompter.xml
+ gcr/org.gnome.keyring.Prompter.xml
-gcr-dbus-generated.c: $(DBUS_XML_DEFINITIONS)
+gcr/gcr-dbus-generated.c: $(DBUS_XML_DEFINITIONS)
$(AM_V_GEN) gdbus-codegen --interface-prefix org.gnome.keyring.internal. \
- --generate-c-code gcr-dbus-generated --c-namespace GcrDBus $^
- $(AM_V_GEN) sed -i -e 's/gcr_dbus/_gcr_dbus/g' gcr-dbus-generated.[ch]
+ --generate-c-code gcr/gcr-dbus-generated --c-namespace GcrDBus $^
+ $(AM_V_GEN) sed -i -e 's/gcr_dbus/_gcr_dbus/g' gcr/gcr-dbus-generated.[ch]
-gcr-dbus-generated.h: gcr-dbus-generated.c
+gcr/gcr-dbus-generated.h: gcr/gcr-dbus-generated.c
-pkgconfig_DATA = \
+pkgconfig_DATA += \
gcr-base-$(GCR_MAJOR).pc
-gcr-base-$(GCR_MAJOR).pc: gcr-base.pc
- $(AM_V_GEN) cp gcr-base.pc gcr-base-$(GCR_MAJOR).pc
+gcr-base-$(GCR_MAJOR).pc: gcr/gcr-base.pc
+ $(AM_V_GEN) cp gcr/gcr-base.pc gcr-base-$(GCR_MAJOR).pc
service_in_files = \
- org.gnome.keyring.SystemPrompter.service.in \
- org.gnome.keyring.PrivatePrompter.service.in
+ gcr/org.gnome.keyring.SystemPrompter.service.in \
+ gcr/org.gnome.keyring.PrivatePrompter.service.in
servicedir = $(DBUS_SERVICES_DIR)
service_DATA = $(service_in_files:.service.in=.service)
-EXTRA_DIST = \
- gcr-base.pc.in \
- gcr-marshal.list \
- gcr-oids.list \
- gcr-mkoids \
+EXTRA_DIST += \
+ gcr/gcr-base.pc.in \
+ gcr/gcr-marshal.list \
+ gcr/gcr-oids.list \
+ gcr/gcr-mkoids \
$(DBUS_XML_DEFINITIONS) \
- gcr-base.symbols \
+ gcr/gcr-base.symbols \
$(service_in_files) \
- gcr-version.h.in
+ gcr/gcr-version.h.in
-CLEANFILES = \
- $(BUILT_SOURCES) \
- $(pkgconfig_DATA) \
+CLEANFILES += \
$(service_DATA) \
- $(desktop_in_files) \
- $(gir_DATA) \
- $(typelibs_DATA) \
gcr-base-actual.abi \
- gcr-base-expected.abi
+ gcr-base-expected.abi \
+ Gcr-3.broken.gir
if HAVE_INTROSPECTION
-include $(INTROSPECTION_MAKEFILE)
-
-INTROSPECTION_GIRS = Gcr-@GCR_MAJOR@.broken.gir
-INTROSPECTION_SCANNER_ARGS = \
- $(INTROSPECTION_FLAGS) \
- --warn-all \
- --add-include-path=$(top_builddir)/gck \
- --include-uninstalled=$(top_builddir)/gck/Gck-@GCK_MAJOR@.gir
-INTROSPECTION_COMPILER_ARGS = \
- --includedir=$(srcdir) \
- --includedir=$(top_builddir)/gck
+INTROSPECTION_GIRS += Gcr-@GCR_MAJOR@.broken.gir
Gcr-@GCR_MAJOR@.gir: Gcr-@GCR_MAJOR@.broken.gir $(FIX_GIR)
@@ -233,23 +205,20 @@ Gcr_@GCR_MAJOR@_broken_gir_INCLUDES = GLib-2.0 GObject-2.0
Gcr_@GCR_MAJOR@_broken_gir_LIBS = libgcr-base-@GCR_MAJOR@.la
Gcr_@GCR_MAJOR@_broken_gir_CFLAGS = -I$(top_srcdir) -I$(top_builddir) \
-DGCR_COMPILATION -DGCR_API_SUBJECT_TO_CHANGE
-Gcr_@GCR_MAJOR@_broken_gir_FILES = $(PUBLIC_FILES)
-Gcr_@GCR_MAJOR@_broken_gir_SCANNERFLAGS = --c-include "gcr/gcr-base.h" \
+Gcr_@GCR_MAJOR@_broken_gir_FILES = $(gcr_PUBLIC_FILES)
+Gcr_@GCR_MAJOR@_broken_gir_SCANNERFLAGS = \
+ --add-include-path=$(top_builddir)/gck \
+ --include-uninstalled=$(builddir)/Gck-@GCK_MAJOR@.gir \
+ --c-include "gcr/gcr-base.h" \
--identifier-prefix Gcr
-girdir = $(datadir)/gir-1.0
-gir_DATA = Gcr-@GCR_MAJOR@.gir
-
-typelibsdir = $(libdir)/girepository-1.0
-typelibs_DATA = $(gir_DATA:.gir=.typelib)
+gir_DATA += Gcr-@GCR_MAJOR@.gir
if ENABLE_VAPIGEN
-include $(VAPIGEN_MAKEFILE)
-
-gcr-@GCR_MAJOR@.vapi: Gcr-@GCR_MAJOR@.gir Gcr-@GCR_MAJOR@.metadata gcr-@GCR_MAJOR@.deps
+gcr-@GCR_MAJOR@.vapi: Gcr-@GCR_MAJOR@.gir gcr/Gcr-@GCR_MAJOR@.metadata gcr-@GCR_MAJOR@.deps
-VAPIGEN_VAPIS = gcr-@GCR_MAJOR@.vapi
+VAPIGEN_VAPIS += gcr-@GCR_MAJOR@.vapi
gcr_@GCR_MAJOR@_vapi_DEPS = glib-2.0 gio-2.0 gck-@GCK_MAJOR@
gcr_@GCR_MAJOR@_vapi_METADATADIRS = $(srcdir)
@@ -257,22 +226,11 @@ gcr_@GCR_MAJOR@_vapi_VAPIDIRS = $(builddir)/../gck
gcr_@GCR_MAJOR@_vapi_GIRDIRS = $(builddir)/../gck
gcr_@GCR_MAJOR@_vapi_FILES = Gcr-@GCR_MAJOR@.gir
-VAPI_DEPS = $(VAPIGEN_VAPIS:.vapi=.deps)
-
gcr-$(GCR_MAJOR).deps: Makefile.am
$(AM_V_GEN) echo $(gcr_@GCR_MAJOR@_vapi_DEPS) | tr ' ' '\n' > $@
-vapidir = $(datadir)/vala/vapi
-vapi_DATA = \
- $(VAPIGEN_VAPIS) \
- $(VAPI_DEPS)
-
EXTRA_DIST += \
- Gcr-@GCR_MAJOR@.metadata
-
-CLEANFILES += \
- $(VAPIGEN_VAPIS) \
- $(VAPI_DEPS)
+ gcr/Gcr-@GCR_MAJOR@.metadata
endif # ENABLE_VAPIGEN
@@ -280,13 +238,161 @@ endif # HAVE_INTROSPECTON
# ----------------------------------------------------------------
-gcr-base-expected.abi: gcr-base.symbols
+gcr-base-expected.abi: gcr/gcr-base.symbols
$(AM_V_GEN) cpp -P $< | sort > $@
gcr-base-actual.abi: $(builddir)/.libs/libgcr-base-@GCR_MAJOR@.so
$(AM_V_GEN) $(NM) -D -g --defined-only $< | \
cut -d ' ' -f 3 | grep -Ev '^(__bss_start|_edata|_end|_gcr_)' | sort > $@
-check-symbols: gcr-base-expected.abi gcr-base-actual.abi
+check-gcr-symbols: gcr-base-expected.abi gcr-base-actual.abi
$(AM_V_GEN) diff -U0 --ignore-blank-lines gcr-base-expected.abi gcr-base-actual.abi || \
(echo "check-symbols: Symbols have CHANGED. Fix gcr-base.symbols"; exit 1)
+
+gcr_CFLAGS = \
+ -I$(top_builddir) \
+ -I$(top_srcdir) \
+ -DSRCDIR="\"@abs_srcdir@\"" \
+ -DGCR_API_SUBJECT_TO_CHANGE \
+ -DGCK_API_SUBJECT_TO_CHANGE \
+ -DGCR_COMPILATION \
+ $(GLIB_CFLAGS) \
+ $(LIBGCRYPT_CFLAGS) \
+ $(P11_KIT_CFLAGS)
+
+gcr_LIBS = \
+ libgcr-base-@GCR_MAJOR@.la \
+ libegg.la \
+ libgck-testable.la \
+ $(GLIB_LIBS) \
+ $(LIBGCRYPT_LIBS) \
+ $(P11_KIT_LIBS)
+
+gcr_TESTS = \
+ test-util \
+ test-filter-collection \
+ test-secret-exchange \
+ test-simple-certificate \
+ test-certificate \
+ test-certificate-chain \
+ test-subject-public-key \
+ test-fingerprint \
+ test-pkcs11-certificate \
+ test-openpgp \
+ test-openssh \
+ test-secure-memory \
+ test-trust \
+ test-parser \
+ test-record \
+ test-memory-icon \
+ test-gnupg-key \
+ test-gnupg-collection \
+ test-gnupg-process \
+ test-system-prompt
+
+test_certificate_SOURCES = gcr/test-certificate.c
+test_certificate_CFLAGS = $(gcr_CFLAGS)
+test_certificate_LDADD = $(gcr_LIBS)
+
+test_certificate_chain_SOURCES = gcr/test-certificate-chain.c
+test_certificate_chain_CFLAGS = $(gcr_CFLAGS)
+test_certificate_chain_LDADD = $(gcr_LIBS)
+
+test_filter_collection_SOURCES = gcr/test-filter-collection.c
+test_filter_collection_CFLAGS = $(gcr_CFLAGS)
+test_filter_collection_LDADD = $(gcr_LIBS)
+
+test_fingerprint_SOURCES = gcr/test-fingerprint.c
+test_fingerprint_CFLAGS = $(gcr_CFLAGS)
+test_fingerprint_LDADD = $(gcr_LIBS)
+
+test_gnupg_collection_SOURCES = gcr/test-gnupg-collection.c
+test_gnupg_collection_CFLAGS = $(gcr_CFLAGS)
+test_gnupg_collection_LDADD = $(gcr_LIBS)
+
+test_gnupg_key_SOURCES = gcr/test-gnupg-key.c
+test_gnupg_key_CFLAGS = $(gcr_CFLAGS)
+test_gnupg_key_LDADD = $(gcr_LIBS)
+
+test_gnupg_process_SOURCES = gcr/test-gnupg-process.c
+test_gnupg_process_CFLAGS = $(gcr_CFLAGS)
+test_gnupg_process_LDADD = $(gcr_LIBS)
+
+test_memory_icon_SOURCES = gcr/test-memory-icon.c
+test_memory_icon_CFLAGS = $(gcr_CFLAGS)
+test_memory_icon_LDADD = $(gcr_LIBS)
+
+test_openpgp_SOURCES = gcr/test-openpgp.c
+test_openpgp_CFLAGS = $(gcr_CFLAGS)
+test_openpgp_LDADD = $(gcr_LIBS)
+
+test_openssh_SOURCES = gcr/test-openssh.c
+test_openssh_CFLAGS = $(gcr_CFLAGS)
+test_openssh_LDADD = $(gcr_LIBS)
+
+test_parser_SOURCES = gcr/test-parser.c
+test_parser_CFLAGS = $(gcr_CFLAGS)
+test_parser_LDADD = $(gcr_LIBS)
+
+test_pkcs11_certificate_SOURCES = gcr/test-pkcs11-certificate.c
+test_pkcs11_certificate_CFLAGS = $(gcr_CFLAGS)
+test_pkcs11_certificate_LDADD = $(gcr_LIBS)
+
+test_record_SOURCES = gcr/test-record.c
+test_record_CFLAGS = $(gcr_CFLAGS)
+test_record_LDADD = $(gcr_LIBS)
+
+test_secret_exchange_SOURCES = gcr/test-secret-exchange.c
+test_secret_exchange_CFLAGS = $(gcr_CFLAGS)
+test_secret_exchange_LDADD = $(gcr_LIBS)
+
+test_secure_memory_SOURCES = gcr/test-secure-memory.c
+test_secure_memory_CFLAGS = $(gcr_CFLAGS)
+test_secure_memory_LDADD = $(gcr_LIBS)
+
+test_simple_certificate_SOURCES = gcr/test-simple-certificate.c
+test_simple_certificate_CFLAGS = $(gcr_CFLAGS)
+test_simple_certificate_LDADD = $(gcr_LIBS)
+
+test_subject_public_key_SOURCES = gcr/test-subject-public-key.c
+test_subject_public_key_CFLAGS = $(gcr_CFLAGS)
+test_subject_public_key_LDADD = $(gcr_LIBS)
+
+test_system_prompt_SOURCES = gcr/test-system-prompt.c
+test_system_prompt_CFLAGS = $(gcr_CFLAGS)
+test_system_prompt_LDADD = $(gcr_LIBS)
+
+test_trust_SOURCES = gcr/test-trust.c
+test_trust_CFLAGS = $(gcr_CFLAGS)
+test_trust_LDADD = $(gcr_LIBS)
+
+test_util_SOURCES = gcr/test-util.c
+test_util_CFLAGS = $(gcr_CFLAGS)
+test_util_LDADD = $(gcr_LIBS)
+
+check_PROGRAMS += $(gcr_TESTS)
+TESTS += $(gcr_TESTS)
+
+EXTRA_DIST += \
+ gcr/fixtures
+
+# ------------------------------------------------------------------
+
+noinst_PROGRAMS += \
+ frob-openpgp \
+ frob-certificate-request \
+ frob-parser
+
+frob_certificate_request_SOURCES = \
+ gcr/frob-certificate-request.c \
+ gcr/console-interaction.c gcr/console-interaction.h
+frob_certificate_request_CFLAGS = $(gcr_CFLAGS)
+frob_certificate_request_LDADD = $(gcr_LIBS)
+
+frob_openpgp_SOURCES = gcr/frob-openpgp.c
+frob_openpgp_CFLAGS = $(gcr_CFLAGS)
+frob_openpgp_LDADD = $(gcr_LIBS)
+
+frob_parser_SOURCES = gcr/frob-parser.c
+frob_parser_CFLAGS = $(gcr_CFLAGS)
+frob_parser_LDADD = $(gcr_LIBS)
diff --git a/gcr/tests/console-interaction.c b/gcr/console-interaction.c
index bc3b7dc..bc3b7dc 100644
--- a/gcr/tests/console-interaction.c
+++ b/gcr/console-interaction.c
diff --git a/gcr/tests/console-interaction.h b/gcr/console-interaction.h
index ffd0f0f..ffd0f0f 100644
--- a/gcr/tests/console-interaction.h
+++ b/gcr/console-interaction.h
diff --git a/gcr/tests/files/RSA_Root_Certificate_1.pem b/gcr/fixtures/RSA_Root_Certificate_1.pem
index f6cdfcd..f6cdfcd 100644
--- a/gcr/tests/files/RSA_Root_Certificate_1.pem
+++ b/gcr/fixtures/RSA_Root_Certificate_1.pem
diff --git a/gcr/tests/files/RSA_Security_1024_v3.pem b/gcr/fixtures/RSA_Security_1024_v3.pem
index 94e0ad1..94e0ad1 100644
--- a/gcr/tests/files/RSA_Security_1024_v3.pem
+++ b/gcr/fixtures/RSA_Security_1024_v3.pem
diff --git a/gcr/tests/files/RSA_Security_2048_v3.pem b/gcr/fixtures/RSA_Security_2048_v3.pem
index 86c907e..86c907e 100644
--- a/gcr/tests/files/RSA_Security_2048_v3.pem
+++ b/gcr/fixtures/RSA_Security_2048_v3.pem
diff --git a/gcr/tests/files/Thawte_Personal_Basic_CA.pem b/gcr/fixtures/Thawte_Personal_Basic_CA.pem
index 22c2a8d..22c2a8d 100644
--- a/gcr/tests/files/Thawte_Personal_Basic_CA.pem
+++ b/gcr/fixtures/Thawte_Personal_Basic_CA.pem
diff --git a/gcr/tests/files/Thawte_Personal_Freemail_CA.pem b/gcr/fixtures/Thawte_Personal_Freemail_CA.pem
index 565a4be..565a4be 100644
--- a/gcr/tests/files/Thawte_Personal_Freemail_CA.pem
+++ b/gcr/fixtures/Thawte_Personal_Freemail_CA.pem
diff --git a/gcr/tests/files/Thawte_Personal_Premium_CA.pem b/gcr/fixtures/Thawte_Personal_Premium_CA.pem
index 688c3ae..688c3ae 100644
--- a/gcr/tests/files/Thawte_Personal_Premium_CA.pem
+++ b/gcr/fixtures/Thawte_Personal_Premium_CA.pem
diff --git a/gcr/tests/files/Thawte_Premium_Server_CA.pem b/gcr/fixtures/Thawte_Premium_Server_CA.pem
index aa37cfc..aa37cfc 100644
--- a/gcr/tests/files/Thawte_Premium_Server_CA.pem
+++ b/gcr/fixtures/Thawte_Premium_Server_CA.pem
diff --git a/gcr/tests/files/Thawte_Server_CA.pem b/gcr/fixtures/Thawte_Server_CA.pem
index ac4e25b..ac4e25b 100644
--- a/gcr/tests/files/Thawte_Server_CA.pem
+++ b/gcr/fixtures/Thawte_Server_CA.pem
diff --git a/gcr/tests/files/Thawte_Time_Stamping_CA.pem b/gcr/fixtures/Thawte_Time_Stamping_CA.pem
index fecbd15..fecbd15 100644
--- a/gcr/tests/files/Thawte_Time_Stamping_CA.pem
+++ b/gcr/fixtures/Thawte_Time_Stamping_CA.pem
diff --git a/gcr/tests/files/base64-rsa-2048.spkac b/gcr/fixtures/base64-rsa-2048.spkac
index e1a3286..e1a3286 100644
--- a/gcr/tests/files/base64-rsa-2048.spkac
+++ b/gcr/fixtures/base64-rsa-2048.spkac
diff --git a/gcr/tests/files/ca-certificates.crt b/gcr/fixtures/ca-certificates.crt
index c30335f..c30335f 100644
--- a/gcr/tests/files/ca-certificates.crt
+++ b/gcr/fixtures/ca-certificates.crt
diff --git a/gcr/tests/files/cacert.org.cer b/gcr/fixtures/cacert.org.cer
index 719b0ff..719b0ff 100644
--- a/gcr/tests/files/cacert.org.cer
+++ b/gcr/fixtures/cacert.org.cer
Binary files differ
diff --git a/gcr/tests/files/cacert.org.pem b/gcr/fixtures/cacert.org.pem
index e7dfc82..e7dfc82 100644
--- a/gcr/tests/files/cacert.org.pem
+++ b/gcr/fixtures/cacert.org.pem
diff --git a/gcr/tests/files/client.crt b/gcr/fixtures/client.crt
index a4bc2fc..a4bc2fc 100644
--- a/gcr/tests/files/client.crt
+++ b/gcr/fixtures/client.crt
Binary files differ
diff --git a/gcr/tests/files/client.key b/gcr/fixtures/client.key
index 206f527..206f527 100644
--- a/gcr/tests/files/client.key
+++ b/gcr/fixtures/client.key
diff --git a/gcr/tests/files/client.pem b/gcr/fixtures/client.pem
index 04bc8ac..04bc8ac 100644
--- a/gcr/tests/files/client.pem
+++ b/gcr/fixtures/client.pem
diff --git a/gcr/tests/files/client.spk b/gcr/fixtures/client.spk
index 09ab6b9..09ab6b9 100644
--- a/gcr/tests/files/client.spk
+++ b/gcr/fixtures/client.spk
Binary files differ
diff --git a/gcr/tests/files/collabora-ca.cer b/gcr/fixtures/collabora-ca.cer
index 2842c69..2842c69 100644
--- a/gcr/tests/files/collabora-ca.cer
+++ b/gcr/fixtures/collabora-ca.cer
Binary files differ
diff --git a/gcr/tests/files/der-certificate-dsa.cer b/gcr/fixtures/der-certificate-dsa.cer
index 024f3c1..024f3c1 100755
--- a/gcr/tests/files/der-certificate-dsa.cer
+++ b/gcr/fixtures/der-certificate-dsa.cer
Binary files differ
diff --git a/gcr/tests/files/der-certificate.crt b/gcr/fixtures/der-certificate.crt
index 56fa849..56fa849 100644
--- a/gcr/tests/files/der-certificate.crt
+++ b/gcr/fixtures/der-certificate.crt
Binary files differ
diff --git a/gcr/tests/files/der-dsa-1024.key b/gcr/fixtures/der-dsa-1024.key
index 61af525..61af525 100644
--- a/gcr/tests/files/der-dsa-1024.key
+++ b/gcr/fixtures/der-dsa-1024.key
Binary files differ
diff --git a/gcr/tests/files/der-key-PBE-MD5-DES.p8 b/gcr/fixtures/der-key-PBE-MD5-DES.p8
index 71b7d61..71b7d61 100644
--- a/gcr/tests/files/der-key-PBE-MD5-DES.p8
+++ b/gcr/fixtures/der-key-PBE-MD5-DES.p8
Binary files differ
diff --git a/gcr/tests/files/der-key-PBE-SHA1-3DES.p8 b/gcr/fixtures/der-key-PBE-SHA1-3DES.p8
index 1c37fe1..1c37fe1 100644
--- a/gcr/tests/files/der-key-PBE-SHA1-3DES.p8
+++ b/gcr/fixtures/der-key-PBE-SHA1-3DES.p8
Binary files differ
diff --git a/gcr/tests/files/der-key-PBE-SHA1-DES.p8 b/gcr/fixtures/der-key-PBE-SHA1-DES.p8
index 9989613..9989613 100644
--- a/gcr/tests/files/der-key-PBE-SHA1-DES.p8
+++ b/gcr/fixtures/der-key-PBE-SHA1-DES.p8
Binary files differ
diff --git a/gcr/tests/files/der-key-PBE-SHA1-RC2-40.p8 b/gcr/fixtures/der-key-PBE-SHA1-RC2-40.p8
index 820926c..820926c 100644
--- a/gcr/tests/files/der-key-PBE-SHA1-RC2-40.p8
+++ b/gcr/fixtures/der-key-PBE-SHA1-RC2-40.p8
Binary files differ
diff --git a/gcr/tests/files/der-key-PBE-SHA1-RC4-128.p8 b/gcr/fixtures/der-key-PBE-SHA1-RC4-128.p8
index 2888450..2888450 100644
--- a/gcr/tests/files/der-key-PBE-SHA1-RC4-128.p8
+++ b/gcr/fixtures/der-key-PBE-SHA1-RC4-128.p8
Binary files differ
diff --git a/gcr/tests/files/der-key-dsa.p8 b/gcr/fixtures/der-key-dsa.p8
index 8b61684..8b61684 100644
--- a/gcr/tests/files/der-key-dsa.p8
+++ b/gcr/fixtures/der-key-dsa.p8
Binary files differ
diff --git a/gcr/tests/files/der-key-encrypted-pkcs5.p8 b/gcr/fixtures/der-key-encrypted-pkcs5.p8
index 68c6b4a..68c6b4a 100644
--- a/gcr/tests/files/der-key-encrypted-pkcs5.p8
+++ b/gcr/fixtures/der-key-encrypted-pkcs5.p8
Binary files differ
diff --git a/gcr/tests/files/der-key-v2-des.p8 b/gcr/fixtures/der-key-v2-des.p8
index 4cd8034..4cd8034 100644
--- a/gcr/tests/files/der-key-v2-des.p8
+++ b/gcr/fixtures/der-key-v2-des.p8
Binary files differ
diff --git a/gcr/tests/files/der-key-v2-des3.p8 b/gcr/fixtures/der-key-v2-des3.p8
index 9e2999c..9e2999c 100644
--- a/gcr/tests/files/der-key-v2-des3.p8
+++ b/gcr/fixtures/der-key-v2-des3.p8
Binary files differ
diff --git a/gcr/tests/files/der-key.p8 b/gcr/fixtures/der-key.p8
index 1650563..1650563 100644
--- a/gcr/tests/files/der-key.p8
+++ b/gcr/fixtures/der-key.p8
Binary files differ
diff --git a/gcr/tests/files/der-rsa-1024.key b/gcr/fixtures/der-rsa-1024.key
index 878fda5..878fda5 100644
--- a/gcr/tests/files/der-rsa-1024.key
+++ b/gcr/fixtures/der-rsa-1024.key
Binary files differ
diff --git a/gcr/tests/files/der-rsa-2048.p10 b/gcr/fixtures/der-rsa-2048.p10
index 6355622..6355622 100644
--- a/gcr/tests/files/der-rsa-2048.p10
+++ b/gcr/fixtures/der-rsa-2048.p10
Binary files differ
diff --git a/gcr/tests/files/der-rsa-2048.spkac b/gcr/fixtures/der-rsa-2048.spkac
index f3b3781..f3b3781 100644
--- a/gcr/tests/files/der-rsa-2048.spkac
+++ b/gcr/fixtures/der-rsa-2048.spkac
Binary files differ
diff --git a/gcr/tests/files/dhansak-collabora.cer b/gcr/fixtures/dhansak-collabora.cer
index c411e7d..c411e7d 100644
--- a/gcr/tests/files/dhansak-collabora.cer
+++ b/gcr/fixtures/dhansak-collabora.cer
Binary files differ
diff --git a/gcr/tests/files/email.p12 b/gcr/fixtures/email.p12
index d45d0f8..d45d0f8 100644
--- a/gcr/tests/files/email.p12
+++ b/gcr/fixtures/email.p12
Binary files differ
diff --git a/gcr/tests/files/generic-dsa.crt b/gcr/fixtures/generic-dsa.crt
index 5658a20..5658a20 100644
--- a/gcr/tests/files/generic-dsa.crt
+++ b/gcr/fixtures/generic-dsa.crt
Binary files differ
diff --git a/gcr/tests/files/generic-dsa.key b/gcr/fixtures/generic-dsa.key
index cdd7ca5..cdd7ca5 100644
--- a/gcr/tests/files/generic-dsa.key
+++ b/gcr/fixtures/generic-dsa.key
diff --git a/gcr/tests/files/generic-dsa.pem b/gcr/fixtures/generic-dsa.pem
index 0d81ef2..0d81ef2 100644
--- a/gcr/tests/files/generic-dsa.pem
+++ b/gcr/fixtures/generic-dsa.pem
diff --git a/gcr/tests/files/generic-dsa.spk b/gcr/fixtures/generic-dsa.spk
index 161391c..161391c 100644
--- a/gcr/tests/files/generic-dsa.spk
+++ b/gcr/fixtures/generic-dsa.spk
Binary files differ
diff --git a/gcr/tests/files/gnupg-homedir/gpg.conf b/gcr/fixtures/gnupg-homedir/gpg.conf
index 4a536a8..e1479ae 100644
--- a/gcr/tests/files/gnupg-homedir/gpg.conf
+++ b/gcr/fixtures/gnupg-homedir/gpg.conf
@@ -1,2 +1 @@
no-auto-check-trustdb
-
diff --git a/gcr/tests/files/gnupg-homedir/pubring.gpg b/gcr/fixtures/gnupg-homedir/pubring.gpg
index 10b1372..10b1372 100644
--- a/gcr/tests/files/gnupg-homedir/pubring.gpg
+++ b/gcr/fixtures/gnupg-homedir/pubring.gpg
Binary files differ
diff --git a/gcr/tests/files/gnupg-homedir/secring.gpg b/gcr/fixtures/gnupg-homedir/secring.gpg
index 4a21e26..4a21e26 100644
--- a/gcr/tests/files/gnupg-homedir/secring.gpg
+++ b/gcr/fixtures/gnupg-homedir/secring.gpg
Binary files differ
diff --git a/gcr/tests/files/gnupg-homedir/trustdb.gpg b/gcr/fixtures/gnupg-homedir/trustdb.gpg
index 3824098..3824098 100644
--- a/gcr/tests/files/gnupg-homedir/trustdb.gpg
+++ b/gcr/fixtures/gnupg-homedir/trustdb.gpg
Binary files differ
diff --git a/gcr/tests/files/gnupg-mock/mock-arguments-environ b/gcr/fixtures/gnupg-mock/mock-arguments-environ
index 5282a2f..5282a2f 100755
--- a/gcr/tests/files/gnupg-mock/mock-arguments-environ
+++ b/gcr/fixtures/gnupg-mock/mock-arguments-environ
diff --git a/gcr/tests/files/gnupg-mock/mock-echo b/gcr/fixtures/gnupg-mock/mock-echo
index 7c4e251..7c4e251 100755
--- a/gcr/tests/files/gnupg-mock/mock-echo
+++ b/gcr/fixtures/gnupg-mock/mock-echo
diff --git a/gcr/tests/files/gnupg-mock/mock-fail-exit b/gcr/fixtures/gnupg-mock/mock-fail-exit
index 4d5634b..4d5634b 100755
--- a/gcr/tests/files/gnupg-mock/mock-fail-exit
+++ b/gcr/fixtures/gnupg-mock/mock-fail-exit
diff --git a/gcr/tests/files/gnupg-mock/mock-fail-signal b/gcr/fixtures/gnupg-mock/mock-fail-signal
index decf8a4..decf8a4 100755
--- a/gcr/tests/files/gnupg-mock/mock-fail-signal
+++ b/gcr/fixtures/gnupg-mock/mock-fail-signal
diff --git a/gcr/tests/files/gnupg-mock/mock-simple-error b/gcr/fixtures/gnupg-mock/mock-simple-error
index 30bb6a9..30bb6a9 100755
--- a/gcr/tests/files/gnupg-mock/mock-simple-error
+++ b/gcr/fixtures/gnupg-mock/mock-simple-error
diff --git a/gcr/tests/files/gnupg-mock/mock-simple-output b/gcr/fixtures/gnupg-mock/mock-simple-output
index 0d145fc..0d145fc 100755
--- a/gcr/tests/files/gnupg-mock/mock-simple-output
+++ b/gcr/fixtures/gnupg-mock/mock-simple-output
diff --git a/gcr/tests/files/gnupg-mock/mock-status-and-attribute b/gcr/fixtures/gnupg-mock/mock-status-and-attribute
index abf8607..abf8607 100755
--- a/gcr/tests/files/gnupg-mock/mock-status-and-attribute
+++ b/gcr/fixtures/gnupg-mock/mock-status-and-attribute
diff --git a/gcr/tests/files/gnupg-mock/mock-status-and-output b/gcr/fixtures/gnupg-mock/mock-status-and-output
index 0fd544b..0fd544b 100755
--- a/gcr/tests/files/gnupg-mock/mock-status-and-output
+++ b/gcr/fixtures/gnupg-mock/mock-status-and-output
diff --git a/gcr/tests/files/gnupg-mock/mock-with-homedir b/gcr/fixtures/gnupg-mock/mock-with-homedir
index c537e03..c537e03 100755
--- a/gcr/tests/files/gnupg-mock/mock-with-homedir
+++ b/gcr/fixtures/gnupg-mock/mock-with-homedir
diff --git a/gcr/tests/files/jabber-server.cer b/gcr/fixtures/jabber-server.cer
index 086b3ae..086b3ae 100644
--- a/gcr/tests/files/jabber-server.cer
+++ b/gcr/fixtures/jabber-server.cer
Binary files differ
diff --git a/gcr/tests/files/openssh_keys.pub b/gcr/fixtures/openssh_keys.pub
index 00d294b..00d294b 100644
--- a/gcr/tests/files/openssh_keys.pub
+++ b/gcr/fixtures/openssh_keys.pub
diff --git a/gcr/tests/files/pem-dsa-1024.key b/gcr/fixtures/pem-dsa-1024.key
index ccb1e7b..ccb1e7b 100644
--- a/gcr/tests/files/pem-dsa-1024.key
+++ b/gcr/fixtures/pem-dsa-1024.key
diff --git a/gcr/tests/files/pem-pkcs8.key b/gcr/fixtures/pem-pkcs8.key
index 1f0d5ed..1f0d5ed 100644
--- a/gcr/tests/files/pem-pkcs8.key
+++ b/gcr/fixtures/pem-pkcs8.key
diff --git a/gcr/tests/files/pem-rsa-2048.req b/gcr/fixtures/pem-rsa-2048.req
index 71bd130..71bd130 100644
--- a/gcr/tests/files/pem-rsa-2048.req
+++ b/gcr/fixtures/pem-rsa-2048.req
diff --git a/gcr/tests/files/pem-rsa-enc.key b/gcr/fixtures/pem-rsa-enc.key
index 65439fe..65439fe 100644
--- a/gcr/tests/files/pem-rsa-enc.key
+++ b/gcr/fixtures/pem-rsa-enc.key
diff --git a/gcr/tests/files/pem-with-attributes.req b/gcr/fixtures/pem-with-attributes.req
index bcbe8f5..bcbe8f5 100644
--- a/gcr/tests/files/pem-with-attributes.req
+++ b/gcr/fixtures/pem-with-attributes.req
diff --git a/gcr/tests/files/personal.p12 b/gcr/fixtures/personal.p12
index 7ae3d05..7ae3d05 100644
--- a/gcr/tests/files/personal.p12
+++ b/gcr/fixtures/personal.p12
Binary files differ
diff --git a/gcr/tests/files/prompt-tests/multiple.prompt b/gcr/fixtures/prompt-tests/multiple.prompt
index 5f02425..5f02425 100644
--- a/gcr/tests/files/prompt-tests/multiple.prompt
+++ b/gcr/fixtures/prompt-tests/multiple.prompt
diff --git a/gcr/tests/files/prompt-tests/password-choice.prompt b/gcr/fixtures/prompt-tests/password-choice.prompt
index 5dfc676..5dfc676 100644
--- a/gcr/tests/files/prompt-tests/password-choice.prompt
+++ b/gcr/fixtures/prompt-tests/password-choice.prompt
diff --git a/gcr/tests/files/pubring.gpg b/gcr/fixtures/pubring.gpg
index 10b1372..10b1372 100644
--- a/gcr/tests/files/pubring.gpg
+++ b/gcr/fixtures/pubring.gpg
Binary files differ
diff --git a/gcr/tests/files/secring.gpg b/gcr/fixtures/secring.gpg
index 4a21e26..4a21e26 100644
--- a/gcr/tests/files/secring.gpg
+++ b/gcr/fixtures/secring.gpg
Binary files differ
diff --git a/gcr/tests/files/startcom-ca.cer b/gcr/fixtures/startcom-ca.cer
index b60dea2..b60dea2 100644
--- a/gcr/tests/files/startcom-ca.cer
+++ b/gcr/fixtures/startcom-ca.cer
Binary files differ
diff --git a/gcr/tests/files/startcom-intermediate.cer b/gcr/fixtures/startcom-intermediate.cer
index a27a7df..a27a7df 100644
--- a/gcr/tests/files/startcom-intermediate.cer
+++ b/gcr/fixtures/startcom-intermediate.cer
Binary files differ
diff --git a/gcr/tests/files/test-x509-swiss.p7b b/gcr/fixtures/test-x509-swiss.p7b
index d45b9e0..d45b9e0 100755
--- a/gcr/tests/files/test-x509-swiss.p7b
+++ b/gcr/fixtures/test-x509-swiss.p7b
Binary files differ
diff --git a/gcr/tests/files/unclient.p12 b/gcr/fixtures/unclient.p12
index 321b447..321b447 100644
--- a/gcr/tests/files/unclient.p12
+++ b/gcr/fixtures/unclient.p12
Binary files differ
diff --git a/gcr/tests/files/usr0052-firefox.p12 b/gcr/fixtures/usr0052-firefox.p12
index eff8c1e..eff8c1e 100644
--- a/gcr/tests/files/usr0052-firefox.p12
+++ b/gcr/fixtures/usr0052-firefox.p12
Binary files differ
diff --git a/gcr/tests/files/werner-koch.asc b/gcr/fixtures/werner-koch.asc
index eb70c97..eb70c97 100644
--- a/gcr/tests/files/werner-koch.asc
+++ b/gcr/fixtures/werner-koch.asc
diff --git a/gcr/tests/frob-certificate-request.c b/gcr/frob-certificate-request.c
index 6801b8c..6801b8c 100644
--- a/gcr/tests/frob-certificate-request.c
+++ b/gcr/frob-certificate-request.c
diff --git a/gcr/tests/frob-openpgp.c b/gcr/frob-openpgp.c
index 433056b..433056b 100644
--- a/gcr/tests/frob-openpgp.c
+++ b/gcr/frob-openpgp.c
diff --git a/gcr/tests/frob-parser.c b/gcr/frob-parser.c
index 6b311ab..6b311ab 100644
--- a/gcr/tests/frob-parser.c
+++ b/gcr/frob-parser.c
diff --git a/gcr/gcr-certificate-chain.c b/gcr/gcr-certificate-chain.c
index 42a83f0..c50615c 100644
--- a/gcr/gcr-certificate-chain.c
+++ b/gcr/gcr-certificate-chain.c
@@ -26,11 +26,12 @@
#include "gcr-certificate.h"
#define DEBUG_FLAG GCR_DEBUG_CERTIFICATE_CHAIN
#include "gcr-debug.h"
-#include "gcr-enum-types-base.h"
#include "gcr-pkcs11-certificate.h"
#include "gcr-simple-certificate.h"
#include "gcr-trust.h"
+#include "gcr/gcr-enum-types-base.h"
+
#include "egg/egg-error.h"
/**
diff --git a/gcr/gcr-certificate-extensions.c b/gcr/gcr-certificate-extensions.c
index 63d1eda..393b3a6 100644
--- a/gcr/gcr-certificate-extensions.c
+++ b/gcr/gcr-certificate-extensions.c
@@ -21,7 +21,8 @@
#include "config.h"
#include "gcr-certificate-extensions.h"
-#include "gcr-oids.h"
+
+#include "gcr/gcr-oids.h"
#include "egg/egg-asn1x.h"
#include "egg/egg-asn1-defs.h"
diff --git a/gcr/gcr-certificate-request.c b/gcr/gcr-certificate-request.c
index 5e946aa..1128f30 100644
--- a/gcr/gcr-certificate-request.c
+++ b/gcr/gcr-certificate-request.c
@@ -21,10 +21,11 @@
#include "gcr-certificate-request.h"
#include "gcr-key-mechanisms.h"
-#include "gcr-enum-types-base.h"
-#include "gcr-oids.h"
#include "gcr-subject-public-key.h"
+#include "gcr/gcr-enum-types-base.h"
+#include "gcr/gcr-oids.h"
+
#include <egg/egg-armor.h>
#include <egg/egg-asn1x.h>
#include <egg/egg-asn1-defs.h>
diff --git a/gcr/gcr-certificate.c b/gcr/gcr-certificate.c
index 0b7d58a..ef3270d 100644
--- a/gcr/gcr-certificate.c
+++ b/gcr/gcr-certificate.c
@@ -24,9 +24,10 @@
#include "gcr-comparable.h"
#include "gcr-icons.h"
#include "gcr-internal.h"
-#include "gcr-oids.h"
#include "gcr-subject-public-key.h"
+#include "gcr/gcr-oids.h"
+
#include "egg/egg-asn1x.h"
#include "egg/egg-asn1-defs.h"
#include "egg/egg-dn.h"
diff --git a/gcr/gcr-fingerprint.c b/gcr/gcr-fingerprint.c
index fc024d1..445f88a 100644
--- a/gcr/gcr-fingerprint.c
+++ b/gcr/gcr-fingerprint.c
@@ -22,9 +22,10 @@
#include "config.h"
#include "gcr-fingerprint.h"
-#include "gcr-oids.h"
#include "gcr-subject-public-key.h"
+#include "gcr/gcr-oids.h"
+
#include "egg/egg-asn1x.h"
#include "egg/egg-asn1-defs.h"
diff --git a/gcr/gcr-gnupg-process.c b/gcr/gcr-gnupg-process.c
index 3435bce..63fab11 100644
--- a/gcr/gcr-gnupg-process.c
+++ b/gcr/gcr-gnupg-process.c
@@ -24,9 +24,10 @@
#define DEBUG_FLAG GCR_DEBUG_GNUPG
#include "gcr-debug.h"
#include "gcr-gnupg-process.h"
-#include "gcr-marshal.h"
#include "gcr-util.h"
+#include "gcr/gcr-marshal.h"
+
#include <glib/gi18n-lib.h>
#include <sys/wait.h>
diff --git a/gcr/gcr-importer.c b/gcr/gcr-importer.c
index bad45e9..528d06b 100644
--- a/gcr/gcr-importer.c
+++ b/gcr/gcr-importer.c
@@ -26,11 +26,12 @@
#include "gcr-deprecated-base.h"
#include "gcr-importer.h"
#include "gcr-internal.h"
-#include "gcr-marshal.h"
#include "gcr-gnupg-importer.h"
#include "gcr-parser.h"
#include "gcr-pkcs11-importer.h"
+#include "gcr/gcr-marshal.h"
+
#include <glib/gi18n-lib.h>
/**
diff --git a/gcr/gcr-parser.c b/gcr/gcr-parser.c
index d64758e..4c39a1a 100644
--- a/gcr/gcr-parser.c
+++ b/gcr/gcr-parser.c
@@ -22,14 +22,15 @@
#include "gck/gck.h"
#include "gcr-internal.h"
-#include "gcr-marshal.h"
-#include "gcr-oids.h"
#include "gcr-openpgp.h"
#include "gcr-openssh.h"
#include "gcr-parser.h"
#include "gcr-record.h"
#include "gcr-types.h"
+#include "gcr/gcr-marshal.h"
+#include "gcr/gcr-oids.h"
+
#include "egg/egg-armor.h"
#include "egg/egg-asn1x.h"
#include "egg/egg-asn1-defs.h"
diff --git a/gcr/gcr-subject-public-key.c b/gcr/gcr-subject-public-key.c
index 8ac4f59..5b7dc28 100644
--- a/gcr/gcr-subject-public-key.c
+++ b/gcr/gcr-subject-public-key.c
@@ -22,10 +22,11 @@
#define DEBUG_FLAG GCR_DEBUG_KEY
#include "gcr-debug.h"
-#include "gcr-oids.h"
#include "gcr-subject-public-key.h"
#include "gcr-types.h"
+#include "gcr/gcr-oids.h"
+
#include "egg/egg-asn1x.h"
#include "egg/egg-asn1-defs.h"
#include "egg/egg-error.h"
diff --git a/gcr/gcr-system-prompt.c b/gcr/gcr-system-prompt.c
index a6d8f95..7874ad1 100644
--- a/gcr/gcr-system-prompt.c
+++ b/gcr/gcr-system-prompt.c
@@ -22,7 +22,6 @@
#include "config.h"
#include "gcr-dbus-constants.h"
-#include "gcr-dbus-generated.h"
#define DEBUG_FLAG GCR_DEBUG_PROMPT
#include "gcr-debug.h"
#include "gcr-internal.h"
@@ -31,6 +30,8 @@
#include "gcr-secret-exchange.h"
#include "gcr-system-prompt.h"
+#include "gcr/gcr-dbus-generated.h"
+
#include "egg/egg-error.h"
#include <glib/gi18n.h>
diff --git a/gcr/gcr-system-prompter.c b/gcr/gcr-system-prompter.c
index 8727ca1..654c686 100644
--- a/gcr/gcr-system-prompter.c
+++ b/gcr/gcr-system-prompter.c
@@ -22,18 +22,19 @@
#include "config.h"
#include "gcr-dbus-constants.h"
-#include "gcr-dbus-generated.h"
#define DEBUG_FLAG GCR_DEBUG_PROMPT
#include "gcr-debug.h"
-#include "gcr-enum-types-base.h"
#include "gcr-internal.h"
#include "gcr-library.h"
-#include "gcr-marshal.h"
#include "gcr-prompt.h"
#include "gcr-secret-exchange.h"
#include "gcr-system-prompter.h"
#include "gcr-system-prompt.h"
+#include "gcr/gcr-dbus-generated.h"
+#include "gcr/gcr-enum-types-base.h"
+#include "gcr/gcr-marshal.h"
+
#include "egg/egg-error.h"
#include <string.h>
diff --git a/gcr/tests/test-certificate-chain.c b/gcr/test-certificate-chain.c
index 45c929a..ac2f734 100644
--- a/gcr/tests/test-certificate-chain.c
+++ b/gcr/test-certificate-chain.c
@@ -165,37 +165,37 @@ setup (Test *test, gconstpointer unused)
gck_list_unref_free (modules);
/* A self-signed certificate */
- if (!g_file_get_contents (SRCDIR "/files/der-certificate.crt", &contents, &n_contents, NULL))
+ if (!g_file_get_contents (SRCDIR "/gcr/fixtures/der-certificate.crt", &contents, &n_contents, NULL))
g_assert_not_reached ();
test->cert_self = gcr_simple_certificate_new ((const guchar *)contents, n_contents);
g_free (contents);
/* A signed certificate */
- if (!g_file_get_contents (SRCDIR "/files/dhansak-collabora.cer", &contents, &n_contents, NULL))
+ if (!g_file_get_contents (SRCDIR "/gcr/fixtures/dhansak-collabora.cer", &contents, &n_contents, NULL))
g_assert_not_reached ();
test->cert_signed = mock_certificate_new (contents, n_contents);
g_free (contents);
/* The signer for the above certificate */
- if (!g_file_get_contents (SRCDIR "/files/collabora-ca.cer", &contents, &n_contents, NULL))
+ if (!g_file_get_contents (SRCDIR "/gcr/fixtures/collabora-ca.cer", &contents, &n_contents, NULL))
g_assert_not_reached ();
test->cert_ca = mock_certificate_new (contents, n_contents);
g_free (contents);
/* A root CA */
- if (!g_file_get_contents (SRCDIR "/files/startcom-ca.cer", &contents, &n_contents, NULL))
+ if (!g_file_get_contents (SRCDIR "/gcr/fixtures/startcom-ca.cer", &contents, &n_contents, NULL))
g_assert_not_reached ();
test->cert_root = mock_certificate_new (contents, n_contents);
g_free (contents);
/* An intermediate */
- if (!g_file_get_contents (SRCDIR "/files/startcom-intermediate.cer", &contents, &n_contents, NULL))
+ if (!g_file_get_contents (SRCDIR "/gcr/fixtures/startcom-intermediate.cer", &contents, &n_contents, NULL))
g_assert_not_reached ();
test->cert_inter = mock_certificate_new (contents, n_contents);
g_free (contents);
/* Signed by above intermediate */
- if (!g_file_get_contents (SRCDIR "/files/jabber-server.cer", &contents, &n_contents, NULL))
+ if (!g_file_get_contents (SRCDIR "/gcr/fixtures/jabber-server.cer", &contents, &n_contents, NULL))
g_assert_not_reached ();
test->cert_host = mock_certificate_new (contents, n_contents);
g_free (contents);
diff --git a/gcr/tests/test-certificate.c b/gcr/test-certificate.c
index 71f43ba..8d77e88 100644
--- a/gcr/tests/test-certificate.c
+++ b/gcr/test-certificate.c
@@ -43,19 +43,19 @@ setup (Test *test, gconstpointer unused)
gchar *contents;
gsize n_contents;
- if (!g_file_get_contents (SRCDIR "/files/der-certificate.crt", &contents, &n_contents, NULL))
+ if (!g_file_get_contents (SRCDIR "/gcr/fixtures/der-certificate.crt", &contents, &n_contents, NULL))
g_assert_not_reached ();
test->certificate = gcr_simple_certificate_new ((const guchar *)contents, n_contents);
g_assert (test->certificate);
g_free (contents);
- if (!g_file_get_contents (SRCDIR "/files/der-certificate-dsa.cer", &contents, &n_contents, NULL))
+ if (!g_file_get_contents (SRCDIR "/gcr/fixtures/der-certificate-dsa.cer", &contents, &n_contents, NULL))
g_assert_not_reached ();
test->dsa_cert = gcr_simple_certificate_new ((const guchar *)contents, n_contents);
g_assert (test->dsa_cert);
g_free (contents);
- if (!g_file_get_contents (SRCDIR "/files/dhansak-collabora.cer", &contents, &n_contents, NULL))
+ if (!g_file_get_contents (SRCDIR "/gcr/fixtures/dhansak-collabora.cer", &contents, &n_contents, NULL))
g_assert_not_reached ();
test->dhansak_cert = gcr_simple_certificate_new ((const guchar *)contents, n_contents);
g_assert (test->certificate);
diff --git a/gcr/tests/test-filter-collection.c b/gcr/test-filter-collection.c
index 3710ea8..3710ea8 100644
--- a/gcr/tests/test-filter-collection.c
+++ b/gcr/test-filter-collection.c
diff --git a/gcr/tests/test-fingerprint.c b/gcr/test-fingerprint.c
index 4bbdfe3..6c5e07b 100644
--- a/gcr/tests/test-fingerprint.c
+++ b/gcr/test-fingerprint.c
@@ -51,19 +51,19 @@ setup (Test *test, gconstpointer unused)
gchar *contents;
gsize length;
- g_file_get_contents (SRCDIR "/files/client.crt", &contents, &length, &error);
+ g_file_get_contents (SRCDIR "/gcr/fixtures/client.crt", &contents, &length, &error);
g_assert_no_error (error);
test->cert_rsa = g_bytes_new_take (contents, length);
- g_file_get_contents (SRCDIR "/files/client.key", &contents, &length, &error);
+ g_file_get_contents (SRCDIR "/gcr/fixtures/client.key", &contents, &length, &error);
g_assert_no_error (error);
test->key_rsa = g_bytes_new_take (contents, length);
- g_file_get_contents (SRCDIR "/files/generic-dsa.crt", &contents, &length, &error);
+ g_file_get_contents (SRCDIR "/gcr/fixtures/generic-dsa.crt", &contents, &length, &error);
g_assert_no_error (error);
test->cert_dsa = g_bytes_new_take (contents, length);
- g_file_get_contents (SRCDIR "/files/generic-dsa.key", &contents, &length, &error);
+ g_file_get_contents (SRCDIR "/gcr/fixtures/generic-dsa.key", &contents, &length, &error);
g_assert_no_error (error);
test->key_dsa = g_bytes_new_take (contents, length);
}
diff --git a/gcr/tests/test-gnupg-collection.c b/gcr/test-gnupg-collection.c
index 9a721ef..d10661f 100644
--- a/gcr/tests/test-gnupg-collection.c
+++ b/gcr/test-gnupg-collection.c
@@ -29,8 +29,10 @@
#include "egg/egg-testing.h"
#include <glib.h>
+#include <glib/gstdio.h>
#include <errno.h>
+#include <stdlib.h>
#include <string.h>
typedef struct {
@@ -81,8 +83,16 @@ static void
setup (Test *test, gconstpointer unused)
{
GcrCollection *collection;
+ GError *error = NULL;
+ gchar *cmd;
+
+ test->directory = g_build_filename ("/tmp/gcr-tests.XXXXXX", NULL);
+ g_assert (g_mkdtemp_full (test->directory, 0700) != NULL);
- test->directory = g_build_filename (SRCDIR, "files", "gnupg-homedir", NULL);
+ cmd = g_strdup_printf ("cp -p " SRCDIR "/gcr/fixtures/gnupg-homedir/* %s", test->directory);
+ g_spawn_check_exit_status (system (cmd), &error);
+ g_assert_no_error (error);
+ g_free (cmd);
collection = _gcr_gnupg_collection_new (test->directory);
test->collection = GCR_GNUPG_COLLECTION (collection);
@@ -95,12 +105,23 @@ setup (Test *test, gconstpointer unused)
static void
teardown (Test *test, gconstpointer unused)
{
+ GError *error = NULL;
+ gchar *cmd;
+
g_hash_table_destroy (test->keys);
if (test->result)
g_object_unref (test->result);
g_object_unref (test->collection);
+
+ cmd = g_strdup_printf ("rm %s/*", test->directory);
+ g_spawn_check_exit_status (system (cmd), &error);
+ g_assert_no_error (error);
+ g_free (cmd);
+
+ if (g_rmdir (test->directory) < 0)
+ g_critical ("couldn't remove %s: %s", test->directory, g_strerror (errno));
g_free (test->directory);
}
diff --git a/gcr/tests/test-gnupg-key.c b/gcr/test-gnupg-key.c
index 1d86907..1d86907 100644
--- a/gcr/tests/test-gnupg-key.c
+++ b/gcr/test-gnupg-key.c
diff --git a/gcr/tests/test-gnupg-process.c b/gcr/test-gnupg-process.c
index b7dcb12..7051700 100644
--- a/gcr/tests/test-gnupg-process.c
+++ b/gcr/test-gnupg-process.c
@@ -115,7 +115,7 @@ build_script_path (const gchar *name)
{
gchar *path;
- path = g_build_filename (SRCDIR, "files", "gnupg-mock", name, NULL);
+ path = g_build_filename (SRCDIR, "gcr", "fixtures", "gnupg-mock", name, NULL);
return path;
}
diff --git a/gcr/tests/test-memory-icon.c b/gcr/test-memory-icon.c
index 39f1a0a..39f1a0a 100644
--- a/gcr/tests/test-memory-icon.c
+++ b/gcr/test-memory-icon.c
diff --git a/gcr/tests/test-openpgp.c b/gcr/test-openpgp.c
index f33da5e..21226e6 100644
--- a/gcr/tests/test-openpgp.c
+++ b/gcr/test-openpgp.c
@@ -166,28 +166,28 @@ static Fixture fixtures[] = {
{
"werner_koch",
werner_koch_records,
- SRCDIR "/files/werner-koch.asc",
+ SRCDIR "/gcr/fixtures/werner-koch.asc",
"GnuPG v1.4.11 (GNU/Linux)",
GCR_OPENPGP_PARSE_KEYS
},
{
"werner_koch_with_sigs",
werner_sig_records,
- SRCDIR "/files/werner-koch.asc",
+ SRCDIR "/gcr/fixtures/werner-koch.asc",
"GnuPG v1.4.11 (GNU/Linux)",
GCR_OPENPGP_PARSE_KEYS | GCR_OPENPGP_PARSE_SIGNATURES
},
{
"pubring",
pubring_records,
- SRCDIR "/files/pubring.gpg",
+ SRCDIR "/gcr/fixtures/pubring.gpg",
NULL,
GCR_OPENPGP_PARSE_KEYS
},
{
"secring",
secring_records,
- SRCDIR "/files/secring.gpg",
+ SRCDIR "/gcr/fixtures/secring.gpg",
NULL,
GCR_OPENPGP_PARSE_KEYS
}
diff --git a/gcr/tests/test-openssh.c b/gcr/test-openssh.c
index bde412a..bde412a 100644
--- a/gcr/tests/test-openssh.c
+++ b/gcr/test-openssh.c
diff --git a/gcr/tests/test-parser.c b/gcr/test-parser.c
index a2e6aac..a8dced7 100644
--- a/gcr/tests/test-parser.c
+++ b/gcr/test-parser.c
@@ -209,7 +209,7 @@ test_parsed_bytes (void)
GBytes *bytes;
gsize len;
- if (!g_file_get_contents (SRCDIR "/files/cacert.org.cer", &contents, &len, NULL))
+ if (!g_file_get_contents (SRCDIR "/gcr/fixtures/cacert.org.cer", &contents, &len, NULL))
g_assert_not_reached ();
bytes = g_bytes_new_take (contents, len);
@@ -264,11 +264,11 @@ test_parse_stream (void)
gsize len;
GBytes *bytes;
- file = g_file_new_for_path (SRCDIR "/files/cacert.org.cer");
+ file = g_file_new_for_path (SRCDIR "/gcr/fixtures/cacert.org.cer");
fis = g_file_read (file, NULL, &error);
g_assert_no_error (error);
- if (!g_file_get_contents (SRCDIR "/files/cacert.org.cer", &contents, &len, NULL))
+ if (!g_file_get_contents (SRCDIR "/gcr/fixtures/cacert.org.cer", &contents, &len, NULL))
g_assert_not_reached ();
bytes = g_bytes_new_take (contents, len);
g_signal_connect (parser, "parsed", G_CALLBACK (on_parsed_compare_bytes), bytes);
@@ -304,7 +304,7 @@ test_parse_filename (void)
gsize len;
GBytes *bytes;
- if (!g_file_get_contents (SRCDIR "/files/cacert.org.cer", &contents, &len, NULL))
+ if (!g_file_get_contents (SRCDIR "/gcr/fixtures/cacert.org.cer", &contents, &len, NULL))
g_assert_not_reached ();
bytes = g_bytes_new_take (contents, len);
@@ -343,7 +343,7 @@ main (int argc, char **argv)
g_set_prgname ("test-parser");
strings = g_ptr_array_new_with_free_func (g_free);
- dir = g_dir_open (SRCDIR "/files", 0, &error);
+ dir = g_dir_open (SRCDIR "/gcr/fixtures", 0, &error);
g_assert_no_error (error);
for (;;) {
@@ -353,7 +353,7 @@ main (int argc, char **argv)
if (filename[0] == '.')
continue;
- path = g_build_filename (SRCDIR "/files", filename, NULL);
+ path = g_build_filename (SRCDIR "/gcr/fixtures", filename, NULL);
if (g_file_test (path, G_FILE_TEST_IS_DIR)) {
g_free (path);
diff --git a/gcr/tests/test-pkcs11-certificate.c b/gcr/test-pkcs11-certificate.c
index ad70542..c3ac8a4 100644
--- a/gcr/tests/test-pkcs11-certificate.c
+++ b/gcr/test-pkcs11-certificate.c
@@ -57,12 +57,12 @@ setup (Test *test, gconstpointer unused)
GNode *asn, *node;
CK_RV rv;
- if (!g_file_get_contents (SRCDIR "/files/der-certificate.crt", (gchar**)&test->cert_data,
+ if (!g_file_get_contents (SRCDIR "/gcr/fixtures/der-certificate.crt", (gchar**)&test->cert_data,
&test->n_cert_data, NULL))
g_assert_not_reached ();
g_assert (test->cert_data);
- if (!g_file_get_contents (SRCDIR "/files/der-certificate-dsa.cer", (gchar**)&test->cert2_data,
+ if (!g_file_get_contents (SRCDIR "/gcr/fixtures/der-certificate-dsa.cer", (gchar**)&test->cert2_data,
&test->n_cert2_data, NULL))
g_assert_not_reached ();
g_assert (test->cert2_data);
diff --git a/gcr/tests/test-record.c b/gcr/test-record.c
index c560544..c560544 100644
--- a/gcr/tests/test-record.c
+++ b/gcr/test-record.c
diff --git a/gcr/tests/test-secret-exchange.c b/gcr/test-secret-exchange.c
index 1b60742..1b60742 100644
--- a/gcr/tests/test-secret-exchange.c
+++ b/gcr/test-secret-exchange.c
diff --git a/gcr/tests/test-secure-memory.c b/gcr/test-secure-memory.c
index 812f213..812f213 100644
--- a/gcr/tests/test-secure-memory.c
+++ b/gcr/test-secure-memory.c
diff --git a/gcr/tests/test-simple-certificate.c b/gcr/test-simple-certificate.c
index 48a509a..38287b1 100644
--- a/gcr/tests/test-simple-certificate.c
+++ b/gcr/test-simple-certificate.c
@@ -40,7 +40,7 @@ typedef struct {
static void
setup (Test *test, gconstpointer unused)
{
- if (!g_file_get_contents (SRCDIR "/files/der-certificate.crt", (gchar**)&test->cert_data,
+ if (!g_file_get_contents (SRCDIR "/gcr/fixtures/der-certificate.crt", (gchar**)&test->cert_data,
&test->n_cert_data, NULL))
g_assert_not_reached ();
g_assert (test->cert_data);
diff --git a/gcr/tests/test-subject-public-key.c b/gcr/test-subject-public-key.c
index 90ff36a..3f84df6 100644
--- a/gcr/tests/test-subject-public-key.c
+++ b/gcr/test-subject-public-key.c
@@ -89,7 +89,7 @@ setup_attributes (TestAttributes *test,
gsize length;
gulong klass;
- filename = g_strdup_printf (SRCDIR "/files/%s.crt", fixture->basename);
+ filename = g_strdup_printf (SRCDIR "/gcr/fixtures/%s.crt", fixture->basename);
g_file_get_contents (filename, &contents, &length, &error);
g_assert_no_error (error);
test->crt_data = g_bytes_new_take (contents, length);
@@ -98,7 +98,7 @@ setup_attributes (TestAttributes *test,
gck_assert_cmpulong (klass, ==, CKO_CERTIFICATE);
g_free (filename);
- filename = g_strdup_printf (SRCDIR "/files/%s.key", fixture->basename);
+ filename = g_strdup_printf (SRCDIR "/gcr/fixtures/%s.key", fixture->basename);
g_file_get_contents (filename, &contents, &length, &error);
g_assert_no_error (error);
test->key_data = g_bytes_new_take (contents, length);
@@ -107,7 +107,7 @@ setup_attributes (TestAttributes *test,
gck_assert_cmpulong (klass, ==, CKO_PRIVATE_KEY);
g_free (filename);
- filename = g_strdup_printf (SRCDIR "/files/%s.spk", fixture->basename);
+ filename = g_strdup_printf (SRCDIR "/gcr/fixtures/%s.spk", fixture->basename);
g_file_get_contents (filename, &contents, &length, &error);
g_assert_no_error (error);
test->spk_data = g_bytes_new_take (contents, length);
diff --git a/gcr/tests/test-system-prompt.c b/gcr/test-system-prompt.c
index b2d384c..b2d384c 100644
--- a/gcr/tests/test-system-prompt.c
+++ b/gcr/test-system-prompt.c
diff --git a/gcr/tests/test-trust.c b/gcr/test-trust.c
index d24d011..eef8bdf 100644
--- a/gcr/tests/test-trust.c
+++ b/gcr/test-trust.c
@@ -52,7 +52,7 @@ setup (Test *test, gconstpointer unused)
gsize len;
CK_RV rv;
- if (!g_file_get_contents (SRCDIR "/files/der-certificate.crt", &contents, &len, NULL))
+ if (!g_file_get_contents (SRCDIR "/gcr/fixtures/der-certificate.crt", &contents, &len, NULL))
g_assert_not_reached ();
g_assert (contents);
diff --git a/gcr/tests/test-util.c b/gcr/test-util.c
index 76bc948..76bc948 100644
--- a/gcr/tests/test-util.c
+++ b/gcr/test-util.c
diff --git a/gcr/tests/Makefile.am b/gcr/tests/Makefile.am
deleted file mode 100644
index 53f3fcd..0000000
--- a/gcr/tests/Makefile.am
+++ /dev/null
@@ -1,71 +0,0 @@
-include $(top_srcdir)/Makefile.decl
-
-AM_CPPFLAGS = \
- -I$(top_builddir) \
- -I$(top_srcdir) \
- -DSRCDIR="\"@abs_srcdir@\"" \
- -DGCR_API_SUBJECT_TO_CHANGE \
- -DGCK_API_SUBJECT_TO_CHANGE \
- -DGCR_COMPILATION \
- $(GLIB_CFLAGS) \
- $(LIBGCRYPT_CFLAGS) \
- $(P11_KIT_CFLAGS)
-
-LDADD = \
- $(top_builddir)/gcr/libgcr-base-@GCR_MAJOR@.la \
- $(top_builddir)/egg/libegg.la \
- $(top_builddir)/gck/libgck-testable.la \
- $(GLIB_LIBS) \
- $(LIBGCRYPT_LIBS) \
- $(P11_KIT_LIBS)
-
-TEST_PROGS = \
- test-util \
- test-filter-collection \
- test-secret-exchange \
- test-simple-certificate \
- test-certificate \
- test-certificate-chain \
- test-subject-public-key \
- test-fingerprint \
- test-pkcs11-certificate \
- test-openpgp \
- test-openssh \
- test-secure-memory \
- test-trust \
- test-parser \
- test-record \
- test-memory-icon \
- test-gnupg-key \
- test-gnupg-collection \
- test-gnupg-process \
- test-system-prompt
-
-check_PROGRAMS = $(TEST_PROGS)
-
-test: $(TEST_PROGS)
- chmod -f 700 $(srcdir)/files/gnupg-homedir
- gtester --verbose -m $(TEST_MODE) --g-fatal-warnings $(TEST_PROGS)
-
-check-local: test
-
-check-memory: perform-memcheck
-
-all-local: $(check_PROGRAMS)
-
-EXTRA_DIST = \
- files
-
-# ------------------------------------------------------------------
-
-noinst_PROGRAMS = \
- frob-openpgp \
- frob-parser
-
-noinst_PROGRAMS += \
- frob-certificate-request \
- frob-parser
-
-frob_certificate_request_SOURCES = \
- frob-certificate-request.c \
- console-interaction.c console-interaction.h
diff --git a/schema/Makefile.am b/schema/Makefile.am
index d9e6b47..5d4c4d5 100644
--- a/schema/Makefile.am
+++ b/schema/Makefile.am
@@ -1,16 +1,16 @@
gsettings_SCHEMAS = \
- org.gnome.crypto.pgp.gschema.xml
+ schema/org.gnome.crypto.pgp.gschema.xml
@GSETTINGS_RULES@
convert_DATA = \
- org.gnome.crypto.pgp.convert \
- org.gnome.crypto.pgp_keyservers.convert
+ schema/org.gnome.crypto.pgp.convert \
+ schema/org.gnome.crypto.pgp_keyservers.convert
convertdir = \
$(datarootdir)/GConf/gsettings
-EXTRA_DIST = \
+EXTRA_DIST += \
$(convert_DATA) \
$(gsettings_SCHEMAS) \ No newline at end of file
diff --git a/testing/Makefile.am b/testing/Makefile.am
deleted file mode 100644
index 275b581..0000000
--- a/testing/Makefile.am
+++ /dev/null
@@ -1,3 +0,0 @@
-
-EXTRA_DIST = \
- ca-example
diff --git a/ui/Makefile.am b/ui/Makefile.am
index 67ecea9..2ae500a 100644
--- a/ui/Makefile.am
+++ b/ui/Makefile.am
@@ -1,40 +1,25 @@
-include $(top_srcdir)/Makefile.decl
-SUBDIRS = . icons tests
+ui_incdir = $(includedir)/gcr-@GCR_MAJOR@/ui
-incdir = $(includedir)/gcr-@GCR_MAJOR@/ui
-
-EXTRA_DIST =
-CLEANFILES =
-
-AM_CPPFLAGS = \
- -I$(top_builddir) \
- -I$(top_srcdir) \
- $(GLIB_CFLAGS) \
- $(LIBGCRYPT_CFLAGS) \
- $(P11_KIT_CFLAGS) \
- -DG_LOG_DOMAIN=\"Gcr\" \
- -DGCR_API_SUBJECT_TO_CHANGE \
- -DLOCALEDIR=\""$(datadir)/locale"\"
-
-check-local: check-symbols
-
-check-memory:
- make -C tests check-memory
-
-check-symbols: gcr-ui-expected.abi gcr-ui-actual.abi
+check-ui-symbols: gcr-ui-expected.abi gcr-ui-actual.abi
$(AM_V_GEN) diff -U0 --ignore-blank-lines gcr-ui-expected.abi gcr-ui-actual.abi || \
(echo "check-symbols: Symbols have CHANGED. Fix gcr-ui.symbols"; exit 1)
-BUILT_SOURCES = \
- gcr-enum-types.c gcr-enum-types.h
+ui_BUILT_SOURCES = \
+ ui/gcr-enum-types.c ui/gcr-enum-types.h
+
+BUILT_SOURCES += \
+ $(ui_BUILT_SOURCES)
libgcr_ui_@GCR_MAJOR@_la_CFLAGS = \
-DGCK_API_SUBJECT_TO_CHANGE \
+ -DGCR_API_SUBJECT_TO_CHANGE \
-DP11_KIT_API_SUBJECT_TO_CHANGE \
+ -DG_LOG_DOMAIN=\"Gcr\" \
-DGCR_COMPILATION \
- $(GTK_CFLAGS) \
- -DUIDIR=\""$(uidir)"\"
+ -DUIDIR=\""$(uidir)"\" \
+ $(P11_KIT_CFLAGS) \
+ $(GTK_CFLAGS)
libgcr_ui_@GCR_MAJOR@_la_LDFLAGS = \
-version-info $(GCR_LT_RELEASE) \
@@ -42,9 +27,9 @@ libgcr_ui_@GCR_MAJOR@_la_LDFLAGS = \
-export-symbols-regex '^_gcr_.*|^gcr_.*|^SECMEM_.*'
libgcr_ui_@GCR_MAJOR@_la_LIBADD = \
- $(top_builddir)/egg/libegg.la \
- $(top_builddir)/gcr/libgcr-base-$(GCR_MAJOR).la \
- $(top_builddir)/gck/libgck-@GCK_MAJOR@.la \
+ libegg.la \
+ libgcr-base-$(GCR_MAJOR).la \
+ libgck-@GCK_MAJOR@.la \
$(GLIB_LIBS) \
$(LIBGCRYPT_LIBS) \
$(P11_KIT_LIBS) \
@@ -60,141 +45,124 @@ install-exec-hook:
uidir = $(datadir)/gcr-@GCR_MAJOR@/ui/
ui_DATA = \
- gcr-pkcs11-import-dialog.ui \
- gcr-unlock-options-widget.ui
+ ui/gcr-pkcs11-import-dialog.ui \
+ ui/gcr-unlock-options-widget.ui
-lib_LTLIBRARIES = \
+lib_LTLIBRARIES += \
libgcr-ui-@GCR_MAJOR@.la
-HEADER_FILES = \
- gcr-ui.h \
- gcr-certificate-basics-widget.h \
- gcr-certificate-details-widget.h \
- gcr-certificate-renderer.h \
- gcr-certificate-widget.h \
- gcr-collection-model.h \
- gcr-combo-selector.h \
- gcr-deprecated.h \
- gcr-failure-renderer.h \
- gcr-key-renderer.h \
- gcr-key-widget.h \
- gcr-import-button.h \
- gcr-list-selector.h \
- gcr-prompt-dialog.h \
- gcr-renderer.h \
- gcr-secure-entry-buffer.h \
- gcr-tree-selector.h \
- gcr-unlock-options-widget.h \
- gcr-viewer.h \
- gcr-viewer-widget.h
-
-inc_HEADERS = \
- $(HEADER_FILES) \
- gcr-enum-types.h
-
-PUBLIC_FILES = \
- gcr-certificate-renderer.c gcr-certificate-renderer.h \
- gcr-certificate-widget.c gcr-certificate-widget.h \
- gcr-collection-model.c gcr-collection-model.h \
- gcr-combo-selector.c gcr-combo-selector.h \
- gcr-failure-renderer.c gcr-failure-renderer.h \
- gcr-key-renderer.c gcr-key-renderer.h \
- gcr-key-widget.c gcr-key-widget.h \
- gcr-import-button.c gcr-import-button.h \
- gcr-list-selector.c gcr-list-selector.h \
- gcr-prompt-dialog.c gcr-prompt-dialog.h \
- gcr-renderer.c gcr-renderer.h \
- gcr-secure-entry-buffer.c gcr-secure-entry-buffer.h \
- gcr-tree-selector.c gcr-tree-selector.h \
- gcr-unlock-options-widget.c gcr-unlock-options-widget.h \
- gcr-viewer.c gcr-viewer.h \
- gcr-viewer-widget.c gcr-viewer-widget.h \
- gcr-ui.h \
+ui_HEADER_FILES = \
+ ui/gcr-ui.h \
+ ui/gcr-certificate-basics-widget.h \
+ ui/gcr-certificate-details-widget.h \
+ ui/gcr-certificate-renderer.h \
+ ui/gcr-certificate-widget.h \
+ ui/gcr-collection-model.h \
+ ui/gcr-combo-selector.h \
+ ui/gcr-deprecated.h \
+ ui/gcr-failure-renderer.h \
+ ui/gcr-key-renderer.h \
+ ui/gcr-key-widget.h \
+ ui/gcr-import-button.h \
+ ui/gcr-list-selector.h \
+ ui/gcr-prompt-dialog.h \
+ ui/gcr-renderer.h \
+ ui/gcr-secure-entry-buffer.h \
+ ui/gcr-tree-selector.h \
+ ui/gcr-unlock-options-widget.h \
+ ui/gcr-viewer.h \
+ ui/gcr-viewer-widget.h
+
+ui_inc_HEADERS = \
+ $(ui_HEADER_FILES) \
+ ui/gcr-enum-types.h
+
+ui_PUBLIC_FILES = \
+ ui/gcr-certificate-renderer.c ui/gcr-certificate-renderer.h \
+ ui/gcr-certificate-widget.c ui/gcr-certificate-widget.h \
+ ui/gcr-collection-model.c ui/gcr-collection-model.h \
+ ui/gcr-combo-selector.c ui/gcr-combo-selector.h \
+ ui/gcr-failure-renderer.c ui/gcr-failure-renderer.h \
+ ui/gcr-key-renderer.c ui/gcr-key-renderer.h \
+ ui/gcr-key-widget.c ui/gcr-key-widget.h \
+ ui/gcr-import-button.c ui/gcr-import-button.h \
+ ui/gcr-list-selector.c ui/gcr-list-selector.h \
+ ui/gcr-prompt-dialog.c ui/gcr-prompt-dialog.h \
+ ui/gcr-renderer.c ui/gcr-renderer.h \
+ ui/gcr-secure-entry-buffer.c ui/gcr-secure-entry-buffer.h \
+ ui/gcr-tree-selector.c ui/gcr-tree-selector.h \
+ ui/gcr-unlock-options-widget.c ui/gcr-unlock-options-widget.h \
+ ui/gcr-viewer.c ui/gcr-viewer.h \
+ ui/gcr-viewer-widget.c ui/gcr-viewer-widget.h \
+ ui/gcr-ui.h \
$(NULL)
-PRIVATE_FILES = \
- eggimagemenuitem.c eggimagemenuitem.h \
- gcr-certificate-basics-widget.c gcr-certificate-basics-widget.h \
- gcr-certificate-details-widget.c gcr-certificate-details-widget.h \
- gcr-certificate-exporter.c gcr-certificate-exporter.h \
- gcr-certificate-renderer-private.h \
- gcr-certificate-request-renderer.c gcr-certificate-request-renderer.h \
- gcr-deprecated.h \
- gcr-dialog-util.c gcr-dialog-util.h \
- gcr-display-scrolled.c gcr-display-scrolled.h \
- gcr-display-view.c gcr-display-view.h \
- gcr-gnupg-renderer.c gcr-gnupg-renderer.h \
- gcr-list-selector-private.h \
- gcr-live-search.c gcr-live-search.h \
- gcr-pkcs11-import-dialog.c gcr-pkcs11-import-dialog.h \
- gcr-pkcs11-import-interaction.c gcr-pkcs11-import-interaction.h \
- gcr-unlock-renderer.c gcr-unlock-renderer.h \
- gcr-viewer-window.c gcr-viewer-window.h \
+ui_PRIVATE_FILES = \
+ ui/eggimagemenuitem.c ui/eggimagemenuitem.h \
+ ui/gcr-certificate-basics-widget.c ui/gcr-certificate-basics-widget.h \
+ ui/gcr-certificate-details-widget.c ui/gcr-certificate-details-widget.h \
+ ui/gcr-certificate-exporter.c ui/gcr-certificate-exporter.h \
+ ui/gcr-certificate-renderer-private.h \
+ ui/gcr-certificate-request-renderer.c ui/gcr-certificate-request-renderer.h \
+ ui/gcr-deprecated.h \
+ ui/gcr-dialog-util.c ui/gcr-dialog-util.h \
+ ui/gcr-display-scrolled.c ui/gcr-display-scrolled.h \
+ ui/gcr-display-view.c ui/gcr-display-view.h \
+ ui/gcr-gnupg-renderer.c ui/gcr-gnupg-renderer.h \
+ ui/gcr-list-selector-private.h \
+ ui/gcr-live-search.c ui/gcr-live-search.h \
+ ui/gcr-pkcs11-import-dialog.c ui/gcr-pkcs11-import-dialog.h \
+ ui/gcr-pkcs11-import-interaction.c ui/gcr-pkcs11-import-interaction.h \
+ ui/gcr-unlock-renderer.c ui/gcr-unlock-renderer.h \
+ ui/gcr-viewer-window.c ui/gcr-viewer-window.h \
$(NULL)
libgcr_ui_@GCR_MAJOR@_la_SOURCES = \
- $(PUBLIC_FILES) \
- $(PRIVATE_FILES) \
+ $(ui_PUBLIC_FILES) \
+ $(ui_PRIVATE_FILES) \
$(NULL)
nodist_libgcr_ui_@GCR_MAJOR@_la_SOURCES = \
- $(BUILT_SOURCES)
+ $(ui_BUILT_SOURCES)
-gcr-enum-types.h: $(ENUM_TEMPLATE_H) $(HEADER_FILES)
+ui/gcr-enum-types.h: $(ENUM_TEMPLATE_H) $(ui_HEADER_FILES)
$(AM_V_GEN) $(GLIB_MKENUMS) --template $^ > $@
-gcr-enum-types.c: $(ENUM_TEMPLATE_C) $(HEADER_FILES)
+ui/gcr-enum-types.c: $(ENUM_TEMPLATE_C) $(ui_HEADER_FILES)
$(AM_V_GEN) $(GLIB_MKENUMS) --template $^ > $@
-gcr-ui-$(GCR_MAJOR).pc: gcr-ui.pc
- $(AM_V_GEN) cp gcr-ui.pc gcr-ui-$(GCR_MAJOR).pc
-gcr-$(GCR_MAJOR).pc: gcr.pc
- $(AM_V_GEN) cp gcr.pc gcr-$(GCR_MAJOR).pc
+gcr-ui-$(GCR_MAJOR).pc: ui/gcr-ui.pc
+ $(AM_V_GEN) cp ui/gcr-ui.pc gcr-ui-$(GCR_MAJOR).pc
+gcr-$(GCR_MAJOR).pc: ui/gcr.pc
+ $(AM_V_GEN) cp ui/gcr.pc gcr-$(GCR_MAJOR).pc
if HAVE_INTROSPECTION
-include $(INTROSPECTION_MAKEFILE)
+INTROSPECTION_GIRS += GcrUi-@GCR_MAJOR@.gir
-INTROSPECTION_GIRS = GcrUi-@GCR_MAJOR@.gir
-INTROSPECTION_SCANNER_ARGS = \
- $(INTROSPECTION_FLAGS) \
- --warn-all \
- --add-include-path=$(top_builddir)/gck \
- --add-include-path=$(top_builddir)/gcr \
- --include-uninstalled=$(top_builddir)/gck/Gck-@GCK_MAJOR@.gir \
- --include-uninstalled=$(top_builddir)/gcr/Gcr-@GCR_MAJOR@.gir \
- $(NULL)
-
-INTROSPECTION_COMPILER_ARGS = \
- --includedir=$(srcdir) \
- --includedir=$(top_builddir)/gck \
- --includedir=$(top_builddir)/gcr \
- $(NULL)
-
-GcrUi-@GCR_MAJOR@.gir: $(builddir)/libgcr-ui-@GCR_MAJOR@.la $(top_builddir)/gcr/Gcr-@GCR_MAJOR@.gir
+GcrUi-@GCR_MAJOR@.gir: libgcr-ui-@GCR_MAJOR@.la Gcr-@GCR_MAJOR@.gir
GcrUi_@GCR_MAJOR@_gir_PACKAGES = gtk+-3.0 p11-kit-1
GcrUi_@GCR_MAJOR@_gir_EXPORT_PACKAGES = gcr-ui-@GCR_MAJOR@
GcrUi_@GCR_MAJOR@_gir_INCLUDES = GLib-2.0 GObject-2.0 Gtk-3.0
-GcrUi_@GCR_MAJOR@_gir_LIBS = $(top_builddir)/gcr/libgcr-base-@GCR_MAJOR@.la libgcr-ui-@GCR_MAJOR@.la
-GcrUi_@GCR_MAJOR@_gir_CFLAGS = -I$(top_srcdir) -I$(top_builddir) -DGCR_COMPILATION -DGCR_API_SUBJECT_TO_CHANGE
-GcrUi_@GCR_MAJOR@_gir_FILES = $(PUBLIC_FILES)
-GcrUi_@GCR_MAJOR@_gir_SCANNERFLAGS = --c-include "ui/gcr-ui.h" \
- --identifier-prefix Gcr --symbol-prefix gcr \
- --include-uninstalled=$(top_builddir)/gcr/Gcr-@GCR_MAJOR@.gir
-
-girdir = $(datadir)/gir-1.0
-gir_DATA = $(INTROSPECTION_GIRS)
-
-typelibsdir = $(libdir)/girepository-1.0
-typelibs_DATA = $(INTROSPECTION_GIRS:.gir=.typelib)
+GcrUi_@GCR_MAJOR@_gir_LIBS = libgcr-base-@GCR_MAJOR@.la libgcr-ui-@GCR_MAJOR@.la
+GcrUi_@GCR_MAJOR@_gir_CFLAGS = -I$(srcdir) -I$(builddir) -DGCR_COMPILATION -DGCR_API_SUBJECT_TO_CHANGE
+GcrUi_@GCR_MAJOR@_gir_FILES = $(ui_PUBLIC_FILES)
+GcrUi_@GCR_MAJOR@_gir_SCANNERFLAGS = \
+ --add-include-path=$(builddir)/gck \
+ --add-include-path=$(builddir)/gcr \
+ --include-uninstalled=Gck-@GCK_MAJOR@.gir \
+ --include-uninstalled=Gcr-@GCR_MAJOR@.gir \
+ --c-include "ui/gcr-ui.h" \
+ --identifier-prefix Gcr --symbol-prefix gcr
+
+gir_DATA += GcrUi-@GCR_MAJOR@.gir
if ENABLE_VAPIGEN
-include $(VAPIGEN_MAKEFILE)
-gcr-ui-@GCR_MAJOR@.vapi: GcrUi-@GCR_MAJOR@.gir GcrUi-@GCR_MAJOR@.metadata gcr-ui-@GCR_MAJOR@.deps
+gcr-ui-@GCR_MAJOR@.vapi: GcrUi-@GCR_MAJOR@.gir ui/GcrUi-@GCR_MAJOR@.metadata gcr-ui-@GCR_MAJOR@.deps
-VAPIGEN_VAPIS = gcr-ui-@GCR_MAJOR@.vapi
+VAPIGEN_VAPIS += gcr-ui-@GCR_MAJOR@.vapi
gcr_ui_@GCR_MAJOR@_vapi_DEPS = glib-2.0 gio-2.0 gck-@GCK_MAJOR@ gcr-@GCR_MAJOR@ gtk+-3.0
gcr_ui_@GCR_MAJOR@_vapi_METADATADIRS = $(srcdir)
@@ -202,92 +170,80 @@ gcr_ui_@GCR_MAJOR@_vapi_VAPIDIRS = $(builddir) $(builddir)/../gck $(builddir)/..
gcr_ui_@GCR_MAJOR@_vapi_GIRDIRS = $(builddir) $(builddir)/../gck $(builddir)/../gcr
gcr_ui_@GCR_MAJOR@_vapi_FILES = GcrUi-@GCR_MAJOR@.gir
-VAPI_DEPS = $(VAPIGEN_VAPIS:.vapi=.deps)
-
gcr-ui-$(GCR_MAJOR).deps: Makefile.am
$(AM_V_GEN) echo $(gcr_ui_@GCR_MAJOR@_vapi_DEPS) | tr ' ' '\n' > $@
-vapidir = $(datadir)/vala/vapi
-vapi_DATA = \
- $(VAPIGEN_VAPIS) \
- $(VAPI_DEPS)
-
EXTRA_DIST += \
- GcrUi-@GCR_MAJOR@.metadata
-
-CLEANFILES += \
- $(VAPIGEN_VAPIS) \
- $(VAPI_DEPS)
+ ui/GcrUi-@GCR_MAJOR@.metadata
endif # ENABLE_VAPIGEN
endif # HAVE_INTROSPECTION
-pkgconfig_DATA = \
+pkgconfig_DATA += \
gcr-$(GCR_MAJOR).pc \
gcr-ui-$(GCR_MAJOR).pc
-gcr-ui-expected.abi: gcr-ui.symbols
+gcr-ui-expected.abi: ui/gcr-ui.symbols
$(AM_V_GEN) cpp -P $< | sort > $@
desktopdir = $(datadir)/applications
-desktop_in_in_files = gcr-viewer.desktop.in.in gcr-prompter.desktop.in.in
+desktop_in_in_files = ui/gcr-viewer.desktop.in.in ui/gcr-prompter.desktop.in.in
desktop_in_files = $(desktop_in_in_files:.desktop.in.in=.desktop.in)
desktop_DATA = $(desktop_in_files:.desktop.in=.desktop)
bin_PROGRAMS = gcr-viewer
gcr_viewer_SOURCES = \
- gcr-viewer-tool.c
+ ui/gcr-viewer-tool.c
gcr_viewer_CFLAGS = \
- $(GLIB_CFLAGS) \
+ $(P11_KIT_CFLAGS) \
$(GTK_CFLAGS) \
- -DLOCALEDIR=\""$(datadir)/locale"\" \
-DGCR_API_SUBJECT_TO_CHANGE
gcr_viewer_LDADD = \
- $(builddir)/libgcr-ui-$(GCR_MAJOR).la \
- $(top_builddir)/gcr/libgcr-base-$(GCR_MAJOR).la \
- $(top_builddir)/gck/libgck-@GCK_MAJOR@.la \
+ libgcr-ui-$(GCR_MAJOR).la \
+ libgcr-base-$(GCR_MAJOR).la \
+ libgck-@GCK_MAJOR@.la \
$(GLIB_LIBS) \
$(GTK_LIBS)
libexec_PROGRAMS = gcr-prompter
gcr_prompter_SOURCES = \
- gcr-prompter-tool.c
+ ui/gcr-prompter-tool.c
gcr_prompter_CFLAGS = \
+ -DGCR_API_SUBJECT_TO_CHANGE \
+ $(P11_KIT_CFLAGS) \
$(GTK_CFLAGS)
gcr_prompter_LDADD = \
- $(builddir)/libgcr-ui-$(GCR_MAJOR).la \
- $(top_builddir)/gcr/libgcr-base-$(GCR_MAJOR).la \
- $(top_builddir)/gck/libgck-@GCK_MAJOR@.la \
+ libgcr-ui-$(GCR_MAJOR).la \
+ libgcr-base-$(GCR_MAJOR).la \
+ libgck-@GCK_MAJOR@.la \
$(GTK_LIBS)
EXTRA_DIST += \
- gcr.pc.in \
- gcr-ui.pc.in \
+ ui/gcr.pc.in \
+ ui/gcr-ui.pc.in \
$(ui_DATA) \
- gcr-ui.symbols \
+ ui/gcr-ui.symbols \
$(desktop_in_in_files) \
- $(mime_DATA)
+ $(mime_DATA) \
+ ui/fixtures
CLEANFILES += \
$(desktop_DATA) \
gcr-ui-actual.abi \
gcr-ui-expected.abi \
- $(BUILT_SOURCES) \
- $(pkgconfig_DATA) \
- $(gir_DATA) \
- $(typelibs_DATA) \
+ $(desktop_in_files) \
$(NULL)
# The new mime system
mimedir = $(datadir)/mime/packages
-mime_DATA = gcr-crypto-types.xml
+mime_DATA = ui/gcr-crypto-types.xml
if WITH_UPDATE_MIME
@@ -307,6 +263,83 @@ update_mime_database:
endif # WITH_UPDATE_MIME
-gcr-ui-actual.abi: $(builddir)/.libs/libgcr-ui-@GCR_MAJOR@.so
+gcr-ui-actual.abi: .libs/libgcr-ui-@GCR_MAJOR@.so
$(AM_V_GEN) $(NM) -D -g --defined-only $< | \
cut -d ' ' -f 3 | grep -Ev '^(__bss_start|_edata|_end|_gcr_)' | sort > $@
+
+ui_CFLAGS = \
+ -DGCR_API_SUBJECT_TO_CHANGE \
+ -DGCK_API_SUBJECT_TO_CHANGE \
+ -DGCR_COMPILATION \
+ $(LIBGCRYPT_CFLAGS) \
+ $(P11_KIT_CFLAGS) \
+ $(GTK_CFLAGS)
+
+ui_LIBS = \
+ libgcr-ui-@GCR_MAJOR@.la \
+ libgcr-base-@GCR_MAJOR@.la \
+ libegg.la \
+ libgck-testable.la \
+ $(LIBGCRYPT_LIBS) \
+ $(P11_KIT_LIBS) \
+ $(GTK_LIBS)
+
+# ------------------------------------------------------------------
+
+noinst_PROGRAMS += \
+ frob-certificate \
+ frob-combo-selector \
+ frob-gnupg-selector \
+ frob-import-button \
+ frob-key \
+ frob-tree-selector \
+ frob-prompt \
+ frob-request \
+ frob-system-prompt \
+ frob-unlock \
+ frob-unlock-options
+
+frob_certificate_SOURCES = ui/frob-certificate.c
+frob_certificate_CFLAGS = $(ui_CFLAGS)
+frob_certificate_LDADD = $(ui_LIBS)
+
+frob_combo_selector_SOURCES = ui/frob-combo-selector.c
+frob_combo_selector_CFLAGS = $(ui_CFLAGS)
+frob_combo_selector_LDADD = $(ui_LIBS)
+
+frob_gnupg_selector_SOURCES = ui/frob-gnupg-selector.c
+frob_gnupg_selector_CFLAGS = $(ui_CFLAGS)
+frob_gnupg_selector_LDADD = $(ui_LIBS)
+
+frob_import_button_SOURCES = ui/frob-import-button.c
+frob_import_button_CFLAGS = $(ui_CFLAGS)
+frob_import_button_LDADD = $(ui_LIBS)
+
+frob_key_SOURCES = ui/frob-key.c
+frob_key_CFLAGS = $(ui_CFLAGS)
+frob_key_LDADD = $(ui_LIBS)
+
+frob_prompt_SOURCES = ui/frob-prompt.c
+frob_prompt_CFLAGS = $(ui_CFLAGS)
+frob_prompt_LDADD = $(ui_LIBS)
+
+frob_request_SOURCES = ui/frob-request.c
+frob_request_CFLAGS = $(ui_CFLAGS)
+frob_request_LDADD = $(ui_LIBS)
+
+frob_system_prompt_SOURCES = ui/frob-system-prompt.c
+frob_system_prompt_CFLAGS = $(ui_CFLAGS)
+frob_system_prompt_LDADD = $(ui_LIBS)
+
+frob_tree_selector_SOURCES = ui/frob-tree-selector.c
+frob_tree_selector_CFLAGS = $(ui_CFLAGS)
+frob_tree_selector_LDADD = $(ui_LIBS)
+
+frob_unlock_SOURCES = \
+ ui/frob-unlock.c ui/gcr-viewer-window.c
+frob_unlock_CFLAGS = $(ui_CFLAGS)
+frob_unlock_LDADD = $(ui_LIBS)
+
+frob_unlock_options_SOURCES = ui/frob-unlock-options.c
+frob_unlock_options_CFLAGS = $(ui_CFLAGS)
+frob_unlock_options_LDADD = $(ui_LIBS)
diff --git a/ui/tests/files/ca-certificates.crt b/ui/fixtures/ca-certificates.crt
index c30335f..c30335f 100644
--- a/ui/tests/files/ca-certificates.crt
+++ b/ui/fixtures/ca-certificates.crt
diff --git a/ui/tests/files/der-certificate.crt b/ui/fixtures/der-certificate.crt
index 56fa849..56fa849 100644
--- a/ui/tests/files/der-certificate.crt
+++ b/ui/fixtures/der-certificate.crt
Binary files differ
diff --git a/ui/tests/files/der-rsa-2048.p10 b/ui/fixtures/der-rsa-2048.p10
index 6355622..6355622 100644
--- a/ui/tests/files/der-rsa-2048.p10
+++ b/ui/fixtures/der-rsa-2048.p10
Binary files differ
diff --git a/ui/tests/files/email.p12 b/ui/fixtures/email.p12
index d45d0f8..d45d0f8 100644
--- a/ui/tests/files/email.p12
+++ b/ui/fixtures/email.p12
Binary files differ
diff --git a/ui/tests/files/pem-dsa-1024.key b/ui/fixtures/pem-dsa-1024.key
index ccb1e7b..ccb1e7b 100644
--- a/ui/tests/files/pem-dsa-1024.key
+++ b/ui/fixtures/pem-dsa-1024.key
diff --git a/ui/tests/frob-certificate.c b/ui/frob-certificate.c
index df4495b..f9cc259 100644
--- a/ui/tests/frob-certificate.c
+++ b/ui/frob-certificate.c
@@ -106,7 +106,7 @@ main(int argc, char *argv[])
if (argc > 1)
test_certificate (argv[1]);
else
- test_certificate (SRCDIR "/files/der-certificate.crt");
+ test_certificate (SRCDIR "/ui/fixtures/der-certificate.crt");
return 0;
}
diff --git a/ui/tests/frob-combo-selector.c b/ui/frob-combo-selector.c
index 856d09a..8263b94 100644
--- a/ui/tests/frob-combo-selector.c
+++ b/ui/frob-combo-selector.c
@@ -70,7 +70,7 @@ main (int argc, char *argv[])
g_signal_connect (parser, "parsed", G_CALLBACK (on_parser_parsed), collection);
if (argc == 1) {
- add_to_selector (parser, SRCDIR "/files/ca-certificates.crt");
+ add_to_selector (parser, SRCDIR "/ui/fixtures/ca-certificates.crt");
} else {
for (i = 1; i < argc; ++i)
add_to_selector (parser, argv[i]);
diff --git a/ui/tests/frob-gnupg-selector.c b/ui/frob-gnupg-selector.c
index 41b1977..41b1977 100644
--- a/ui/tests/frob-gnupg-selector.c
+++ b/ui/frob-gnupg-selector.c
diff --git a/ui/tests/frob-import-button.c b/ui/frob-import-button.c
index d3ca560..6a9a88e 100644
--- a/ui/tests/frob-import-button.c
+++ b/ui/frob-import-button.c
@@ -234,7 +234,7 @@ main (int argc, char *argv[])
g_signal_connect (parser, "parsed", G_CALLBACK (on_parser_parsed), button);
if (argc == 1) {
- parse_file (parser, SRCDIR "/files/ca-certificates.crt");
+ parse_file (parser, SRCDIR "/ui/fixtures/ca-certificates.crt");
} else {
for (i = 1; i < argc; ++i)
parse_file (parser, argv[i]);
diff --git a/ui/tests/frob-key.c b/ui/frob-key.c
index 7b62f11..97d216b 100644
--- a/ui/tests/frob-key.c
+++ b/ui/frob-key.c
@@ -81,7 +81,7 @@ main(int argc, char *argv[])
if (argc > 1)
test_key (argv[1]);
else
- test_key (SRCDIR "/files/pem-dsa-1024.key");
+ test_key (SRCDIR "/ui/fixtures/pem-dsa-1024.key");
return 0;
}
diff --git a/ui/tests/frob-prompt.c b/ui/frob-prompt.c
index 20462f6..20462f6 100644
--- a/ui/tests/frob-prompt.c
+++ b/ui/frob-prompt.c
diff --git a/ui/tests/frob-request.c b/ui/frob-request.c
index c4b8d53..1d2f946 100644
--- a/ui/tests/frob-request.c
+++ b/ui/frob-request.c
@@ -91,7 +91,7 @@ main(int argc, char *argv[])
if (argc > 1)
test_request (argv[1]);
else
- test_request (SRCDIR "/files/der-rsa-2048.p10");
+ test_request (SRCDIR "/ui/fixtures/der-rsa-2048.p10");
return 0;
}
diff --git a/ui/tests/frob-system-prompt.c b/ui/frob-system-prompt.c
index e08114f..e08114f 100644
--- a/ui/tests/frob-system-prompt.c
+++ b/ui/frob-system-prompt.c
diff --git a/ui/tests/frob-tree-selector.c b/ui/frob-tree-selector.c
index ecf87d3..f3b3187 100644
--- a/ui/tests/frob-tree-selector.c
+++ b/ui/frob-tree-selector.c
@@ -183,7 +183,7 @@ main (int argc, char *argv[])
g_signal_connect (parser, "parsed", G_CALLBACK (on_parser_parsed), collection);
if (argc == 1) {
- add_to_selector (parser, SRCDIR "/files/ca-certificates.crt");
+ add_to_selector (parser, SRCDIR "/ui/fixtures/ca-certificates.crt");
} else {
for (i = 1; i < argc; ++i)
add_to_selector (parser, argv[i]);
diff --git a/ui/tests/frob-unlock-options.c b/ui/frob-unlock-options.c
index b9e5b09..b9e5b09 100644
--- a/ui/tests/frob-unlock-options.c
+++ b/ui/frob-unlock-options.c
diff --git a/ui/tests/frob-unlock.c b/ui/frob-unlock.c
index 567b0b2..4919765 100644
--- a/ui/tests/frob-unlock.c
+++ b/ui/frob-unlock.c
@@ -116,7 +116,7 @@ main(int argc, char *argv[])
if (argc > 1) {
test_key (argv[1]);
} else {
- test_key (SRCDIR "/files/email.p12");
+ test_key (SRCDIR "/ui/fixtures/email.p12");
}
return 0;
diff --git a/ui/gcr-collection-model.c b/ui/gcr-collection-model.c
index 6e8db6c..d4f7c10 100644
--- a/ui/gcr-collection-model.c
+++ b/ui/gcr-collection-model.c
@@ -23,7 +23,8 @@
#include "config.h"
#include "gcr-collection-model.h"
-#include "gcr-enum-types.h"
+
+#include "ui/gcr-enum-types.h"
#include <gtk/gtk.h>
diff --git a/ui/gcr-live-search.c b/ui/gcr-live-search.c
index fe8c371..f8483bf 100644
--- a/ui/gcr-live-search.c
+++ b/ui/gcr-live-search.c
@@ -27,10 +27,10 @@
#include "config.h"
-#include "gcr/gcr-marshal.h"
-
#include "gcr-live-search.h"
+#include "gcr/gcr-marshal.h"
+
#include <gtk/gtk.h>
#include <gdk/gdkkeysyms.h>
diff --git a/ui/gcr-ui.h b/ui/gcr-ui.h
index 193398a..cbec5b3 100644
--- a/ui/gcr-ui.h
+++ b/ui/gcr-ui.h
@@ -37,9 +37,9 @@
#include <ui/gcr-collection-model.h>
#include <ui/gcr-combo-selector.h>
#include <ui/gcr-deprecated.h>
+#include <ui/gcr-enum-types.h>
#include <ui/gcr-key-renderer.h>
#include <ui/gcr-key-widget.h>
-#include <ui/gcr-enum-types.h>
#include <ui/gcr-failure-renderer.h>
#include <ui/gcr-key-renderer.h>
#include <ui/gcr-key-widget.h>
diff --git a/ui/icons/Makefile.am b/ui/icons/Makefile.am
index 65da739..ef5c81e 100644
--- a/ui/icons/Makefile.am
+++ b/ui/icons/Makefile.am
@@ -1,15 +1,15 @@
-SUBDIRS = \
- 16x16 \
- 22x22 \
- 24x24 \
- 32x32 \
- 48x48 \
- 256x256
+SUBDIRS += \
+ ui/icons/16x16 \
+ ui/icons/22x22 \
+ ui/icons/24x24 \
+ ui/icons/32x32 \
+ ui/icons/48x48 \
+ ui/icons/256x256
-EXTRA_DIST = \
- src \
- render-icons.py
+EXTRA_DIST += \
+ ui/icons/src \
+ ui/icons/render-icons.py
if WITH_UPDATE_ICON_CACHE
@@ -26,4 +26,4 @@ install-data-hook:
endif
render:
- python render-icons.py
+ python ui/icons/render-icons.py
diff --git a/ui/tests/Makefile.am b/ui/tests/Makefile.am
deleted file mode 100644
index 287b9dc..0000000
--- a/ui/tests/Makefile.am
+++ /dev/null
@@ -1,42 +0,0 @@
-include $(top_srcdir)/Makefile.decl
-
-AM_CPPFLAGS = \
- -I$(top_builddir) \
- -I$(top_srcdir) \
- -DSRCDIR="\"@abs_srcdir@\"" \
- -DGCR_API_SUBJECT_TO_CHANGE \
- -DGCK_API_SUBJECT_TO_CHANGE \
- -DGCR_COMPILATION \
- $(GLIB_CFLAGS) \
- $(LIBGCRYPT_CFLAGS) \
- $(P11_KIT_CFLAGS) \
- $(GTK_CFLAGS)
-
-LDADD = \
- $(top_builddir)/ui/libgcr-ui-@GCR_MAJOR@.la \
- $(top_builddir)/gcr/libgcr-base-@GCR_MAJOR@.la \
- $(top_builddir)/egg/libegg.la \
- $(top_builddir)/gck/libgck-testable.la \
- $(GLIB_LIBS) \
- $(LIBGCRYPT_LIBS) \
- $(P11_KIT_LIBS) \
- $(GTK_LIBS)
-
-# ------------------------------------------------------------------
-
-noinst_PROGRAMS = \
- frob-certificate \
- frob-combo-selector \
- frob-gnupg-selector \
- frob-import-button \
- frob-key \
- frob-tree-selector \
- frob-prompt \
- frob-request \
- frob-system-prompt \
- frob-unlock \
- frob-unlock-options
-
-frob_unlock_SOURCES = \
- frob-unlock.c \
- ../gcr-viewer-window.c