Libmng

From CBLFS
Revision as of 00:19, 5 January 2007 by Kalessin (talk | contribs) (I added a new patch and updated the instructions to take advantage of it.)
Jump to navigationJump to search
Download Source: http://prdownloads.sourceforge.net/libmng/libmng-1.0.10.tar.gz
Download Patch: http://svn.cross-lfs.org/svn/repos/patches/libmng/libmng-1.0.10-libdir-1.patch

Introduction to libmng

The libmng libraries are used by programs wanting to read and write Multiple-image Network Graphics (MNG) files which are the animation equivalents to PNG files.

Dependencies

Required

Additional Configuration Options

Note to DESTDIR fans: You will need to alter the installation of the documentation to:

 install -dv -m755 <DESTDIR>/usr/share/man/man{3,5}
 install -v -m644 doc/man/*.3 <DESTDIR>/usr/share/man/man3
 install -v -m644 doc/man/*.5 <DESTDIR>/usr/share/man/man5
 install -dv -m755 <DESTDIR>/usr/share/doc/libmng-1.0.10
 install -v -m644 doc/*.{png,txt} <DESTDIR>/usr/share/doc/libmng-1.0.10

Other than that - thanks to the patch - DESTDIR should work as it normally does.


Non-Multilib

Compile the package:

cp makefiles/makefile.linux Makefile &&
patch -Np1 -i ../libmng-1.0.10-libdir-1.patch &&
make

Install the package

make install &&
install -v -m644 doc/man/*.3 /usr/share/man/man3 &&
install -v -m644 doc/man/*.5 /usr/share/man/man5 &&
install -dv -m755 /usr/share/doc/libmng-1.0.10 &&
install -v -m644 doc/*.{png,txt} /usr/share/doc/libmng-1.0.10

Command Explanations

cp makefiles/makefile.linux Makefile: There are no autotools shipped with this package. We copy the appropriate Makefile to the base directory so that we can use it.

patch -Np1 -i ../libmng-1.0.10-libdir-1.patch: This patch makes it more sane to build libmng. Basically it makes the default prefix /usr and makes it so that all you have to do to change the library directory is pass libdir=/usr/lib64 (or the equivalent) to make and make install. It also adds DESTDIR to the Makefile for those that want it.

install ...: The documentation files are not installed by the installation procedure, so we copy them manually.

Multilib

32Bit

Compile the package:

cp makefiles/makefile.linux Makefile
patch -Np1 -i ../libmng-1.0.10-libdir-1.patch
make CC="gcc ${BUILD32}"

Install the package

make install

N32

Compile the package

cp makefiles/makefile.linux Makefile
patch -Np1 -i ../libmng-1.0.10-libdir-1.patch
make CC="gcc ${BUILDN32}" libdir=/usr/lib32

Install the package

make libdir=/usr/lib32 install

64Bit

Compile the package

cp makefiles/makefile.linux Makefile
patch -Np1 -i ../libmng-1.0.10-libdir-1.patch
make CC="gcc ${BUILD64}" libdir=/usr/lib64

Install the package

make libdir=/usr/lib64 install
install -v -m644 doc/man/*.3 /usr/share/man/man3 &&
install -v -m644 doc/man/*.5 /usr/share/man/man5 &&
install -v -m755 -d /usr/share/doc/libmng-1.0.10 &&
install -v -m644 doc/*.{png,txt} /usr/share/doc/libmng-1.0.10

Contents

Installed Programs: None
Installed Libraries: libmng.{so,a}
Installed Directories: /usr/share/doc/libmng-1.0.10

Short Descriptions

libmng.{so,a} provides functions for programs wishing to read and write MNG files which are animation files without the patent problems associated with certain other formats.