Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 389055 - app-admin/gpw - Trigraph Password Generator
Summary: app-admin/gpw - Trigraph Password Generator
Status: UNCONFIRMED
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: New packages (show other bugs)
Hardware: All All
: Normal enhancement
Assignee: Default Assignee for New Packages
URL: http://www.multicians.org/thvv/tvvtoo...
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2011-10-31 04:26 UTC by Philipp Psurek
Modified: 2011-11-13 06:59 UTC (History)
1 user (show)

See Also:
Package list:
Runtime testing required: ---


Attachments
gpw-0.0.19940601.ebuild (gpw-0.0.19940601.ebuild,1.89 KB, text/plain)
2011-10-31 04:27 UTC, Philipp Psurek
Details
metadata (metadata.xml,761 bytes, text/plain)
2011-10-31 04:28 UTC, Philipp Psurek
Details
ChangeLog (ChangeLog,552 bytes, text/plain)
2011-10-31 04:29 UTC, Philipp Psurek
Details
the digest data, if needed (Manifest,985 bytes, text/plain)
2011-10-31 04:32 UTC, Philipp Psurek
Details
gpw-0.0.19940601.ebuild (gpw-0.0.19940601.ebuild,2.03 KB, text/plain)
2011-10-31 07:59 UTC, Philipp Psurek
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Philipp Psurek 2011-10-31 04:26:14 UTC
Please include this ebuild in the portage tree

Reproducible: Always

Steps to Reproduce:
1. load the files
2. emerge
3. enjoy
Actual Results:  
this ebuild compiles fine on x86

Expected Results:  
it will compile everywhere without bugs ;–)

After 1,5 years of Gentoo abstinence I will use it again. Due to my residence on Ubuntu I miss this little helper on Gentoo now. This is my 2nd ebuild and the first new one. Please inform me what did I do wrong and I try to correct this.

This program is very old, there is not much to maintain. If you like I'll maintain this ebuild. Due to I don't speak C it will be a challenge.
Comment 1 Philipp Psurek 2011-10-31 04:27:39 UTC
Created attachment 291327 [details]
gpw-0.0.19940601.ebuild
Comment 2 Philipp Psurek 2011-10-31 04:28:11 UTC
Created attachment 291329 [details]
metadata
Comment 3 Philipp Psurek 2011-10-31 04:29:46 UTC
Created attachment 291331 [details]
ChangeLog
Comment 4 Philipp Psurek 2011-10-31 04:32:12 UTC
Created attachment 291333 [details]
the digest data, if needed
Comment 5 Philipp Psurek 2011-10-31 07:53:38 UTC
Comment on attachment 291327 [details]
gpw-0.0.19940601.ebuild

# Copyright 1999-2011 Gentoo Foundation
# Distributed under the terms of the GNU General Public License v2
# $Header: $

EAPI="2"

inherit eutils

DESCRIPTION="Trigraph Password Generator"
HOMEPAGE="http://www.multicians.org/thvv/tvvtools.html#gpw"
# original files on autor's homepage, but debian sources are packed and provide
# a man page
#SRC_URI="ftp://ftp.multicians.org/gpw.C
#	ftp://ftp.multicians.org/loadtris.C
#	ftp://ftp.multicians.org/gpw.Makefile"

# wordfile taken from sys-apps/miscfiles which is not needed at runtime
MISCFILES_PV=1.4.2
SRC_URI="ftp://ftp.de.debian.org/debian/pool/main/g/gpw/gpw_0.0.19940601.orig.tar.gz
	ftp://ftp.de.debian.org/debian/pool/main/g/gpw/gpw_0.0.19940601-8.1.diff.gz
	mirror://gnu/miscfiles/miscfiles-${MISCFILES_PV}.tar.gz"

LICENSE="as-is"
SLOT="0"
KEYWORDS="~alpha ~amd64 ~arm ~hppa ~ia64 ~m68k ~mips ~ppc ~ppc64 ~s390 ~sh ~sparc ~x86 ~sparc-fbsd ~x86-fbsd ~x86-interix ~amd64-linux ~x86-linux ~ppc-macos ~x64-macos ~x86-macos ~m68k-mint ~sparc-solaris ~sparc64-solaris ~x86-solaris"

src_prepare() {
	cd ${S}
	epatch "${WORKDIR}/gpw_0.0.19940601-8.1.diff"
}

src_compile() {
    $(tc-getCC) ${CFLAGS} -W -Wall -pedantic -o loadtris.o -c loadtris.c || die 
    $(tc-getCC) ${CFLAGS} -W -Wall -pedantic -o loadtris loadtris.o || die 

	./loadtris "${WORKDIR}/miscfiles-${MISCFILES_PV}/web2" | sed "s/, }/}/" > trigram.h.wait \
		 || die "Failed to generate trigram.h"

	# this patch provides a workaround for this warning while compiling gpw
	# trigram.h:5:1:
	# trigram.h:11:1:
	# trigram.h:15:1: warning: overflow in implicit constant conversion
	sed -e "s/const short sing/const long sing/g" \
		-e "s/const short duos/const long duos/g" \
		trigram.h.wait > trigram.h \
		 || die "Failed to patch trigram.h"

    $(tc-getCC) ${CFLAGS} -W -Wall -pedantic -o gpw.o -c gpw.c || die
    $(tc-getCC) ${CFLAGS} -W -Wall -pedantic -o gpw gpw.o || \
		die "Died compiling gpw"
}

src_install() {
	dobin gpw || die
	doman debian/gpw.1 || die
	dodoc README || die
	dodoc LICENSE || die
	newdoc debian/changelog changelog.Debian || die
}
Comment 6 Philipp Psurek 2011-10-31 07:56:17 UTC
Comment on attachment 291327 [details]
gpw-0.0.19940601.ebuild

# Copyright 1999-2011 Gentoo Foundation
# Distributed under the terms of the GNU General Public License v2
# $Header: $

EAPI="2"

inherit eutils

DESCRIPTION="Trigraph Password Generator"
HOMEPAGE="http://www.multicians.org/thvv/tvvtools.html#gpw"
# original files on autor's homepage, but debian sources are packed and provide
# a man page
#SRC_URI="ftp://ftp.multicians.org/gpw.C
#	ftp://ftp.multicians.org/loadtris.C
#	ftp://ftp.multicians.org/gpw.Makefile"

# wordfile taken from sys-apps/miscfiles which is not needed at runtime
MISCFILES_PV=1.4.2
SRC_URI="ftp://ftp.de.debian.org/debian/pool/main/g/gpw/gpw_0.0.19940601.orig.tar.gz
	ftp://ftp.de.debian.org/debian/pool/main/g/gpw/gpw_0.0.19940601-8.1.diff.gz
	mirror://gnu/miscfiles/miscfiles-${MISCFILES_PV}.tar.gz"

LICENSE="as-is"
SLOT="0"
KEYWORDS="~alpha ~amd64 ~arm ~hppa ~ia64 ~m68k ~mips ~ppc ~ppc64 ~s390 ~sh ~sparc ~x86 ~sparc-fbsd ~x86-fbsd ~x86-interix ~amd64-linux ~x86-linux ~ppc-macos ~x64-macos ~x86-macos ~m68k-mint ~sparc-solaris ~sparc64-solaris ~x86-solaris"

src_prepare() {
	cd ${S}
	epatch "${WORKDIR}/gpw_0.0.19940601-8.1.diff"
}

src_compile() {
    $(tc-getCC) ${CFLAGS} -W -Wall -pedantic -o loadtris.o -c loadtris.c || die 
    $(tc-getCC) ${CFLAGS} -W -Wall -pedantic -o loadtris loadtris.o || die 

	./loadtris "${WORKDIR}/miscfiles-${MISCFILES_PV}/web2" | sed "s/, }/}/" > trigram.h.wait \
		 || die "Failed to generate trigram.h"

	# this patch provides a workaround for this warning while compiling gpw
	# trigram.h:5:1:
	# trigram.h:11:1:
	# trigram.h:15:1: warning: overflow in implicit constant conversion
	sed -e "s/const short sing/const long sing/g" \
		-e "s/const short duos/const long duos/g" \
		trigram.h.wait > trigram.h \
		 || die "Failed to patch trigram.h"

    $(tc-getCC) ${CFLAGS} -W -Wall -pedantic -o gpw.o -c gpw.c || die
    $(tc-getCC) ${CFLAGS} -W -Wall -pedantic -o gpw gpw.o || \
		die "Died compiling gpw"
}

src_install() {
	dobin gpw || die
	doman debian/gpw.1 || die
	dodoc README || die
	dodoc LICENSE || die
	newdoc debian/changelog changelog.Debian || die
}
Comment 7 Philipp Psurek 2011-10-31 07:59:55 UTC
Created attachment 291335 [details]
gpw-0.0.19940601.ebuild

gpw-0.0.19940601.ebuild
don't need the wordfile from sys-apps/miscfiles at runtime