diff options
author | Ronny (tastytea) Gutbrod <gentoo@tastytea.de> | 2022-03-21 15:44:40 +0100 |
---|---|---|
committer | Joonas Niilola <juippis@gentoo.org> | 2022-03-26 15:34:59 +0200 |
commit | cf229d1f4cce78e372c9eefb7c2eb220d3823098 (patch) | |
tree | af55d7c54d97ec7f17eac22496697f19f6a53001 /www-apps | |
parent | www-apps/hugo: update DESCRIPTION (diff) | |
download | gentoo-cf229d1f4cce78e372c9eefb7c2eb220d3823098.tar.gz gentoo-cf229d1f4cce78e372c9eefb7c2eb220d3823098.tar.bz2 gentoo-cf229d1f4cce78e372c9eefb7c2eb220d3823098.zip |
www-apps/hugo: add 0.95.0
Signed-off-by: Ronny (tastytea) Gutbrod <gentoo@tastytea.de>
Closes: https://github.com/gentoo/gentoo/pull/24696
Signed-off-by: Joonas Niilola <juippis@gentoo.org>
Diffstat (limited to 'www-apps')
-rw-r--r-- | www-apps/hugo/Manifest | 2 | ||||
-rw-r--r-- | www-apps/hugo/hugo-0.95.0.ebuild | 77 |
2 files changed, 79 insertions, 0 deletions
diff --git a/www-apps/hugo/Manifest b/www-apps/hugo/Manifest index 98fe7b7c6897..344172428384 100644 --- a/www-apps/hugo/Manifest +++ b/www-apps/hugo/Manifest @@ -1,2 +1,4 @@ DIST hugo-0.93.3-vendor.tar.xz 4828092 BLAKE2B 4df3e876ffcc71f4caa089512510bec47f9e3aa25240ed6cc9ed9e7faef7425b3f7bdd03293023f103a0b8927ecbdf7fe3d9f36f5a66db580dfc8f0ddb9dc310 SHA512 6c93a8435552553079e856f8a74eef76e23ab7343e6e65ac83f9f1675c5fe44547f5d3f700656c0e666bc668792be38e343cfaebbfb23b5ece28ddfa0896755c DIST hugo-0.93.3.tar.gz 27852078 BLAKE2B 8e21fcbacc55cb304314d24f7a1258c9192655cb603e33c2ac2cac5fcc21f83045c1fc3a3ee7bd227507fd08be54e15dcd9cc9629e320bae9b41f1c87d03e163 SHA512 c65cc776588604a6ca2fbe5c4081db252ec007311eae54ed81ea65e983f1787edf6e10774d8ace82284eb7c42f6cb70650135ec44b2ddc8994ed511ba2a7d55e +DIST hugo-0.95.0-vendor.tar.xz 4781084 BLAKE2B ead2d42b615fa838995853df38c304c63baccb109f32b5034449cb64c8edacb78e5fac615f2018e8d4acb693f83df0abaa73bc511f5ba31b3a30bdec476420b1 SHA512 941061396433a20b524694c8dd2838d84454fbee98c48aa2860881fd9b31b6d480d22f6fd54bd2e17f1f90b1c9e6c3c5813682131fd01c7d3eabc063dcbb01b2 +DIST hugo-0.95.0.tar.gz 27859168 BLAKE2B 3667ab14c19f586d0f45b76072786a49f2448367cdf4151df2b44a329a57047544dcbbe4db8774433cf2042024c17ccca3269f5eeb508392aed00d31955de55a SHA512 fbe43fc9698325c380d7e7499ee726aba448eebba087f7bdc7cdf14d01e0649869359c07fefaa9a0d9623c910523b82efc2a2b57e152d391443e2b890a29affb diff --git a/www-apps/hugo/hugo-0.95.0.ebuild b/www-apps/hugo/hugo-0.95.0.ebuild new file mode 100644 index 000000000000..c36eb6cf14c3 --- /dev/null +++ b/www-apps/hugo/hugo-0.95.0.ebuild @@ -0,0 +1,77 @@ +# Copyright 1999-2022 Gentoo Authors +# Distributed under the terms of the GNU General Public License v2 + +EAPI=8 + +inherit go-module bash-completion-r1 + +DESCRIPTION="Fast static HTML and CSS website generator" +HOMEPAGE="https://gohugo.io https://github.com/gohugoio/hugo" +SRC_URI=" + https://github.com/gohugoio/${PN}/archive/v${PV}.tar.gz -> ${P}.tar.gz + https://tastytea.de/files/${P}-vendor.tar.xz +" + +# NOTE: To create the vendor tarball, run: +# `go mod vendor && cd .. && tar -cJf ${P}-vendor.tar.xz ${P}/vendor` + +LICENSE="Apache-2.0 BSD BSD-2 MIT Unlicense" +SLOT="0" +KEYWORDS="~amd64 ~x86" +IUSE="doc +sass" + +BDEPEND=">=dev-lang/go-1.18" +RDEPEND=" + media-libs/libwebp + sass? ( dev-libs/libsass ) +" +DEPEND="${RDEPEND}" + +PATCHES=( "${FILESDIR}/${PN}-0.92.2-link-to-webp-and-sass.patch" ) + +src_configure() { + export CGO_ENABLED=1 + export CGO_CFLAGS="${CFLAGS}" + export CGO_CPPFLAGS="${CPPFLAGS} -DLIBWEBP_NO_SRC -DUSE_LIBSASS_SRC" + export CGO_CXXFLAGS="${CXXFLAGS}" + export CGO_LDFLAGS="${LDFLAGS}" + + default +} + +src_compile() { + mkdir -pv bin || die + local my_import_path="github.com/gohugoio/hugo/common" + local mybuildtags="-tags $(usev sass "extended,")nodeploy" + ego build -ldflags \ + "-X ${my_import_path}/hugo.buildDate=$(date --iso-8601=seconds) -X ${my_import_path}/hugo.vendorInfo=Gentoo" \ + ${mybuildtags} -o "${S}/bin/hugo" + + bin/hugo gen man --dir man || die + + mkdir -pv completions || die + bin/hugo completion bash > completions/hugo || die + bin/hugo completion fish > completions/hugo.fish || die + bin/hugo completion zsh > completions/_hugo || die + + if use doc ; then + bin/hugo gen doc --dir doc || die + fi +} + +src_install() { + dobin bin/* + doman man/* + + dobashcomp completions/${PN} + + insinto /usr/share/fish/vendor_completions.d + doins completions/${PN}.fish + + insinto /usr/share/zsh/site-functions + doins completions/_${PN} + + if use doc ; then + dodoc -r doc/* + fi +} |