unofficial mirror of guix-devel@gnu.org 
 help / color / mirror / code / Atom feed
From: Pronaip <pronaip@protonmail.com>
To: "guix-devel@gnu.org" <guix-devel@gnu.org>
Subject: Mixing build systems
Date: Wed, 01 May 2019 19:53:21 +0000	[thread overview]
Message-ID: <sR133aesLa99N9oYxc6XLzpWsD3-CXgCBTpfXFrAqCZxTJKHfllMO5XfkWoOjHxk10nQnM53Fa1cpo1JhITai9uSl05GknrxMhkfsYtt_JE=@protonmail.com> (raw)

[-- Attachment #1: Type: text/plain, Size: 474 bytes --]

Hi, I'm (still) trying to build Mininet and it uses both a Makefile for building an C executable and setup.py to install its Python modules. I looked at the soundconverter package to get some hints for mixing build systems but couldn't get very far, I get all sorts of (mostly cryptic) error messages, usually about missing modules.
What should I do? I'm pretty new to Guile and Guix but I've packaged software for the AUR before.

I attached the code I currently have.

[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #2: mininet.scm --]
[-- Type: text/x-scheme; name="mininet.scm", Size: 2668 bytes --]

(define-module (raingloom packages mininet)
  #:use-module (gnu packages networking)
  #:use-module (gnu packages admin)
  #:use-module (gnu packages python)
  #:use-module (gnu packages python-xyz)
  #:use-module (gnu packages linux)
  #:use-module (gnu packages man)
  #:use-module (gnu packages bash)
  #:use-module (gnu packages gcc)
  #:use-module (gnu packages)
  #:use-module (guix packages)
  #:use-module (guix git-download)
  #:use-module (guix build-system gnu)
  #:use-module (guix build-system python)
  #:use-module (guix licenses))

(define-public mininet
  (package
   (name "mininet")
   (version "2.2.2")
   (source (origin
            (method git-fetch)
            (uri (git-reference
		  (url "git://github.com/mininet/mininet.git")
		  (commit version)))
	    (sha256 (base32 "18w9vfszhnx4j3b8dd1rvrg8xnfk6rgh066hfpzspzqngd5qzakg"))
	    (file-name (git-file-name name version))
	    (modules '((guix build utils)))
	    (snippet
             '(begin
                (substitute* "Makefile"
			     (("cc")  "gcc")
			     (("BINDIR =") "BINDIR ?=")
			     (("MANDIR =") "MANDIR ?="))
                #t))))
   (build-system gnu-build-system)
   (arguments
    `(#:imported-modules
      ((guix build python-build-system)
       (guix build gnu-build-system))
      #:modules
      ((guix build utils)
       (guix build python-build-system) #:prefix python:
       (guix build gnu-build-system))
      #:phases
      (modify-phases %standard-phases
		     (delete 'configure)
		     (delete 'check)
		     (delete 'build)
		     ;(add-after 'unpack 'ensure-no-mtimes-pre-1980 ensure-no-mtimes-pre-1980)
		     ;(add-after 'ensure-no-mtimes-pre-1980 'enable-bytecode-determinism)
		     (add-before 'install 'create-dirs
				 (lambda _
				   (mkdir-p (string-append %output "/bin"))
			     	   (mkdir-p (string-append %output "/share/man/man1"))))) ;why does build run test???
    #:make-flags
    (list (string-append "MANDIR=" %output "/bin")
	  (string-append "BINDIR=" %output "/share/man/man1"))))
   (inputs
    `(("openvswitch" ,openvswitch)
      ("python2" ,python-2.7)
      ("python2-pyflakes" ,python2-pyflakes)
      ("ethtool" ,ethtool)
      ("inetutils" ,inetutils)
      ("net-tools" ,net-tools)
      ("psmisc" ,psmisc)
      ("libcgroup" ,libcgroup)
      ("iproute2" ,iproute)
      ("iperf" ,iperf)
      ("bash" ,bash)))
   (native-inputs
    `(("gcc" ,gcc)
      ("help2man" ,help2man)))
   (synopsis "Rapid Prototyping for Software Defined Networks")
   (description "Mininet emulates a complete network of hosts, links, and switches on a single machine.")
   (home-page "http://mininet.org/")
   (license bsd-style)))

             reply	other threads:[~2019-05-01 19:53 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2019-05-01 19:53 Pronaip [this message]
2019-05-03  5:26 ` Mixing build systems Ricardo Wurmus

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

  List information: https://guix.gnu.org/

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to='sR133aesLa99N9oYxc6XLzpWsD3-CXgCBTpfXFrAqCZxTJKHfllMO5XfkWoOjHxk10nQnM53Fa1cpo1JhITai9uSl05GknrxMhkfsYtt_JE=@protonmail.com' \
    --to=pronaip@protonmail.com \
    --cc=guix-devel@gnu.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
Code repositories for project(s) associated with this public inbox

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

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).