fixed autotools (broken since the new directory structure) and added autotools as a build method for jpip (credit to Vincent Torri)

This commit is contained in:
Antonin Descampe 2011-05-23 20:30:20 +00:00
parent 88f43b15fa
commit 586581685c
8 changed files with 175 additions and 173 deletions

View File

@ -5,6 +5,10 @@ What's New for OpenJPEG
! : changed
+ : added
May 23, 2011
+ [antonin] added autotools as a build method for jpip (credit to Vincent Torri)
* [antonin] fixed autotools (broken since the new directory structure) (credit to Vincent Torri)
May 18, 2011
! [antonin] defined new type "opj_bool", and new constants OPJ_FALSE and OPJ_TRUE, to avoid having to deal with "stdbool.h" (patch from Winfried)

View File

@ -2,21 +2,7 @@ DISTCHECK_CONFIGURE_FLAGS = --enable-jp3d=yes --enable-jpwl=yes --enable-mj2=yes
ACLOCAL_AMFLAGS = -I m4
SUBDIRS = libopenjpeg codec
if WANT_JP3D
SUBDIRS += jp3d
endif
if WANT_JPWL
SUBDIRS += jpwl
endif
if WANT_MJ2
SUBDIRS += mj2
endif
SUBDIRS += doc
SUBDIRS = libopenjpeg applications doc
pkgconfigdir = $(libdir)/pkgconfig
pkgconfig_DATA = libopenjpeg1.pc

View File

@ -2,12 +2,16 @@ MAINTAINERCLEANFILES = Makefile.in
bin_PROGRAMS = j2k_to_image image_to_j2k j2k_dump
if WANT_JPWL
bin_PROGRAMS += JPWL_j2k_to_image JPWL_image_to_j2k
endif
j2k_to_image_CPPFLAGS = \
-I. \
-I$(top_srcdir)/codec \
-I$(top_builddir)/codec \
-I$(top_srcdir)/common \
-I$(top_builddir)/common \
-I$(top_srcdir)/applications/codec \
-I$(top_builddir)/applications/codec \
-I$(top_srcdir)/applications/common \
-I$(top_builddir)/applications/common \
-I$(top_srcdir)/libopenjpeg \
-I$(top_builddir)/libopenjpeg \
@PNG_CFLAGS@ \
@ -26,10 +30,10 @@ j2k_to_image.c \
image_to_j2k_CPPFLAGS = \
-I. \
-I$(top_srcdir)/codec \
-I$(top_builddir)/codec \
-I$(top_srcdir)/common \
-I$(top_builddir)/common \
-I$(top_srcdir)/applications/codec \
-I$(top_builddir)/applications/codec \
-I$(top_srcdir)/applications/common \
-I$(top_builddir)/applications/common \
-I$(top_srcdir)/libopenjpeg \
-I$(top_builddir)/libopenjpeg \
@PNG_CFLAGS@ \
@ -47,10 +51,10 @@ index.h
j2k_dump_CPPFLAGS = \
-I. \
-I$(top_srcdir)/codec \
-I$(top_builddir)/codec \
-I$(top_srcdir)/common \
-I$(top_builddir)/common \
-I$(top_srcdir)/applications/codec \
-I$(top_builddir)/applications/codec \
-I$(top_srcdir)/applications/common \
-I$(top_builddir)/applications/common \
-I$(top_srcdir)/libopenjpeg \
-I$(top_builddir)/libopenjpeg
j2k_dump_CFLAGS =
@ -62,6 +66,44 @@ j2k_dump.c \
../common/getopt.h \
index.h
JPWL_j2k_to_image_CPPFLAGS = \
-I. \
-I$(top_srcdir)/applications/common \
-I$(top_builddir)/applications/common \
-I$(top_srcdir)/libopenjpeg \
-I$(top_builddir)/libopenjpeg \
-DUSE_JPWL \
@TIFF_CFLAGS@ \
@PNG_CFLAGS@ \
@LCMS1_CFLAGS@ \
@LCMS2_CFLAGS@
JPWL_j2k_to_image_CFLAGS =
JPWL_j2k_to_image_LDADD = $(top_builddir)/libopenjpeg/jpwl/libopenjpeg_JPWL.la @LCMS1_LIBS@ @LCMS2_LIBS@ @TIFF_LIBS@ @PNG_LIBS@
JPWL_j2k_to_image_SOURCES = \
../common/color.c \
../common/getopt.c \
index.c \
convert.c \
j2k_to_image.c
JPWL_image_to_j2k_CPPFLAGS = \
-I. \
-I$(top_srcdir)/applications/common \
-I$(top_builddir)/applications/common \
-I$(top_srcdir)/libopenjpeg \
-I$(top_builddir)/libopenjpeg \
-DUSE_JPWL \
@TIFF_CFLAGS@ \
@PNG_CFLAGS@
JPWL_image_to_j2k_CFLAGS =
JPWL_image_to_j2k_LDADD = $(top_builddir)/libopenjpeg/jpwl/libopenjpeg_JPWL.la @TIFF_LIBS@ @PNG_LIBS@
JPWL_image_to_j2k_SOURCES = \
..//common/getopt.c \
index.c \
convert.c \
image_to_j2k.c
EXTRA_DIST = \
CMakeLists.txt \
windirent.h
@ -70,3 +112,7 @@ install-data-hook:
@echo -e " (B)\t$(bindir)/j2k_to_image$(EXEEXT)" >> $(top_builddir)/report.txt
@echo -e " (B)\t$(bindir)/image_to_j2k$(EXEEXT)" >> $(top_builddir)/report.txt
@echo -e " (B)\t$(bindir)/j2k_dump$(EXEEXT)" >> $(top_builddir)/report.txt
if WANT_JPWL
@echo -e " (B)\t$(bindir)/JPWL_j2k_to_image$(EXEEXT)" >> $(top_builddir)/report.txt
@echo -e " (B)\t$(bindir)/JPWL_image_to_j2k$(EXEEXT)" >> $(top_builddir)/report.txt
endif

View File

@ -5,6 +5,9 @@ What's New for OpenJPIP
! : changed
+ : added
May 23, 2011
+ [antonin] added autotools as a build method for jpip (credit to Vincent Torri)
May 10, 2011
! [kaori] opj_viewer removed the xml functions (for users without Xersus2)
+ [kaori] renamed opj_viewer to opj_viewer_xerces ( needs Xersus2)

View File

@ -1,24 +1,24 @@
MAINTAINERCLEANFILES = Makefile.in
OPJ_SRC = \
../libopenjpeg/bio.c \
../libopenjpeg/cio.c \
../libopenjpeg/dwt.c \
../libopenjpeg/event.c \
../libopenjpeg/image.c \
../libopenjpeg/j2k.c \
../libopenjpeg/j2k_lib.c \
../libopenjpeg/jp2.c \
../libopenjpeg/jpt.c \
../libopenjpeg/mct.c \
../libopenjpeg/mqc.c \
../libopenjpeg/openjpeg.c \
../libopenjpeg/pi.c \
../libopenjpeg/raw.c \
../libopenjpeg/t1.c \
../libopenjpeg/t2.c \
../libopenjpeg/tcd.c \
../libopenjpeg/tgt.c
../../libopenjpeg/bio.c \
../../libopenjpeg/cio.c \
../../libopenjpeg/dwt.c \
../../libopenjpeg/event.c \
../../libopenjpeg/image.c \
../../libopenjpeg/j2k.c \
../../libopenjpeg/j2k_lib.c \
../../libopenjpeg/jp2.c \
../../libopenjpeg/jpt.c \
../../libopenjpeg/mct.c \
../../libopenjpeg/mqc.c \
../../libopenjpeg/openjpeg.c \
../../libopenjpeg/pi.c \
../../libopenjpeg/raw.c \
../../libopenjpeg/t1.c \
../../libopenjpeg/t2.c \
../../libopenjpeg/tcd.c \
../../libopenjpeg/tgt.c
bin_PROGRAMS = \
frames_to_mj2 \
@ -28,12 +28,10 @@ wrap_j2k_in_mj2
frames_to_mj2_CPPFLAGS = \
-I. \
-I$(top_srcdir)/common \
-I$(top_builddir)/common \
-I$(top_srcdir)/applications/common \
-I$(top_builddir)/applications/common \
-I$(top_srcdir)/libopenjpeg \
-I$(top_builddir)/libopenjpeg \
-I$(top_srcdir)/mj2 \
-I$(top_builddir)/mj2 \
-DOPJ_STATIC
frames_to_mj2_CFLAGS =
frames_to_mj2_LDADD = -lm
@ -48,12 +46,10 @@ mj2_convert.h
mj2_to_frames_CPPFLAGS = \
-I. \
-I$(top_srcdir)/common \
-I$(top_builddir)/common \
-I$(top_srcdir)/applications/common \
-I$(top_builddir)/applications/common \
-I$(top_srcdir)/libopenjpeg \
-I$(top_builddir)/libopenjpeg \
-I$(top_srcdir)/mj2 \
-I$(top_builddir)/mj2 \
@LCMS2_CFLAGS@ \
@LCMS1_CFLAGS@ \
-DOPJ_STATIC
@ -71,12 +67,10 @@ mj2_convert.h
extract_j2k_from_mj2_CPPFLAGS = \
-I. \
-I$(top_srcdir)/common \
-I$(top_builddir)/common \
-I$(top_srcdir)/applications/common \
-I$(top_builddir)/applications/common \
-I$(top_srcdir)/libopenjpeg \
-I$(top_builddir)/libopenjpeg \
-I$(top_srcdir)/mj2 \
-I$(top_builddir)/mj2 \
-DOPJ_STATIC
extract_j2k_from_mj2_CFLAGS =
extract_j2k_from_mj2_LDADD = -lm
@ -88,12 +82,10 @@ mj2.h
wrap_j2k_in_mj2_CPPFLAGS = \
-I. \
-I$(top_srcdir)/common \
-I$(top_builddir)/common \
-I$(top_srcdir)/applications/common \
-I$(top_builddir)/applications/common \
-I$(top_srcdir)/libopenjpeg \
-I$(top_builddir)/libopenjpeg \
-I$(top_srcdir)/mj2 \
-I$(top_builddir)/mj2 \
-DOPJ_STATIC
wrap_j2k_in_mj2_CFLAGS =
wrap_j2k_in_mj2_LDADD = -lm

View File

@ -9,18 +9,10 @@ m4_define([OPJ_MAJOR], [1])
m4_define([OPJ_MINOR], [4])
m4_define([OPJ_MICRO], [0])
m4_define([JP3D_MAJOR], [1])
m4_define([JP3D_MINOR], [3])
m4_define([JP3D_MICRO], [0])
m4_define([lt_cur], m4_eval(OPJ_MAJOR + OPJ_MINOR))
m4_define([lt_rev], OPJ_MICRO)
m4_define([lt_age], OPJ_MINOR)
m4_define([lt_cur_jp3d], m4_eval(JP3D_MAJOR + JP3D_MINOR))
m4_define([lt_rev_jp3d], JP3D_MICRO)
m4_define([lt_age_jp3d], JP3D_MINOR)
AC_PREREQ([2.62])
AC_INIT([OpenJPEG],
[OPJ_MAJOR.OPJ_MINOR.OPJ_MICRO],
@ -44,22 +36,12 @@ AC_SUBST(MAJOR_NR)
AC_SUBST(MINOR_NR)
AC_SUBST(MICRO_NR)
JP3D_MAJOR_NR=JP3D_MAJOR
JP3D_MINOR_NR=JP3D_MINOR
JP3D_MICRO_NR=JP3D_MICRO
AC_SUBST(JP3D_MAJOR_NR)
AC_SUBST(JP3D_MINOR_NR)
AC_SUBST(JP3D_MICRO_NR)
LT_PREREQ([2.0])
LT_INIT([win32-dll])
lt_version=lt_cur:lt_rev:lt_age
AC_SUBST(lt_version)
lt_version_jp3d=lt_cur_jp3d:lt_rev_jp3d:lt_age_jp3d
AC_SUBST(lt_version_jp3d)
### Needed information
@ -140,27 +122,56 @@ fi
AM_CONDITIONAL([WANT_JPWL], [test "x${want_jpwl}" = "xyes"])
# JP3D
# JPIP
AC_ARG_ENABLE([jp3d],
[AC_HELP_STRING([--enable-jp3d], [build jp3d library @<:@default=disabled@:>@])],
AC_ARG_ENABLE([jpip],
[AC_HELP_STRING([--enable-jpip], [build jpip library @<:@default=disabled@:>@])],
[
if test "x${enableval}" = "xyes" ; then
want_jp3d="yes"
want_jpip="yes"
else
want_jp3d="no"
want_jpip="no"
fi
],
[want_jp3d="no"])
[want_jpip="no"])
AC_MSG_CHECKING([whether to build the JP3D library])
AC_MSG_RESULT([${want_jp3d}])
AC_MSG_CHECKING([whether to build the JPIP library])
AC_MSG_RESULT([${want_jpip}])
if test "x${want_jp3d}" = "xyes" ; then
AC_DEFINE(USE_JP3D, [1], [define to 1 if you use jp3d])
if test "x${want_jpip}" = "xyes" ; then
AC_DEFINE(USE_JPIP, [1], [define to 1 if you use jpip])
fi
AM_CONDITIONAL([WANT_JP3D], [test "x${want_jp3d}" = "xyes"])
# libfcgi
if test "x${want_jpip}" = "xyes" ; then
OPJ_CHECK_LIB([/usr],
[fcgi_stdio.h],
[fcgi],
[FCGI_printf],
[want_jpip="yes"],
[want_jpip="no"])
fi
if test "x${want_jpip}" = "xno" ; then
OPJ_CHECK_LIB([/usr/local],
[fcgi_stdio.h],
[fcgi],
[FCGI_printf],
[want_jpip="yes"],
[want_jpip="no"])
fi
if test "x${want_jpip}" = "xno" ; then
OPJ_CHECK_LIB([/opt],
[fcgi_stdio.h],
[fcgi],
[FCGI_printf],
[want_jpip="yes"],
[want_jpip="no"])
fi
AM_CONDITIONAL([WANT_JPIP], [test "x${want_jpip}" = "xyes"])
### Checks for programs
@ -410,8 +421,6 @@ if test "x${have_lcms2}" = "xno" ; then
fi
### Checks for header files
## FIXME: declarations must be fixed in source code. See autoconf manual
@ -451,13 +460,16 @@ AC_CONFIG_FILES([
Makefile
libopenjpeg1.pc
libopenjpeg/Makefile
jpwl/Makefile
codec/Makefile
mj2/Makefile
libopenjpeg/jpwl/Makefile
applications/Makefile
applications/codec/Makefile
applications/mj2/Makefile
applications/jpip/Makefile
applications/jpip/libopenjpip/Makefile
applications/jpip/opj_server/Makefile
applications/jpip/opj_client/Makefile
applications/jpip/opj_client/opj_dec_server/Makefile
doc/Makefile
jp3d/Makefile
jp3d/libjp3dvm/Makefile
jp3d/codec/Makefile
])
AC_OUTPUT
@ -486,5 +498,5 @@ echo " Build.............: make doc"
echo
echo " mj2.................: ${want_mj2}"
echo " jpwl................: ${want_jpwl}"
echo " jp3d................: ${want_jp3d}"
echo " jpip................: ${want_jpip}"
echo

View File

@ -1,5 +1,11 @@
MAINTAINERCLEANFILES = Makefile.in
SUBDIRS = .
if WANT_JPWL
SUBDIRS += jpwl
endif
includesdir = $(includedir)/openjpeg-$(MAJOR_NR).$(MINOR_NR)
includes_HEADERS = openjpeg.h
@ -31,6 +37,7 @@ openjpeg.c \
pi.c \
raw.c \
t1.c \
t1_generate_luts.c \
t2.c \
tcd.c \
tgt.c \
@ -47,15 +54,15 @@ jp2.h \
jpt.h \
mct.h \
mqc.h \
opj_includes.h \
opj_malloc.h \
pi.h \
raw.h \
t1.h \
t1_luts.h \
t2.h \
tcd.h \
tgt.h \
opj_malloc.h \
opj_includes.h
tgt.h
EXTRA_DIST = \
CMakeLists.txt

View File

@ -3,31 +3,32 @@ MAINTAINERCLEANFILES = Makefile.in
lib_LTLIBRARIES = libopenjpeg_JPWL.la
OPJ_SRC = \
../libopenjpeg/bio.c \
../libopenjpeg/cio.c \
../libopenjpeg/dwt.c \
../libopenjpeg/event.c \
../libopenjpeg/image.c \
../libopenjpeg/j2k.c \
../libopenjpeg/j2k_lib.c \
../libopenjpeg/jp2.c \
../libopenjpeg/jpt.c \
../libopenjpeg/mct.c \
../libopenjpeg/mqc.c \
../libopenjpeg/openjpeg.c \
../libopenjpeg/pi.c \
../libopenjpeg/raw.c \
../libopenjpeg/t1.c \
../libopenjpeg/t2.c \
../libopenjpeg/tcd.c \
../libopenjpeg/tgt.c
../bio.c \
../cio.c \
../dwt.c \
../event.c \
../image.c \
../j2k.c \
../j2k_lib.c \
../jp2.c \
../jpt.c \
../mct.c \
../mqc.c \
../openjpeg.c \
../pi.c \
../raw.c \
../t1.c \
../t1_generate_luts.c \
../t2.c \
../tcd.c \
../tgt.c
libopenjpeg_JPWL_la_CPPFLAGS = \
-I. \
-I$(top_srcdir)/libopenjpeg \
-I$(top_builddir)/libopenjpeg \
-I$(top_srcdir)/jpwl \
-I$(top_builddir)/jpwl \
-I$(top_srcdir)/libopenjpeg/jpwl \
-I$(top_builddir)/libopenjpeg/jpwl \
-DUSE_JPWL
libopenjpeg_JPWL_la_CFLAGS =
libopenjpeg_JPWL_la_LIBADD = -lm
@ -38,60 +39,11 @@ crc.c \
jpwl.c \
jpwl_lib.c \
rs.c \
jpwl.h \
crc.h \
jpwl.h \
rs.h
bin_PROGRAMS = JPWL_j2k_to_image JPWL_image_to_j2k
JPWL_j2k_to_image_CPPFLAGS = \
-I. \
-I$(top_srcdir)/common \
-I$(top_builddir)/common \
-I$(top_srcdir)/libopenjpeg \
-I$(top_builddir)/libopenjpeg \
-I$(top_srcdir)/jpwl \
-I$(top_builddir)/jpwl \
-DUSE_JPWL \
@TIFF_CFLAGS@ \
@PNG_CFLAGS@ \
@LCMS1_CFLAGS@ \
@LCMS2_CFLAGS@
JPWL_j2k_to_image_CFLAGS =
JPWL_j2k_to_image_LDADD = $(top_builddir)/jpwl/libopenjpeg_JPWL.la @LCMS1_LIBS@ @LCMS2_LIBS@ @TIFF_LIBS@ @PNG_LIBS@
JPWL_j2k_to_image_SOURCES = \
$(top_builddir)/common/color.c \
$(top_builddir)/common/getopt.c \
$(top_builddir)/codec/index.c \
$(top_builddir)/codec/convert.c \
$(top_builddir)/codec/j2k_to_image.c
JPWL_image_to_j2k_CPPFLAGS = \
-I. \
-I$(top_srcdir)/common \
-I$(top_builddir)/common \
-I$(top_srcdir)/libopenjpeg \
-I$(top_builddir)/libopenjpeg \
-I$(top_srcdir)/jpwl \
-I$(top_builddir)/jpwl \
-DUSE_JPWL \
@TIFF_CFLAGS@ \
@PNG_CFLAGS@
JPWL_image_to_j2k_CFLAGS =
JPWL_image_to_j2k_LDADD = $(top_builddir)/jpwl/libopenjpeg_JPWL.la @TIFF_LIBS@ @PNG_LIBS@
JPWL_image_to_j2k_SOURCES = \
$(top_builddir)/common/getopt.c \
$(top_builddir)/codec/index.c \
$(top_builddir)/codec/convert.c \
$(top_builddir)/codec/image_to_j2k.c
EXTRA_DIST = \
CMakeLists.txt
install-data-hook:
@echo -e " (B)\t$(bindir)/JPWL_j2k_to_image$(EXEEXT)" >> $(top_builddir)/report.txt
@echo -e " (B)\t$(bindir)/JPWL_image_to_j2k$(EXEEXT)" >> $(top_builddir)/report.txt
@echo -e " (LA)\t$(libdir)/libopenjpeg_JPWL.la" >> $(top_builddir)/report.txt
@( $(call solist) ) >> $(top_builddir)/report.txt
@echo -e " (A)\t$(base)/$(a)" >> $(top_builddir)/report.txt