all messages for Guix-related lists mirrored at yhetil.org
 help / color / mirror / code / Atom feed
* Building Go package - GNU or  Go build system
@ 2021-05-08 11:29 phodina via
  0 siblings, 0 replies; only message in thread
From: phodina via @ 2021-05-08 11:29 UTC (permalink / raw)
  To: help-guix@gnu.org

I'm trying to package sbctl - secureboot manager written in Golang. However, the repository contains a Makefile to simplify the process which works great without packaging.

Firstly, I'd like to ask about the opinion on building the programs that use Makefiles just to invoke the language builder e.g. go, rust... Is it better to skip Makefile and run the go or cargo build-system instead or just follow the instructions and invoke the Makefile itself and deal with the underlying build tools?

Secondly, as I attempt to package it I run into the trouble that go wants to create a cache outside of the out directory.
Could you please help me with the definition of GOCACHE?

;;; GNU Guix --- Functional package management for GNU

;;; Copyright © 2021 Petr Hodina <
phodina@protonmail.com
>

;;;

;;; This file is part of GNU Guix.

;;;

;;; GNU Guix is free software; you can redistribute it and/or modify it

;;; under the terms of the GNU General Public License as published by

;;; the Free Software Foundation; either version 3 of the License, or (at

;;; your option) any later version.

;;;

;;; GNU Guix 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 General Public License for more details.

;;;

;;; You should have received a copy of the GNU General Public License

;;; along with GNU Guix.  If not, see <
http://www.gnu.org/licenses/
>.

(

define-module

(

expanse

packages

sbctl

)

#

:use-module

(

guix

packages

)

#

:use-module

(

gnu

packages

documentation

)

#

:use-module

(

gnu

packages

golang

)

#

:use-module

(

guix

git-download

)

#

:use-module

(

guix

build-system

gnu

)

#

:use-module

(

guix

licenses

))

(

define-public

sbctl

(

package

(

name

"sbctl"

)

(

version

"master"

)

(

source

(

origin

(

method

git-fetch

)

(

uri

(

git-reference

(

url

"
https://github.com/Foxboron/sbctl
"

)

(

commit

version

)))

(

sha256

(

base32

"1ilrq3ldclr2b8ch8w59y9pdncnjwqbgglvbcf6qzbgqzkn9ad7q"

))))

(

build-system

gnu-build-system

)

(

native-inputs

`

((

"asciidoc"

,

asciidoc

)

(

"go"

,

go

)))

(

inputs

`

((

"go"

,

go

)))

(

arguments

'

(

#

:phases

(

modify-phases

%standard-phases

(

delete

'configure

)

(

replace

'install

(

lambda*

(

#

:key

outputs

#

:allow-other-keys

)

(

let

((

bin

(

string-append

(

assoc-ref

outputs

"out"

)

"/bin"

)))

(

install-file

"sbctl"

bin

)

#t

))))))

(

synopsis

"Secure Boot Manager"

)

(

description

""

)

(

home-page

"
https://github.com/Foxboron/sbctl
"

)

(

license

#f

)))

Sent with [ProtonMail](https://protonmail.com/) Secure Email.

^ permalink raw reply	[flat|nested] only message in thread

only message in thread, other threads:[~2021-05-08 21:50 UTC | newest]

Thread overview: (only message) (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2021-05-08 11:29 Building Go package - GNU or Go build system phodina via

Code repositories for project(s) associated with this external index

	https://git.savannah.gnu.org/cgit/guix.git

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.