Pygame seems popular, it was also on my backburner list todo. In the AUR¹
there's acutally a package for 1.9.2pre20141217-1, which doesn't have a
dependancy on smpeg. When I tried building pygame with smpeg pygame
couldn't find it, and I also ran into problems with the sdl inputs.


¹ https://aur.archlinux.org/packages/python-pygame/

On Fri, Jul 22, 2016 at 03:41:08PM -0400, Kei Kebreau wrote:
> Kei Kebreau <k...@openmailbox.org> writes:
> 
> > This is a preliminary patch for pygame. I don't really have a test case
> > for it outside of (hopefully) a successful build of pygame. We'll see
> > how it goes.
> 
> Pygame's config.py is not finding smpeg-config. This will be fun! Anyone
> with skill in Python is welcome to offer me assistance!
> 
> -- 
> Kei (GPG Key: 4096R/E6A5EE3C19467A0D)



-- 
Efraim Flashner   <efr...@flashner.co.il>   אפרים פלשנר
GPG key = A28B F40C 3E55 1372 662D  14F7 41AA E7DC CA3D 8351
Confidentiality cannot be guaranteed on emails sent or received unencrypted
;;; Copyright © 2016 Efraim Flashner <efr...@flashner.co.il>
;;;
;;; This file is an addendum to 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 (wip bambam)
  #:use-module ((guix licenses) #:prefix license:)
  #:use-module (guix download)
  #:use-module (guix packages)
  #:use-module (guix build-system gnu)
  #:use-module (guix build-system python)
  #:use-module (gnu packages)
  #:use-module (gnu packages fontutils)
  #:use-module (gnu packages image)
  #:use-module (gnu packages music)
  #:use-module (gnu packages python)
  #:use-module (gnu packages sdl))

(define-public smpeg
  (package
    (name "smpeg")
    (version "0.4.5+cvs20030824")
    (source
      (origin
        (method url-fetch)
        (uri (string-append "mirror://debian/pool/main/s/smpeg/"
                            "smpeg_" version ".orig.tar.gz"))
        ;; Unfortunately the svn-fetch method does not work with this repo
        ;(method svn-fetch)
        ;(uri (svn-reference
        ;       (url "https://svn.icculus.org/smpeg/";)
        ;       (revision 408)))
        (sha256
         (base32
           "05hrprv8h0bw8xxzraccq922b4jk04c3zwyk5nhyizfrgmwylxhj"))))
        ;  "0cyl0ww4fjlf289pjxa53q4klyn55ajvkgymw0qrdgp4593raq52"))
        ;(file-name (string-append name "-" version "-checkout"))))
    (build-system gnu-build-system)
    (inputs
     `(("sdl" ,sdl)
       ("sdl-mixer" ,sdl-mixer)))
    (home-page "https://icculus.org/smpeg/";)
    (synopsis "SDL MPEG Player Library")
    (description "SMPEG (SDL MPEG Player Library) is a free MPEG1 video player
library with sound support.  Video playback is based on the ubiquitous Berkeley
MPEG player, mpeg_play v2.2.  Audio is played through a slightly modified
mpegsound library, part of splay v0.8.2.  SMPEG supports MPEG audio (MP3),
MPEG-1 video, and MPEG system streams.")
    (license #f)))

(define-public python2-pygame
  (package
    (name "python2-pygame")
    (version "1.9.1")
    (source
      (origin
        (method url-fetch)
        (uri (string-append "http://pygame.org/ftp/pygame-";
                            version "release.tar.gz"))
        (sha256
         (base32
          "0cyl0ww4fjlf289pjxa53q4klyn55ajvkgymw0qrdgp4593raq52"))))
    (build-system python-build-system)
    (arguments
     `(#:python ,python-2
       #:phases
       (modify-phases %standard-phases
         (add-after 'unpack 'apply-v4l-patch
           (lambda _
             (zero? (system* "patch" "--force" "-p1" "-i"
                             (assoc-ref %build-inputs "patch")))))
         (add-after 'unpack 'patch-config
           (lambda _
             (substitute* '("config_unix.py"
                            "config_msys.py")
                          (("not confirm")
                           "\"-auto\" not in sys.argv and not confirm"))
             #t))
         (add-before 'build 'config
           (lambda _
             (zero?
               (system* "python2" "config.py" "-auto")))))))
    (inputs
     `(
       ;("freetype" ,freetype)
       ;("libjpeg" ,libjpeg)
       ;("libpng" ,libpng)
       ;("python2-numpy" ,python2-numpy)
       ;("sdl" ,sdl)
       ("portmidi" ,portmidi)
       ("sdl-image" ,sdl-image)
       ("sdl-mixer" ,sdl-mixer)
       ("sdl-ttf" ,sdl-ttf)
       ;("smpeg" ,smpeg)
       ))
    ;(native-inputs
    ; `("patch" ,@("/home/efraim/workspace/my-guix/patches/pygame-v4l.patch")))
    (home-page "http://www.pygame.org/";)
    (synopsis "SDL bindings for games development in Python")
    (description "A multimedia development kit for Python.  Pygame provides
modules for you to access the video display, play sounds, track time, read the
mouse and joystick, control the CD player, render true type fonts and more.  It
does this using mainly the cross-platform SDL library, a lightweight wrapper to
OS-specific APIs.")
    (license (list license:lgpl2.1
                   license:public-domain)))) ; programs in example directory

Attachment: signature.asc
Description: PGP signature

Reply via email to