Ver código fonte

* Added "common.h", a placeholder for simple features and functions missing

from some systems.
tags/v0.99.beta14
Sam Hocevar sam 18 anos atrás
pai
commit
370fb06990
11 arquivos alterados com 38 adições e 37 exclusões
  1. +1
    -1
      Makefile.am
  2. +28
    -0
      common.h
  3. +1
    -4
      test/export.c
  4. +1
    -4
      test/font.c
  5. +1
    -4
      test/frames.c
  6. +1
    -4
      test/gamma.c
  7. +1
    -4
      test/hsv.c
  8. +1
    -4
      test/text.c
  9. +1
    -4
      test/transform.c
  10. +1
    -4
      test/truecolor.c
  11. +1
    -4
      test/unicode.c

+ 1
- 1
Makefile.am Ver arquivo

@@ -3,7 +3,7 @@
SUBDIRS = kernel cucul caca src test tools cpp doc
DIST_SUBDIRS = $(SUBDIRS) autotools debian msvc

EXTRA_DIST = NOTES COPYING.GPL COPYING.LGPL bootstrap build-dos build-kernel build-win32 caca-config.in libcaca.spec
EXTRA_DIST = NOTES COPYING.GPL COPYING.LGPL bootstrap build-dos build-kernel build-win32 caca-config.in common.h libcaca.spec
AUTOMAKE_OPTIONS = dist-bzip2

bin_SCRIPTS = caca-config


+ 28
- 0
common.h Ver arquivo

@@ -0,0 +1,28 @@
/*
* libcucul Canvas for ultrafast compositing of Unicode letters
* libcaca Colour ASCII-Art library
* Copyright (c) 2006 Sam Hocevar <sam@zoy.org>
* All Rights Reserved
*
* $Id$
*
* This library is free software; you can redistribute it and/or
* modify it under the terms of the Do What The Fuck You Want To
* Public License, Version 2, as published by Sam Hocevar. See
* http://sam.zoy.org/wtfpl/COPYING for more details.
*/

/*
* This file contains replacements for commonly found object types and
* function prototypes that are sometimes missing.
*/

#if !defined(HAVE_INTTYPES_H)
typedef signed char int8_t;
typedef signed short int16_t;
typedef signed long int int32_t;
typedef unsigned char uint8_t;
typedef unsigned short uint16_t;
typedef unsigned long int uint32_t;
#endif


+ 1
- 4
test/export.c Ver arquivo

@@ -12,13 +12,10 @@
*/

#include "config.h"
#include "common.h"

#if defined(HAVE_INTTYPES_H)
# include <inttypes.h>
#else
typedef unsigned char uint8_t;
typedef unsigned short uint16_t;
typedef unsigned int uint32_t;
#endif

#include <stdio.h>


+ 1
- 4
test/font.c Ver arquivo

@@ -12,13 +12,10 @@
*/

#include "config.h"
#include "common.h"

#if defined(HAVE_INTTYPES_H)
# include <inttypes.h>
#else
typedef unsigned char uint8_t;
typedef unsigned short uint16_t;
typedef unsigned int uint32_t;
#endif

#if defined(HAVE_ENDIAN_H)


+ 1
- 4
test/frames.c Ver arquivo

@@ -12,13 +12,10 @@
*/

#include "config.h"
#include "common.h"

#if defined(HAVE_INTTYPES_H)
# include <inttypes.h>
#else
typedef unsigned char uint8_t;
typedef unsigned short uint16_t;
typedef unsigned int uint32_t;
#endif

#include <stdio.h>


+ 1
- 4
test/gamma.c Ver arquivo

@@ -12,13 +12,10 @@
*/

#include "config.h"
#include "common.h"

#if defined(HAVE_INTTYPES_H)
# include <inttypes.h>
#else
typedef unsigned char uint8_t;
typedef unsigned short uint16_t;
typedef unsigned int uint32_t;
#endif

#if !defined(__KERNEL__)


+ 1
- 4
test/hsv.c Ver arquivo

@@ -12,13 +12,10 @@
*/

#include "config.h"
#include "common.h"

#if defined(HAVE_INTTYPES_H)
# include <inttypes.h>
#else
typedef unsigned char uint8_t;
typedef unsigned short uint16_t;
typedef unsigned int uint32_t;
#endif

#include <stdio.h>


+ 1
- 4
test/text.c Ver arquivo

@@ -12,13 +12,10 @@
*/

#include "config.h"
#include "common.h"

#if defined(HAVE_INTTYPES_H)
# include <inttypes.h>
#else
typedef unsigned char uint8_t;
typedef unsigned short uint16_t;
typedef unsigned int uint32_t;
#endif

#include <stdio.h>


+ 1
- 4
test/transform.c Ver arquivo

@@ -12,13 +12,10 @@
*/

#include "config.h"
#include "common.h"

#if defined(HAVE_INTTYPES_H)
# include <inttypes.h>
#else
typedef unsigned char uint8_t;
typedef unsigned short uint16_t;
typedef unsigned int uint32_t;
#endif

#include <stdio.h>


+ 1
- 4
test/truecolor.c Ver arquivo

@@ -12,13 +12,10 @@
*/

#include "config.h"
#include "common.h"

#if defined(HAVE_INTTYPES_H)
# include <inttypes.h>
#else
typedef unsigned char uint8_t;
typedef unsigned short uint16_t;
typedef unsigned int uint32_t;
#endif

#include <stdio.h>


+ 1
- 4
test/unicode.c Ver arquivo

@@ -12,13 +12,10 @@
*/

#include "config.h"
#include "common.h"

#if defined(HAVE_INTTYPES_H)
# include <inttypes.h>
#else
typedef unsigned char uint8_t;
typedef unsigned short uint16_t;
typedef unsigned int uint32_t;
#endif

#include <stdio.h>


Carregando…
Cancelar
Salvar