From d3ab9923c45ff9bb75979a21344e7295289aadc1 Mon Sep 17 00:00:00 2001 From: maxcodehack Date: Sun, 3 Jan 2021 15:25:55 +0000 Subject: [PATCH] uPDF: set up libraries autobuild git-svn-id: svn://kolibrios.org@8506 a494cfbc-eb01-0410-851d-a64ba20cac60 --- contrib/media/updf/draw/Tupfile.lua | 12 ++++++++++++ contrib/media/updf/fitz/Tupfile.lua | 12 ++++++++++++ contrib/media/updf/libopenjpeg/Tupfile.lua | 12 ++++++++++++ contrib/media/updf/pdf/Tupfile.lua | 12 ++++++++++++ 4 files changed, 48 insertions(+) create mode 100755 contrib/media/updf/draw/Tupfile.lua create mode 100755 contrib/media/updf/fitz/Tupfile.lua create mode 100755 contrib/media/updf/libopenjpeg/Tupfile.lua create mode 100755 contrib/media/updf/pdf/Tupfile.lua diff --git a/contrib/media/updf/draw/Tupfile.lua b/contrib/media/updf/draw/Tupfile.lua new file mode 100755 index 0000000000..03d664b658 --- /dev/null +++ b/contrib/media/updf/draw/Tupfile.lua @@ -0,0 +1,12 @@ +if tup.getconfig("NO_GCC") ~= "" then return end +HELPERDIR = (tup.getconfig("HELPERDIR") == "") and "../../../../programs" or tup.getconfig("HELPERDIR") +tup.include(HELPERDIR .. "/use_gcc.lua") +tup.include(HELPERDIR .. "/use_newlib.lua") + +SDK_DIR = "../../../sdk" + +CFLAGS = CFLAGS .. " -std=c99" +INCLUDES = INCLUDES .. " -I ../fitz" + +compile_gcc{"arch_arm.c", "arch_port.c", "draw_affine.c", "draw_blend.c", "draw_device.c", "draw_edge.c", "draw_glyph.c", "draw_mesh.c", "draw_paint.c", "draw_path.c", "draw_scale.c", "draw_unpack.c"} +tup.rule(OBJS, "kos32-ar rcs %o %f", {"../lib/libdraw.a", "<../lib/libdraw>"}) diff --git a/contrib/media/updf/fitz/Tupfile.lua b/contrib/media/updf/fitz/Tupfile.lua new file mode 100755 index 0000000000..2650401e13 --- /dev/null +++ b/contrib/media/updf/fitz/Tupfile.lua @@ -0,0 +1,12 @@ +if tup.getconfig("NO_GCC") ~= "" then return end +HELPERDIR = (tup.getconfig("HELPERDIR") == "") and "../../../../programs" or tup.getconfig("HELPERDIR") +tup.include(HELPERDIR .. "/use_gcc.lua") +tup.include(HELPERDIR .. "/use_newlib.lua") + +SDK_DIR = "../../../sdk" + +CFLAGS = CFLAGS .. " -std=c99 -U__WIN32__ -U_Win32 -U_WIN32 -U__MINGW32__ -UWIN32" +INCLUDES = INCLUDES .. " -I . -I $(SDK_DIR)/sources/freetype/include -I $(SDK_DIR)/sources/libjpeg -I $(SDK_DIR)/sources/zlib -I ../libopenjpeg -I ../libjbig2dec" + +compile_gcc{"base_error.c", "base_geometry.c", "base_getopt.c", "base_hash.c", "base_memory.c", "base_object.c", "base_string.c", "base_time.c", "crypt_aes.c", "crypt_arc4.c", "crypt_md5.c", "crypt_sha2.c", "dev_bbox.c", "dev_list.c", "dev_null.c", "dev_text.c", "dev_trace.c", "filt_basic.c", "filt_dctd.c", "filt_faxd.c", "filt_flate.c", "filt_jbig2d.c", "filt_jpxd.c", "filt_lzwd.c", "filt_predict.c", "lrintf.c", "obj_print.c", "res_bitmap.c", "res_colorspace.c", "res_font.c", "res_halftone.c", "res_path.c", "res_pixmap.c", "res_shade.c", "res_text.c", "stm_buffer.c", "stm_open.c", "stm_read.c", "strtoll.c", "strtoull.c"} +tup.rule(OBJS, "kos32-ar rcs %o %f", {"../lib/libfitz.a", "<../lib/libfitz>"}) diff --git a/contrib/media/updf/libopenjpeg/Tupfile.lua b/contrib/media/updf/libopenjpeg/Tupfile.lua new file mode 100755 index 0000000000..0c10f4fe77 --- /dev/null +++ b/contrib/media/updf/libopenjpeg/Tupfile.lua @@ -0,0 +1,12 @@ +if tup.getconfig("NO_GCC") ~= "" then return end +HELPERDIR = (tup.getconfig("HELPERDIR") == "") and "../../../../programs" or tup.getconfig("HELPERDIR") +tup.include(HELPERDIR .. "/use_gcc.lua") +tup.include(HELPERDIR .. "/use_newlib.lua") + +SDK_DIR = "../../../sdk" + +CFLAGS = CFLAGS .. " -std=c99 -U__WIN32__ -U_Win32 -U_WIN32 -U__MINGW32__ -UWIN32" +INCLUDES = INCLUDES .. " -I ." + +compile_gcc{"bio.c", "cio.c", "dwt.c", "event.c", "image.c", "j2k.c", "j2k_lib.c", "jp2.c", "jpt.c", "lrintf.c", "mct.c", "mqc.c", "openjpeg.c", "pi.c", "raw.c", "t1.c", "t1_generate_luts.c", "t2.c", "tcd.c", "tgt.c"} +tup.rule(OBJS, "kos32-ar rcs %o %f", {"../lib/libopenjpeg.a", "<../lib/libopenjpeg>"}) diff --git a/contrib/media/updf/pdf/Tupfile.lua b/contrib/media/updf/pdf/Tupfile.lua new file mode 100755 index 0000000000..cbdfa857ad --- /dev/null +++ b/contrib/media/updf/pdf/Tupfile.lua @@ -0,0 +1,12 @@ +if tup.getconfig("NO_GCC") ~= "" then return end +HELPERDIR = (tup.getconfig("HELPERDIR") == "") and "../../../../programs" or tup.getconfig("HELPERDIR") +tup.include(HELPERDIR .. "/use_gcc.lua") +tup.include(HELPERDIR .. "/use_newlib.lua") + +SDK_DIR = "../../../sdk" + +CFLAGS = CFLAGS .. " -std=c99" +INCLUDES = INCLUDES .. " -I . -I ../fitz -I $(SDK_DIR)/sources/freetype/include" + +compile_gcc{"pdf_annot.c", "pdf_cmap.c", "pdf_cmap_load.c", "pdf_cmap_parse.c", "pdf_cmap_table.c", "pdf_colorspace.c", "pdf_crypt.c", "pdf_encoding.c", "pdf_font.c", "pdf_fontfile.c", "pdf_function.c", "pdf_image.c", "pdf_interpret.c", "pdf_lex.c", "pdf_metrics.c", "pdf_nametree.c", "pdf_outline.c", "pdf_page.c", "pdf_parse.c", "pdf_pattern.c", "pdf_repair.c", "pdf_shade.c", "pdf_store.c", "pdf_stream.c", "pdf_type3.c", "pdf_unicode.c", "pdf_xobject.c", "pdf_xref.c", "snprintf.c"} +tup.rule(OBJS, "kos32-ar rcs %o %f", {"../lib/libmupdf.a", "<../lib/libmupdf>"})