Hello,
I'm posting this directly here as account creation is disabled on
dev.gnupg.org.
In Debian we like to have a manpage for every binary in $PATH, so we
wrote one
for gpgme-json. I don't know if you are interested by having it
upstream,
but here it is in attachement.
best regards,
Sébastien
diff --git a/configure.ac b/configure.ac
index c0f136e7..f64f252d 100644
--- a/configure.ac
+++ b/configure.ac
@@ -104,6 +104,8 @@ AC_CANONICAL_HOST
AM_SILENT_RULES
AC_ARG_VAR(SYSROOT,[locate config scripts also below that directory])
+AC_PATH_PROG(YAT2M, [yat2m], [:])
+
# Enable GNU extensions on systems that have them.
AC_USE_SYSTEM_EXTENSIONS
diff --git a/doc/Makefile.am b/doc/Makefile.am
index f722980f..9c2dff81 100644
--- a/doc/Makefile.am
+++ b/doc/Makefile.am
@@ -28,6 +28,12 @@ EXTRA_DIST = module-overview.sk HACKING DCO ChangeLog-2011 \
BUILT_SOURCES = defsincdate defs.inc
+YAT2M_OPTIONS = -I $(srcdir) --release "GPGME @PACKAGE_VERSION@"
+
+myman_sources = gpgme-json.texi
+myman_pages = gpgme-json.1
+
+man_MANS = $(myman_pages)
info_TEXINFOS = gpgme.texi
gpgme_TEXINFOS = uiserver.texi lesser.texi gpl.texi
@@ -38,6 +44,29 @@ mkdefsinc: mkdefsinc.c Makefile $(top_builddir)/conf/config.h
$(CC_FOR_BUILD) -I. -I$(top_builddir)/conf -I$(srcdir) \
$(AM_CPPFLAGS) -o $@ $(srcdir)/mkdefsinc.c
+yat2m-stamp: $(myman_sources) defs.inc
+ @rm -f yat2m-stamp.tmp
+ @touch yat2m-stamp.tmp
+ incd="`test -f defsincdate || echo '$(srcdir)/'`defsincdate"; \
+ for file in $(myman_sources) ; do \
+ $(YAT2M) $(YAT2M_OPTIONS) --store \
+ --date "`cat $$incd 2>/dev/null`" \
+ `test -f '$$file' || echo '$(srcdir)/'`$$file ; done
+ @mv -f yat2m-stamp.tmp $@
+
+$(myman_pages) : yat2m-stamp defs.inc
+ @if test -f $@; then :; else \
+ trap 'rm -rf yat2m-stamp yat2m-lock' 1 2 13 15; \
+ if mkdir yat2m-lock 2>/dev/null; then \
+ rm -f yat2m-stamp; \
+ $(MAKE) $(AM_MAKEFLAGS) yat2m-stamp; \
+ rmdir yat2m-lock; \
+ else \
+ while test -d yat2m-lock; do sleep 1; done; \
+ test -f yat2m-stamp; exit $$?; \
+ fi; \
+ fi
+
dist-hook: defsincdate
defsincdate: $(gpgme_TEXINFOS)
@include defs.inc
@manpage gpgme-json.1
@ifset manverb
.B gpgme-json
\- Native messaging based GPGME operations
@end ifset
@mansect synopsis
@ifset manverb
.B gpgme-json
.RB [ \-\-interactive | \-i ]
.RB [ \-\-single | \-s ]
.RB [ \-\-identify
.IR file ]
.RB [ \-\-lib\-version ]
.RB [ \-\-help | \-h ]
@end ifset
@mansect description
@command{gpgme-json} is a JSON to GPGME bridge.
This interface allows web-browser extensions to communicate with the
GPGME library through the Native Messaging facility from web-browser.
@mansect options
@command{gpgme-json} accepts the following options on the command line:
@item -i
@itemx --interactive
@opindex interactive
Enable interactive mode
@item -s
@itemx --single
@opindex single
Enable single request mode
@item --identify @var{file|-}
@opindex identify
Identify the type of the data found in @file{file} or standard input @var{-}.
@item --debug
@opindex single
Enable debug mode. Logs are saved to to @file{~/.gnupg/S.gpgme-json.log}.
Note that you can also turn debug mode on and specify a custom logfile using
the environment variable @code{GPGME_JSON_DEBUG}.
@item --lib-version
@opindex version
Print GPGME library version.
@item -h
@itemx --help
@opindex help
Print a usage message summarizing the most useful command-line options.
@mansect bugs
Please report bugs to <https://bugs.gnupg.org>.
@mansect copyright
@command{gpgme-json} is Copyright 2018-2024 g10 Code GmbH.
LGPL version 2.1 or later <https://www.gnu.org/licenses/>
This is free software: you are free to change and redistribute it.
There is NO WARRANTY, to the extent permitted by law.
_______________________________________________
Gnupg-devel mailing list
[email protected]
https://lists.gnupg.org/mailman/listinfo/gnupg-devel