diff --git a/.gitignore b/.gitignore index 959d0eee9..7268e963b 100644 --- a/.gitignore +++ b/.gitignore @@ -25,6 +25,7 @@ /libports/include/KHR /libports/include/SDL /libports/include/ffat +/libports/include/fribidi /libports/include/freetype /libports/include/ft2build.h /libports/include/jbig2dec diff --git a/libports/include/fribidi/fribidi-config.h b/libports/include/fribidi/fribidi-config.h new file mode 100644 index 000000000..ac452c314 --- /dev/null +++ b/libports/include/fribidi/fribidi-config.h @@ -0,0 +1,26 @@ +/* lib/fribidi-config.h. Generated from fribidi-config.h.in by configure. */ +/* Not copyrighted, in public domain. */ +#ifndef FRIBIDI_CONFIG_H +#define FRIBIDI_CONFIG_H + +#define FRIBIDI "fribidi" +#define FRIBIDI_NAME "GNU FriBidi" +#define FRIBIDI_BUGREPORT "http://bugs.freedesktop.org/enter_bug.cgi?product=fribidi" + +#define FRIBIDI_VERSION "0.19.5" +#define FRIBIDI_MAJOR_VERSION 0 +#define FRIBIDI_MINOR_VERSION 19 +#define FRIBIDI_MICRO_VERSION 5 +#define FRIBIDI_INTERFACE_VERSION 3 +#define FRIBIDI_INTERFACE_VERSION_STRING "3" + +/* Define to 1 if you want charset conversion codes in the library */ +#define FRIBIDI_CHARSETS 1 + +/* Define to 1 if you want to use glib */ +#define FRIBIDI_USE_GLIB 0 + +/* The size of a `int', as computed by sizeof. */ +#define FRIBIDI_SIZEOF_INT 4 + +#endif /* FRIBIDI_CONFIG_H */ diff --git a/libports/lib/mk/fribidi.mk b/libports/lib/mk/fribidi.mk new file mode 100644 index 000000000..2e3a2f991 --- /dev/null +++ b/libports/lib/mk/fribidi.mk @@ -0,0 +1,14 @@ +include $(REP_DIR)/ports/fribidi.inc + +FRIBIDI_DIR = $(REP_DIR)/contrib/$(FRIBIDI) + +LIBS += libc +INC_DIR += $(FRIBIDI_DIR) $(REP_DIR)/src/lib/fribidi $(REP_DIR)/include/fribidi +SRC_C = $(notdir $(wildcard $(FRIBIDI_DIR)/lib/*.c)) + +CC_OPT += -DHAVE_CONFIG_H +CC_WARN = + +vpath %.c $(FRIBIDI_DIR)/lib + +SHARED_LIB = yes diff --git a/libports/ports/fribidi.inc b/libports/ports/fribidi.inc new file mode 100644 index 000000000..f676cef2a --- /dev/null +++ b/libports/ports/fribidi.inc @@ -0,0 +1,2 @@ +FRIBIDI_VERSION := 0.19.5 +FRIBIDI := fribidi-$(FRIBIDI_VERSION) diff --git a/libports/ports/fribidi.mk b/libports/ports/fribidi.mk new file mode 100644 index 000000000..c97a1584a --- /dev/null +++ b/libports/ports/fribidi.mk @@ -0,0 +1,36 @@ +include ports/fribidi.inc + +FRIBIDI_TBZ2 = $(FRIBIDI).tar.bz2 +FRIBIDI_URL = http://fribidi.org/download/$(FRIBIDI_TBZ2) + +# +# Interface to top-level prepare Makefile +# +PORTS += $(FRIBIDI) + +prepare-fribidi: $(CONTRIB_DIR)/$(FRIBIDI) include/fribidi/fribidi.h + +$(CONTRIB_DIR)/$(FRIBIDI):clean-fribidi + +# +# Port-specific local rules +# +$(DOWNLOAD_DIR)/$(FRIBIDI_TBZ2): + $(VERBOSE)wget -c -P $(DOWNLOAD_DIR) $(FRIBIDI_URL) && touch $@ + +$(CONTRIB_DIR)/$(FRIBIDI): $(DOWNLOAD_DIR)/$(FRIBIDI_TBZ2) + $(VERBOSE)tar xfj $< -C $(CONTRIB_DIR) && touch $@ + +FRIBIDI_INCLUDES = fribidi.h + +include/fribidi/fribidi.h: + $(VERBOSE)for i in lib charset; do \ + for j in `find $(CONTRIB_DIR)/$(FRIBIDI)/$$i -name "fribidi*.h"`; do \ + name=`basename $$j`; \ + ln -sf ../../$(CONTRIB_DIR)/$(FRIBIDI)/$$i/$$name $(dir $@)$$name; \ + done; \ + done + +clean-fribidi: + $(VERBOSE)find include/fribidi -type l -delete + $(VERBOSE)rm -rf $(CONTRIB_DIR)/$(FRIBIDI) diff --git a/libports/src/lib/fribidi/config.h b/libports/src/lib/fribidi/config.h new file mode 100644 index 000000000..369387832 --- /dev/null +++ b/libports/src/lib/fribidi/config.h @@ -0,0 +1,102 @@ +/* config.h. Generated from config.h.in by configure. */ +/* config.h.in. Generated from configure.ac by autoheader. */ + +/* Define to 1 if you want to include debug code in the library */ +#define DEBUG 1 + +/* Define to 1 if you have the header file. */ +/* #undef HAVE_ASM_PAGE_H */ + +/* Define to 1 if you have the header file. */ +#define HAVE_DLFCN_H 1 + +/* Define to 1 if you have the header file. */ +#define HAVE_INTTYPES_H 1 + +/* Define to 1 if you have the `memmove' function. */ +#define HAVE_MEMMOVE 1 + +/* Define to 1 if you have the header file. */ +#define HAVE_MEMORY_H 1 + +/* Define to 1 if you have the `memset' function. */ +#define HAVE_MEMSET 1 + +/* Define to 1 if you have the header file. */ +#define HAVE_STDINT_H 1 + +/* Define to 1 if you have the header file. */ +#define HAVE_STDLIB_H 1 + +/* Define to 1 if you have the `strdup' function. */ +#define HAVE_STRDUP 1 + +/* Define to 1 if cpp supports the ANSI # stringizing operator. */ +#define HAVE_STRINGIZE 1 + +/* Define to 1 if you have the header file. */ +#define HAVE_STRINGS_H 1 + +/* Define to 1 if you have the header file. */ +#define HAVE_STRING_H 1 + +/* Define to 1 if you have the header file. */ +#define HAVE_SYS_STAT_H 1 + +/* Define to 1 if you have the header file. */ +#define HAVE_SYS_TIMES_H 1 + +/* Define to 1 if you have the header file. */ +#define HAVE_SYS_TYPES_H 1 + +/* Define to 1 if you have the header file. */ +#define HAVE_UNISTD_H 1 + +/* Define to 1 if you have the header file. */ +#define HAVE_WCHAR_H 1 + +/* Define to the sub-directory in which libtool stores uninstalled libraries. + */ +#define LT_OBJDIR ".libs/" + +/* Define to the address where bug reports for this package should be sent. */ +#define PACKAGE_BUGREPORT "http://bugs.freedesktop.org/enter_bug.cgi?product=fribidi" + +/* Define to the full name of this package. */ +#define PACKAGE_NAME "GNU FriBidi" + +/* Define to the full name and version of this package. */ +#define PACKAGE_STRING "GNU FriBidi 0.19.5" + +/* Define to the one symbol short name of this package. */ +#define PACKAGE_TARNAME "fribidi" + +/* Define to the home page for this package. */ +#define PACKAGE_URL "http://fribidi.org/" + +/* Define to the version of this package. */ +#define PACKAGE_VERSION "0.19.5" + +/* Define as the return type of signal handlers (`int' or `void'). */ +#define RETSIGTYPE void + +/* The size of `int', as computed by sizeof. */ +#define SIZEOF_INT 4 + +/* The size of `short', as computed by sizeof. */ +#define SIZEOF_SHORT 2 + +/* The size of `void *', as computed by sizeof. */ +#define SIZEOF_VOID_P 4 + +/* The size of `wchar_t', as computed by sizeof. */ +#define SIZEOF_WCHAR_T 4 + +/* Define to 1 if you have the ANSI C header files. */ +#define STDC_HEADERS 1 + +/* Define to 1 if you want to use simple mallocs instead of memory chunks */ +/* #undef USE_SIMPLE_MALLOC */ + +/* Define to empty if `const' does not conform to ANSI C. */ +/* #undef const */ diff --git a/libports/src/test/libports/fribidi/target.mk b/libports/src/test/libports/fribidi/target.mk new file mode 100644 index 000000000..efacd4616 --- /dev/null +++ b/libports/src/test/libports/fribidi/target.mk @@ -0,0 +1,5 @@ +TARGET = test-fribidi +LIBS = libc fribidi +SRC_CC = main.cc + +vpath main.cc $(PRG_DIR)/..