Kaynağa Gözat

* debian/control:

+ Changed section to libs/libdevel instead of games/games.
    + Changed package name to libcaca-dev.
  * debian/rules:
    + Use debian/compat instead of DH_COMPAT.
    + Install README, BUGS and TODO into /usr/share/doc.
  * caca-config.in:
    + First version of the config script.
  * configure.ac src/Makefile.am:
    + Build a static PIC library as well.
  * README TODO:
    + Various updates.
tags/v0.99.beta14
Sam Hocevar sam 21 yıl önce
ebeveyn
işleme
e23cfdea60
11 değiştirilmiş dosya ile 206 ekleme ve 20 silme
  1. +3
    -1
      Makefile.am
  2. +22
    -0
      README
  3. +12
    -0
      TODO
  4. +123
    -0
      caca-config.in
  5. +15
    -0
      configure.ac
  6. +1
    -0
      debian/compat
  7. +7
    -6
      debian/control
  8. +2
    -3
      debian/rules
  9. +10
    -7
      examples/Makefile.am
  10. +3
    -1
      examples/demo.c
  11. +8
    -2
      src/Makefile.am

+ 3
- 1
Makefile.am Dosyayı Görüntüle

@@ -5,6 +5,8 @@
SUBDIRS = src examples
DIST_SUBDIRS = $(SUBDIRS) autotools debian

EXTRA_DIST = BUGS bootstrap
EXTRA_DIST = BUGS bootstrap caca-config.in
AUTOMAKE_OPTIONS = foreign dist-bzip2

bin_SCRIPTS = caca-config


+ 22
- 0
README Dosyayı Görüntüle

@@ -12,3 +12,25 @@ Building libcaca
./configure --enable-conio --host=i386-pc-msdosdjgpp


Using libcaca

o Compiling a libcaca program is fairly simple:

gcc -c foobar.c -o foobar.o `caca-config --cflags`
gcc foobar.o -o foobar `caca-config --libs`

o If you are writing a shared object that uses libcaca, either a
dynamically loadable plug-in or a shared library, you should use
the `--plugin-libs' flag for libcaca:

gcc -fPIC -c libfoo.c -o libfoo.o `caca-config --cflags`
gcc -shared libfoo.o -o libfoo.so `caca-config --plugin-libs`


Binary packages

o As the API is not stable yet, everyone should statically link libcaca
with their programs or libraries. DO NOT DISTRIBUTE SHARED VERSIONS
OF LIBCACA.


+ 12
- 0
TODO Dosyayı Görüntüle

@@ -8,6 +8,8 @@ Low level stuff
o Better keyboard driver in an X terminal, see
http://groups.yahoo.com/group/zepp/message/381

o Write a window resize handler.

o DONE 12 Nov 2003: Port to conio.h


@@ -19,3 +21,13 @@ High level stuff

o Fix the thin ellipse rendering


Misc

o Draw a nicer logo sprite


Documentation

o Everything is still to do.


+ 123
- 0
caca-config.in Dosyayı Görüntüle

@@ -0,0 +1,123 @@
#! /bin/sh

## config script for libcaca -- Sam Hocevar <sam@zoy.org>
## $Id$

prefix=@prefix@
exec_prefix=@exec_prefix@

lib_dir=@libdir@
include_dir=@includedir@

@USE_SLANG_TRUE@libs_slang="-lslang"
@USE_NCURSES_TRUE@libs_ncurses="-lncurses"
libs="$libs_slang $libs_ncurses"

usage()
{
cat <<EOF
Usage: caca-config [OPTIONS] [LIBRARIES]
Options:
[--prefix[=DIR]]
[--exec-prefix[=DIR]]
[--version]
[--libs]
[--plugin-libs]
[--ldflags]
[--cflags]
EOF
exit $1
}

if test $# -eq 0
then
usage 1 1>&2
fi

while test $# -gt 0
do
case "$1" in
-*=*) optarg=`echo "$1" | sed 's/[-_a-zA-Z0-9]*=//'` ;;
*) optarg= ;;
esac

case $1 in
--prefix=*)
prefix=$optarg
local_prefix=yes
;;
--prefix)
echo_prefix=yes
;;
--exec-prefix=*)
exec_prefix=$optarg
exec_prefix_set=yes
local_prefix=yes
;;
--exec-prefix)
echo_exec_prefix=yes
;;
--version)
echo @VERSION@
exit 0
;;
--cflags)
echo_cflags=yes
;;
--ldflags)
echo_ldflags=yes
;;
@NEED_PIC_TRUE@ --libs)
@NEED_PIC_FALSE@ --libs | --plugin-libs)
echo_libs=yes
;;
@NEED_PIC_TRUE@ --plugin-libs)
@NEED_PIC_TRUE@ echo_plugin_libs=yes
@NEED_PIC_TRUE@ ;;
*)
usage 1 1>&2
;;
esac
shift
done

if test "$local_prefix" = "yes"
then
if test "$exec_prefix_set" != "yes"
then
exec_prefix=$prefix
fi
fi

if test "$echo_prefix" = "yes"
then
echo $prefix
fi

if test "$echo_exec_prefix" = "yes"
then
echo $exec_prefix
fi

if test "$echo_cflags" = "yes"
then
cflags="-I$include_dir/"
echo $cflags
fi

if test "$echo_ldflags" = "yes"
then
ldflags="-L$lib_dir"
echo $ldflags
fi

if test "$echo_libs" = "yes"
then
echo -L@libdir@ -lcaca $libs
fi

@NEED_PIC_TRUE@if test "$echo_plugin_libs" = "yes"
@NEED_PIC_TRUE@then
@NEED_PIC_TRUE@ echo -L@libdir@ -lcaca_pic $libs
@NEED_PIC_TRUE@fi


+ 15
- 0
configure.ac Dosyayı Görüntüle

@@ -58,11 +58,26 @@ CFLAGS="${CFLAGS} -g -O2 -fno-strength-reduce -fomit-frame-pointer"
# Code qui fait des warnings == code de porc == deux baffes dans ta gueule
CFLAGS="${CFLAGS} -Wall -Wpointer-arith -Wcast-align -Wcast-qual -Wstrict-prototypes -Wshadow -Waggregate-return -Wmissing-prototypes -Wnested-externs -Wsign-compare"

# Build the PIC library?
case "${target_os}" in
*mingw32* | *cygwin*)
NEED_PIC=false
;;
*)
NEED_PIC=:
;;
esac

AM_CONDITIONAL(NEED_PIC, ${NEED_PIC})

AC_OUTPUT([
Makefile
src/Makefile
examples/Makefile
autotools/Makefile
debian/Makefile
caca-config
],[
chmod 0755 caca-config
])


+ 1
- 0
debian/compat Dosyayı Görüntüle

@@ -0,0 +1 @@
4

+ 7
- 6
debian/control Dosyayı Görüntüle

@@ -1,15 +1,16 @@
Source: libcaca
Section: games
Section: libs
Priority: optional
Maintainer: Sam Hocevar (Debian packages) <sam+deb@zoy.org>
Build-Depends: debhelper (>= 2.2.0), slang1-dev
Build-Depends: debhelper (>= 4.0), slang1-dev
Standards-Version: 3.6.1.0

Package: libcaca
Section: games
Package: libcaca-dev
Section: libdevel
Architecture: any
Depends: ${shlibs:Depends}
Description: text mode graphics library
libcaca is the Color ANSI Console Art library.
libcaca is the Colour AsCii Art library.
.
It rules.
This package contains the header files and static libraries needed to
compile applications or shared objects that use libcaca.

+ 2
- 3
debian/rules Dosyayı Görüntüle

@@ -1,7 +1,6 @@
#!/usr/bin/make -f

#export DH_VERBOSE=1
export DH_COMPAT=3
export DEB_HOST_GNU_TYPE ?= $(shell dpkg-architecture -qDEB_HOST_GNU_TYPE)
export DEB_BUILD_GNU_TYPE ?= $(shell dpkg-architecture -qDEB_BUILD_GNU_TYPE)

@@ -38,7 +37,7 @@ install: build
dh_testroot
dh_clean -k
dh_installdirs
DESTDIR=`pwd`/debian/libcaca/ $(MAKE) install prefix=/usr
DESTDIR=`pwd`/debian/libcaca-dev/ $(MAKE) install prefix=/usr

# Build architecture-independent files here.
binary-indep: build install
@@ -50,7 +49,7 @@ binary-arch: build install
dh_testdir
dh_testroot
# dh_installdebconf
dh_installdocs
dh_installdocs README BUGS TODO
# dh_installexamples
dh_installmenu
# dh_installemacsen


+ 10
- 7
examples/Makefile.am Dosyayı Görüntüle

@@ -4,6 +4,8 @@

AM_CPPFLAGS = -I$(top_srcdir)/src

pkgdata_DATA = caca.txt

EXTRA_DIST = caca.txt

if USE_SLANG
@@ -13,13 +15,14 @@ if USE_NCURSES
LDFLAGS_ncurses = -lncurses
endif

noinst_PROGRAMS = demo spritedit
bin_PROGRAMS = caca-demo caca-spritedit

demo_SOURCES = demo.c
demo_LDADD = ../src/libcaca.a $(LDFLAGS_slang) $(LDFLAGS_ncurses) -lm
demo_CFLAGS = `pkg-config --cflags gtk+-2.0`
demo_LDFLAGS = `pkg-config --libs gtk+-2.0`
caca_demo_SOURCES = demo.c
caca_demo_LDADD = ../src/libcaca.a $(LDFLAGS_slang) $(LDFLAGS_ncurses) -lm
caca_demo_CPPFLAGS = -DDATADIR=\"$(pkgdatadir)\"
caca_demo_CFLAGS = `pkg-config --cflags gtk+-2.0`
caca_demo_LDFLAGS = `pkg-config --libs gtk+-2.0`

spritedit_SOURCES = spritedit.c
spritedit_LDADD = ../src/libcaca.a $(LDFLAGS_slang) $(LDFLAGS_ncurses) -lm
caca_spritedit_SOURCES = spritedit.c
caca_spritedit_LDADD = ../src/libcaca.a $(LDFLAGS_slang) $(LDFLAGS_ncurses) -lm


+ 3
- 1
examples/demo.c Dosyayı Görüntüle

@@ -67,7 +67,9 @@ int main(int argc, char **argv)
caca_set_delay(40000);

/* Initialize data */
sprite = caca_load_sprite("caca.txt");
sprite = caca_load_sprite(DATADIR "/caca.txt");
if(!sprite)
sprite = caca_load_sprite("caca.txt");
if(!sprite)
sprite = caca_load_sprite("examples/caca.txt");



+ 8
- 2
src/Makefile.am Dosyayı Görüntüle

@@ -2,7 +2,9 @@
# Automake targets and declarations for libcaca
###############################################################################

lib_LIBRARIES = libcaca.a
include_HEADERS = caca.h

lib_LIBRARIES = libcaca.a $(libcaca_pic_a)
libcaca_a_SOURCES = \
caca.c \
caca.h \
@@ -18,5 +20,9 @@ libcaca_a_SOURCES = \
blit.c \
$(NULL)

include_HEADERS = caca.h
if NEED_PIC
libcaca_pic_a = libcaca_pic.a
endif
libcaca_pic_a_SOURCES = $(libcaca_a_SOURCES)
libcaca_pic_a_CPPFLAGS = -fPIC


Yükleniyor…
İptal
Kaydet