ucl: Split package. Fix autotools using.

This commit is contained in:
Alexpux 2015-02-22 23:01:38 +03:00
parent 15d2007c7c
commit 87a4771cc2
5 changed files with 126 additions and 603 deletions

View File

@ -9,486 +9,3 @@
| -mingw32* | -linux-gnu* | -linux-uclibc* | -uxpv* | -beos* | -mpeix* | -udk* \
| -interix* | -uwin* | -mks* | -rhapsody* | -darwin* | -opened* \
| -openstep* | -oskit* | -conix* | -pw32* | -nonstopux* \
--- a/acconfig/ltmain.sh.orig 2004-07-20 01:01:47.000000000 +0200
+++ b/acconfig/ltmain.sh 2015-02-21 23:31:32.307735800 +0100
@@ -650,7 +650,7 @@
# On Cygwin there's no "real" PIC flag so we must build both object types
case $host_os in
- cygwin* | mingw* | pw32* | os2*)
+ cygwin* | msys* | mingw* | pw32* | os2*)
pic_mode=default
;;
esac
@@ -885,19 +885,19 @@
link | relink)
modename="$modename: link"
case $host in
- *-*-cygwin* | *-*-mingw* | *-*-pw32* | *-*-os2*)
+ *-*-cygwin* | *-*-msys* | *-*-mingw* | *-*-pw32* | *-*-os2*)
# It is impossible to link a dll without this setting, and
# we shouldn't force the makefile maintainer to figure out
# which system we are compiling for in order to pass an extra
# flag for every libtool invocation.
- # allow_undefined=no
+ allow_undefined=no
# FIXME: Unfortunately, there are problems with the above when trying
# to make a dll which has undefined symbols, in which case not
# even a static library is built. For now, we need to specify
# -no-undefined on the libtool link line when we can be certain
# that all symbols are satisfied, otherwise we get a static library.
- allow_undefined=yes
+ # allow_undefined=yes
;;
*)
allow_undefined=yes
@@ -1326,7 +1326,7 @@
;;
esac
case $host in
- *-*-cygwin* | *-*-mingw* | *-*-pw32* | *-*-os2*)
+ *-*-cygwin* | *-*-msys* | *-*-mingw* | *-*-pw32* | *-*-os2*)
case :$dllsearchpath: in
*":$dir:"*) ;;
*) dllsearchpath="$dllsearchpath:$dir";;
@@ -1339,7 +1339,7 @@
-l*)
if test "X$arg" = "X-lc" || test "X$arg" = "X-lm"; then
case $host in
- *-*-cygwin* | *-*-pw32* | *-*-beos*)
+ *-*-cygwin* | *-*-msys* | *-*-pw32* | *-*-beos*)
# These systems don't actually have a C or math library (as such)
continue
;;
@@ -1413,7 +1413,7 @@
-no-install)
case $host in
- *-*-cygwin* | *-*-mingw* | *-*-pw32* | *-*-os2*)
+ *-*-cygwin* | *-*-msys* | *-*-mingw* | *-*-pw32* | *-*-os2*)
# The PATH hackery in wrapper scripts is required on Windows
# in order for the loader to find any dlls it needs.
$echo "$modename: warning: \`-no-install' is ignored for $host" 1>&2
@@ -1760,7 +1760,7 @@
esac
case $host in
- *cygwin* | *mingw* | *pw32*)
+ *cygwin* | *msys* | *mingw* | *pw32*)
# don't eliminate duplications in $postdeps and $predeps
duplicate_compiler_generated_deps=yes
;;
@@ -2330,7 +2330,7 @@
elif test -n "$soname_spec"; then
# bleh windows
case $host in
- *cygwin* | mingw*)
+ *cygwin* | msys* | mingw*)
major=`expr $current - $age`
versuffix="-$major"
;;
@@ -3193,7 +3193,7 @@
if test "$build_libtool_libs" = yes; then
if test -n "$rpath"; then
case $host in
- *-*-cygwin* | *-*-mingw* | *-*-pw32* | *-*-os2* | *-*-beos*)
+ *-*-cygwin* | *-*-msys* | *-*-mingw* | *-*-pw32* | *-*-os2* | *-*-beos*)
# these systems don't actually have a c library (as such)!
;;
*-*-rhapsody* | *-*-darwin1.[012])
@@ -4106,7 +4106,7 @@
prog)
case $host in
- *cygwin*) output=`$echo $output | ${SED} -e 's,.exe$,,;s,$,.exe,'` ;;
+ *cygwin* | *msys*) output=`$echo $output | ${SED} -e 's,.exe$,,;s,$,.exe,'` ;;
esac
if test -n "$vinfo"; then
$echo "$modename: warning: \`-version-info' is ignored for programs" 1>&2
@@ -4184,7 +4184,7 @@
esac
fi
case $host in
- *-*-cygwin* | *-*-mingw* | *-*-pw32* | *-*-os2*)
+ *-*-cygwin* | *-*-msys* | *-*-mingw* | *-*-pw32* | *-*-os2*)
case :$dllsearchpath: in
*":$libdir:"*) ;;
*) dllsearchpath="$dllsearchpath:$libdir";;
@@ -4581,13 +4581,13 @@
esac
# test for cygwin because mv fails w/o .exe extensions
case $host in
- *cygwin*)
+ *cygwin* | *msys*)
exeext=.exe
outputname=`$echo $outputname|${SED} 's,.exe$,,'` ;;
*) exeext= ;;
esac
case $host in
- *cygwin* | *mingw* )
+ *cygwin* | *msys* | *mingw* )
cwrappersource=`$echo ${objdir}/lt-${output}.c`
cwrapper=`$echo ${output}.exe`
$rm $cwrappersource $cwrapper
@@ -5235,7 +5235,7 @@
# place dlname in correct position for cygwin
tdlname=$dlname
case $host,$output,$installed,$module,$dlname in
- *cygwin*,*lai,yes,no,*.dll | *mingw*,*lai,yes,no,*.dll) tdlname=../bin/$dlname ;;
+ *cygwin*,*lai,yes,no,*.dll | *msys*,*lai,yes,no,*.dll | *mingw*,*lai,yes,no,*.dll) tdlname=../bin/$dlname ;;
esac
$echo > $output "\
# $outputname - a libtool library file
@@ -5634,7 +5634,7 @@
# Do a test to see if this is really a libtool program.
case $host in
- *cygwin*|*mingw*)
+ *cygwin*|*msys*|*mingw*)
wrapper=`$echo $file | ${SED} -e 's,.exe$,,'`
;;
*)
@@ -5649,7 +5649,7 @@
# finese the cygwin/MSYS system by explicitly sourcing "foo."
# which disallows the automatic-append-.exe behavior.
case $build in
- *cygwin* | *mingw*) wrapperdot=${wrapper}. ;;
+ *cygwin* | *msys* | *mingw*) wrapperdot=${wrapper}. ;;
*) wrapperdot=${wrapper} ;;
esac
# If there is no directory component, then add one.
@@ -5687,7 +5687,7 @@
# finese the cygwin/MSYS system by explicitly sourcing "foo."
# which disallows the automatic-append-.exe behavior.
case $build in
- *cygwin* | *mingw*) wrapperdot=${wrapper}. ;;
+ *cygwin* | *msys* | *mingw*) wrapperdot=${wrapper}. ;;
*) wrapperdot=${wrapper} ;;
esac
# If there is no directory component, then add one.
@@ -5736,7 +5736,7 @@
# remove .exe since cygwin /usr/bin/install will append another
# one anyways
case $install_prog,$host in
- */usr/bin/install*,*cygwin*)
+ */usr/bin/install*,*cygwin* | */usr/bin/install*,*msys*)
case $file:$destfile in
*.exe:*.exe)
# this is ok
--- a/configure.orig 2004-07-20 01:01:47.000000000 +0200
+++ b/configure 2015-02-22 17:33:12.096996400 +0100
@@ -4609,7 +4609,7 @@
lt_cv_file_magic_test_file=/shlib/libc.so
;;
-cygwin*)
+cygwin* | msys*)
# func_win32_libid is a shell function defined in ltmain.sh
lt_cv_deplibs_check_method='file_magic ^x86 archive import|^x86 DLL'
lt_cv_file_magic_cmd='func_win32_libid'
@@ -6296,7 +6296,7 @@
lt_cv_sys_max_cmd_len=-1;
;;
- cygwin* | mingw*)
+ cygwin* | msys* | mingw*)
# On Win9x/ME, this test blows up -- it succeeds, but takes
# about 5 minutes as the teststring grows exponentially.
# Worse, since 9x/ME are not pre-emptively multitasking,
@@ -6377,7 +6377,7 @@
aix*)
symcode='[BCDT]'
;;
-cygwin* | mingw* | pw32*)
+cygwin* | msys* | mingw* | pw32*)
symcode='[ABCDGISTW]'
;;
hpux*) # Its linker distinguishes data from code symbols
@@ -7210,7 +7210,7 @@
lt_prog_compiler_pic='-m68020 -resident32 -malways-restore-a4'
;;
- beos* | cygwin* | irix5* | irix6* | nonstopux* | osf3* | osf4* | osf5*)
+ beos* | cygwin* | msys* | irix5* | irix6* | nonstopux* | osf3* | osf4* | osf5*)
# PIC is the default for these OSes.
;;
@@ -7541,7 +7541,7 @@
extract_expsyms_cmds=
case $host_os in
- cygwin* | mingw* | pw32*)
+ cygwin* | msys* | mingw* | pw32*)
# FIXME: the MSVC++ port hasn't been tested in a loooong time
# When not using gcc, we currently assume that we are using
# Microsoft Visual C++.
@@ -7602,7 +7602,7 @@
fi
;;
- cygwin* | mingw* | pw32*)
+ cygwin* | msys* | mingw* | pw32*)
# _LT_AC_TAGVAR(hardcode_libdir_flag_spec, ) is actually meaningless,
# as there is no search path for DLLs.
hardcode_libdir_flag_spec='-L$libdir'
@@ -7957,7 +7957,7 @@
export_dynamic_flag_spec=-rdynamic
;;
- cygwin* | mingw* | pw32*)
+ cygwin* | msys* | mingw* | pw32*)
# When not using gcc, we currently assume that we are using
# Microsoft Visual C++.
# hardcode_libdir_flag_spec is actually meaningless, as there is
@@ -8534,14 +8534,14 @@
# libtool to hard-code these into programs
;;
-cygwin* | mingw* | pw32*)
+cygwin* | msys* | mingw* | pw32*)
version_type=windows
shrext_cmds=".dll"
need_version=no
need_lib_prefix=no
case $GCC,$host_os in
- yes,cygwin* | yes,mingw* | yes,pw32*)
+ yes,cygwin* | yes,msys* | yes,mingw* | yes,pw32*)
library_names_spec='$libname.dll.a'
# DLL is installed to $(libdir)/../bin by postinstall_cmds
postinstall_cmds='base_file=`basename \${file}`~
@@ -8560,6 +8560,11 @@
soname_spec='`echo ${libname} | sed -e 's/^lib/cyg/'``echo ${release} | $SED -e 's/[.]/-/g'`${versuffix}${shared_ext}'
sys_lib_search_path_spec="/usr/lib /lib/w32api /lib /usr/local/lib"
;;
+ msys*)
+ # MSYS2 DLLs use 'msys-' prefix rather than 'lib'
+ soname_spec='`echo ${libname} | sed -e 's/^lib/msys-/'``echo ${release} | $SED -e 's/[.]/-/g'`${versuffix}${shared_ext}'
+ sys_lib_search_path_spec="/usr/lib /lib/w32api /lib /usr/local/lib"
+ ;;
mingw*)
# MinGW DLLs use traditional 'lib' prefix
soname_spec='${libname}`echo ${release} | $SED -e 's/[.]/-/g'`${versuffix}${shared_ext}'
@@ -9060,7 +9065,7 @@
lt_cv_dlopen_libs=
;;
- cygwin*)
+ cygwin* | msys*)
lt_cv_dlopen="dlopen"
lt_cv_dlopen_libs=
;;
@@ -10920,7 +10925,7 @@
esac
;;
- cygwin* | mingw* | pw32*)
+ cygwin* | msys* | mingw* | pw32*)
# _LT_AC_TAGVAR(hardcode_libdir_flag_spec, CXX) is actually meaningless,
# as there is no search path for DLLs.
hardcode_libdir_flag_spec_CXX='-L$libdir'
@@ -11657,7 +11662,7 @@
# like `-m68040'.
lt_prog_compiler_pic_CXX='-m68020 -resident32 -malways-restore-a4'
;;
- beos* | cygwin* | irix5* | irix6* | nonstopux* | osf3* | osf4* | osf5*)
+ beos* | cygwin* | msys* | irix5* | irix6* | nonstopux* | osf3* | osf4* | osf5*)
# PIC is the default for these OSes.
;;
mingw* | os2* | pw32*)
@@ -12040,7 +12045,7 @@
pw32*)
export_symbols_cmds_CXX="$ltdll_cmds"
;;
- cygwin* | mingw*)
+ cygwin* | msys* | mingw*)
export_symbols_cmds_CXX='$NM $libobjs $convenience | $global_symbol_pipe | $SED -e '\''/^[BCDGS] /s/.* \([^ ]*\)/\1 DATA/'\'' | $SED -e '\''/^[AITW] /s/.* //'\'' | sort | uniq > $export_symbols'
;;
linux*)
@@ -12238,14 +12243,14 @@
# libtool to hard-code these into programs
;;
-cygwin* | mingw* | pw32*)
+cygwin* | msys* | mingw* | pw32*)
version_type=windows
shrext_cmds=".dll"
need_version=no
need_lib_prefix=no
case $GCC,$host_os in
- yes,cygwin* | yes,mingw* | yes,pw32*)
+ yes,cygwin* | yes,msys* | yes,mingw* | yes,pw32*)
library_names_spec='$libname.dll.a'
# DLL is installed to $(libdir)/../bin by postinstall_cmds
postinstall_cmds='base_file=`basename \${file}`~
@@ -12264,6 +12269,11 @@
soname_spec='`echo ${libname} | sed -e 's/^lib/cyg/'``echo ${release} | $SED -e 's/[.]/-/g'`${versuffix}${shared_ext}'
sys_lib_search_path_spec="/usr/lib /lib/w32api /lib /usr/local/lib"
;;
+ msys*)
+ # MSYS2 DLLs use 'msys-' prefix rather than 'lib'
+ soname_spec='`echo ${libname} | sed -e 's/^lib/msys-/'``echo ${release} | $SED -e 's/[.]/-/g'`${versuffix}${shared_ext}'
+ sys_lib_search_path_spec="/usr/lib /lib/w32api /lib /usr/local/lib"
+ ;;
mingw*)
# MinGW DLLs use traditional 'lib' prefix
soname_spec='${libname}`echo ${release} | $SED -e 's/[.]/-/g'`${versuffix}${shared_ext}'
@@ -12764,7 +12774,7 @@
lt_cv_dlopen_libs=
;;
- cygwin*)
+ cygwin* | msys*)
lt_cv_dlopen="dlopen"
lt_cv_dlopen_libs=
;;
@@ -14087,7 +14097,7 @@
lt_prog_compiler_pic_F77='-m68020 -resident32 -malways-restore-a4'
;;
- beos* | cygwin* | irix5* | irix6* | nonstopux* | osf3* | osf4* | osf5*)
+ beos* | cygwin* | msys* | irix5* | irix6* | nonstopux* | osf3* | osf4* | osf5*)
# PIC is the default for these OSes.
;;
@@ -14418,7 +14428,7 @@
extract_expsyms_cmds=
case $host_os in
- cygwin* | mingw* | pw32*)
+ cygwin* | msys* | mingw* | pw32*)
# FIXME: the MSVC++ port hasn't been tested in a loooong time
# When not using gcc, we currently assume that we are using
# Microsoft Visual C++.
@@ -14479,7 +14489,7 @@
fi
;;
- cygwin* | mingw* | pw32*)
+ cygwin* | msys* | mingw* | pw32*)
# _LT_AC_TAGVAR(hardcode_libdir_flag_spec, F77) is actually meaningless,
# as there is no search path for DLLs.
hardcode_libdir_flag_spec_F77='-L$libdir'
@@ -14814,7 +14824,7 @@
export_dynamic_flag_spec_F77=-rdynamic
;;
- cygwin* | mingw* | pw32*)
+ cygwin* | msys* | mingw* | pw32*)
# When not using gcc, we currently assume that we are using
# Microsoft Visual C++.
# hardcode_libdir_flag_spec is actually meaningless, as there is
@@ -15391,14 +15401,14 @@
# libtool to hard-code these into programs
;;
-cygwin* | mingw* | pw32*)
+cygwin* | msys* | mingw* | pw32*)
version_type=windows
shrext_cmds=".dll"
need_version=no
need_lib_prefix=no
case $GCC,$host_os in
- yes,cygwin* | yes,mingw* | yes,pw32*)
+ yes,cygwin* | yes,msys* | yes,mingw* | yes,pw32*)
library_names_spec='$libname.dll.a'
# DLL is installed to $(libdir)/../bin by postinstall_cmds
postinstall_cmds='base_file=`basename \${file}`~
@@ -15417,6 +15427,11 @@
soname_spec='`echo ${libname} | sed -e 's/^lib/cyg/'``echo ${release} | $SED -e 's/[.]/-/g'`${versuffix}${shared_ext}'
sys_lib_search_path_spec="/usr/lib /lib/w32api /lib /usr/local/lib"
;;
+ msys*)
+ # MSYS2 DLLs use 'msys-' prefix rather than 'lib'
+ soname_spec='`echo ${libname} | sed -e 's/^lib/msys-/'``echo ${release} | $SED -e 's/[.]/-/g'`${versuffix}${shared_ext}'
+ sys_lib_search_path_spec="/usr/lib /lib/w32api /lib /usr/local/lib"
+ ;;
mingw*)
# MinGW DLLs use traditional 'lib' prefix
soname_spec='${libname}`echo ${release} | $SED -e 's/[.]/-/g'`${versuffix}${shared_ext}'
@@ -16425,7 +16440,7 @@
lt_prog_compiler_pic_GCJ='-m68020 -resident32 -malways-restore-a4'
;;
- beos* | cygwin* | irix5* | irix6* | nonstopux* | osf3* | osf4* | osf5*)
+ beos* | cygwin* | msys* | irix5* | irix6* | nonstopux* | osf3* | osf4* | osf5*)
# PIC is the default for these OSes.
;;
@@ -16756,7 +16771,7 @@
extract_expsyms_cmds=
case $host_os in
- cygwin* | mingw* | pw32*)
+ cygwin* | msys* | mingw* | pw32*)
# FIXME: the MSVC++ port hasn't been tested in a loooong time
# When not using gcc, we currently assume that we are using
# Microsoft Visual C++.
@@ -16817,7 +16832,7 @@
fi
;;
- cygwin* | mingw* | pw32*)
+ cygwin* | msys* | mingw* | pw32*)
# _LT_AC_TAGVAR(hardcode_libdir_flag_spec, GCJ) is actually meaningless,
# as there is no search path for DLLs.
hardcode_libdir_flag_spec_GCJ='-L$libdir'
@@ -17172,7 +17187,7 @@
export_dynamic_flag_spec_GCJ=-rdynamic
;;
- cygwin* | mingw* | pw32*)
+ cygwin* | msys* | mingw* | pw32*)
# When not using gcc, we currently assume that we are using
# Microsoft Visual C++.
# hardcode_libdir_flag_spec is actually meaningless, as there is
@@ -17749,14 +17764,14 @@
# libtool to hard-code these into programs
;;
-cygwin* | mingw* | pw32*)
+cygwin* | msys* | mingw* | pw32*)
version_type=windows
shrext_cmds=".dll"
need_version=no
need_lib_prefix=no
case $GCC,$host_os in
- yes,cygwin* | yes,mingw* | yes,pw32*)
+ yes,cygwin* | yes,msys* | yes,mingw* | yes,pw32*)
library_names_spec='$libname.dll.a'
# DLL is installed to $(libdir)/../bin by postinstall_cmds
postinstall_cmds='base_file=`basename \${file}`~
@@ -17775,6 +17790,11 @@
soname_spec='`echo ${libname} | sed -e 's/^lib/cyg/'``echo ${release} | $SED -e 's/[.]/-/g'`${versuffix}${shared_ext}'
sys_lib_search_path_spec="/usr/lib /lib/w32api /lib /usr/local/lib"
;;
+ msys*)
+ # MSYS2 DLLs use 'msys-' prefix rather than 'lib'
+ soname_spec='`echo ${libname} | sed -e 's/^lib/msys-/'``echo ${release} | $SED -e 's/[.]/-/g'`${versuffix}${shared_ext}'
+ sys_lib_search_path_spec="/usr/lib /lib/w32api /lib /usr/local/lib"
+ ;;
mingw*)
# MinGW DLLs use traditional 'lib' prefix
soname_spec='${libname}`echo ${release} | $SED -e 's/[.]/-/g'`${versuffix}${shared_ext}'
@@ -18275,7 +18295,7 @@
lt_cv_dlopen_libs=
;;
- cygwin*)
+ cygwin* | msys*)
lt_cv_dlopen="dlopen"
lt_cv_dlopen_libs=
;;
@@ -31411,7 +31431,7 @@
if test "X$GCC" = Xyes; then
case $host_os in
-cygwin* | mingw* | pw32*)
+cygwin* | msys* | mingw* | pw32*)
LIBS="$LIBS -lwinmm" ;;
*)
;;

View File

@ -1,7 +1,30 @@
https://dev.openwrt.org/browser/packages/libs/ucl/patches/001-autoconf-compat.patch?rev=24363
--- a/configure.ac
+++ b/configure.ac
@@ -48,7 +48,7 @@ AC_CANONICAL_TARGET
--- ucl-1.03/Makefile.am.orig 2004-07-20 01:01:47.000000000 +0200
+++ ucl-1.03/Makefile.am 2013-03-13 21:25:41.453183500 +0100
@@ -3,7 +3,8 @@
# Copyright (C) 1996-2004 Markus F.X.J. Oberhumer
#
-AUTOMAKE_OPTIONS = 1.8.5 foreign
+AUTOMAKE_OPTIONS = 1.14
+ACLOCAL_AMFLAGS = -I m4
SUBDIRS = include src examples
--- ucl-1.03/configure.ac.orig 2004-07-20 01:01:47.000000000 +0200
+++ ucl-1.03/configure.ac 2013-03-13 21:25:41.453183500 +0100
@@ -36,9 +36,10 @@ All Rights Reserved.
This configure script may be copied, distributed and modified under the
terms of the GNU General Public License; see COPYING for more details.])
-AC_PREREQ(2.59)
+AC_PREREQ(2.69)
AC_INIT(ucl,1.03,markus@oberhumer.com)
AC_MSG_NOTICE([Configuring UCL $PACKAGE_VERSION])
+AC_CONFIG_MACRO_DIR([m4])
AC_CONFIG_SRCDIR(src/ucl_init.c)
AC_CONFIG_AUX_DIR(acconfig)
AC_PREFIX_DEFAULT(/usr/local)
@@ -48,7 +49,7 @@ AC_CANONICAL_TARGET
AM_MAINTAINER_MODE
if test -z "$ac_abs_top_srcdir"; then
@ -10,3 +33,29 @@ https://dev.openwrt.org/browser/packages/libs/ucl/patches/001-autoconf-compat.pa
fi
if test -r .Conf.settings1; then
. ./.Conf.settings1
--- ucl-1.03/examples/Makefile.am.orig 2004-07-20 01:01:47.000000000 +0200
+++ ucl-1.03/examples/Makefile.am 2013-03-13 21:25:41.453183500 +0100
@@ -3,7 +3,7 @@
# Copyright (C) 1996-2004 Markus F.X.J. Oberhumer
#
-INCLUDES = -I$(top_srcdir)/include -I$(top_srcdir)
+AM_CPPFLAGS = -I$(top_srcdir)/include -I$(top_srcdir)
noinst_PROGRAMS = simple uclpack
--- ucl-1.03/src/Makefile.am.orig 2004-07-20 01:01:47.000000000 +0200
+++ ucl-1.03/src/Makefile.am 2013-03-13 21:25:41.453183500 +0100
@@ -6,9 +6,9 @@
VPATH = @srcdir@@UCL_ASM_VPATH@
SUFFIXES = .S
-INCLUDES = -I$(top_srcdir)/include -I$(top_srcdir)
-CPPFLAGS = $(UCL_CPPFLAGS) $(configure_CPPFLAGS) $(UCL_EXTRA_CPPFLAGS)
-CFLAGS = $(UCL_CFLAGS) $(configure_CFLAGS) $(UCL_EXTRA_CFLAGS)
+AM_CPPFLAGS = -I$(top_srcdir)/include -I$(top_srcdir)
+AM_CPPFLAGS += $(UCL_CPPFLAGS) $(configure_CPPFLAGS) $(UCL_EXTRA_CPPFLAGS)
+AM_CFLAGS = $(UCL_CFLAGS) $(configure_CFLAGS) $(UCL_EXTRA_CFLAGS)
lib_LTLIBRARIES = libucl.la

View File

@ -1,22 +1,23 @@
https://dev.openwrt.org/browser/packages/libs/ucl/patches/002-missing-macros.patch?rev=24363
--- /dev/null
+++ b/acinclude.m4
@@ -0,0 +1,361 @@
diff -Naur ucl-1.03-orig/local.m4 ucl-1.03/local.m4
--- ucl-1.03-orig/m4/local.m4 1970-01-01 03:00:00.000000000 +0300
+++ ucl-1.03/m4/local.m4 2015-02-04 14:24:51.000000000 +0300
@@ -0,0 +1,288 @@
+
+# /***********************************************************************
+# // standard ACC macros
+# ************************************************************************/
+
+AC_DEFUN([mfx_ACC_CHECK_ENDIAN], [
+AC_C_BIGENDIAN([AC_DEFINE(ACC_ABI_BIG_ENDIAN,1,[Define to 1 if your machine is big endian.])],[AC_DEFINE(ACC_ABI_LITTLE_ENDIAN,1,[Define to 1 if your machine is little endian.])])
+AC_C_BIGENDIAN([AC_DEFINE(ACC_ENDIAN_BIG_ENDIAN,1,[Define to 1 if your machine is big endian.])],[AC_DEFINE(ACC_ENDIAN_LITTLE_ENDIAN,1,[Define to 1 if your machine is little endian.])])
+])#
+
+AC_DEFUN([mfx_ACC_CHECK_HEADERS], [
+AC_HEADER_TIME
+AC_CHECK_HEADERS([assert.h ctype.h dirent.h errno.h fcntl.h float.h limits.h malloc.h memory.h setjmp.h signal.h stdarg.h stddef.h stdint.h stdio.h stdlib.h string.h strings.h time.h unistd.h utime.h sys/mman.h sys/resource.h sys/stat.h sys/time.h sys/types.h sys/wait.h])
+AC_CHECK_HEADERS([assert.h ctype.h dirent.h errno.h fcntl.h limits.h malloc.h memory.h setjmp.h signal.h stdarg.h stddef.h stdint.h stdio.h stdlib.h string.h strings.h time.h unistd.h utime.h sys/stat.h sys/time.h sys/types.h])
+])#
+
+AC_DEFUN([mfx_ACC_CHECK_FUNCS], [
+AC_CHECK_FUNCS(access alloca atexit atoi atol chmod chown clock_getcpuclockid clock_getres clock_gettime ctime difftime fstat getenv getpagesize getrusage gettimeofday gmtime isatty localtime longjmp lstat memcmp memcpy memmove memset mkdir mktime mmap mprotect munmap qsort raise rmdir setjmp signal snprintf strcasecmp strchr strdup strerror strftime stricmp strncasecmp strnicmp strrchr strstr time umask utime vsnprintf)
+AC_CHECK_FUNCS(access alloca atexit atoi atol chmod chown ctime difftime fstat gettimeofday gmtime localtime longjmp lstat memcmp memcpy memmove memset mktime qsort raise setjmp signal snprintf strcasecmp strchr strdup strerror strftime stricmp strncasecmp strnicmp strrchr strstr time umask utime vsnprintf)
+])#
+
+
@ -25,15 +26,15 @@ https://dev.openwrt.org/browser/packages/libs/ucl/patches/002-missing-macros.pat
+AC_CHECK_SIZEOF(int)
+AC_CHECK_SIZEOF(long)
+
+AC_CHECK_SIZEOF(long long)
+AC_CHECK_SIZEOF(__int16)
+AC_CHECK_SIZEOF(__int32)
+AC_CHECK_SIZEOF(__int64)
+
+AC_CHECK_SIZEOF(ptrdiff_t)
+AC_CHECK_SIZEOF(size_t)
+AC_CHECK_SIZEOF(void *)
+AC_CHECK_SIZEOF(char *)
+AC_CHECK_SIZEOF(size_t)
+AC_CHECK_SIZEOF(ptrdiff_t)
+
+AC_CHECK_SIZEOF(long long)
+AC_CHECK_SIZEOF(unsigned long long)
+AC_CHECK_SIZEOF(__int64)
+AC_CHECK_SIZEOF(unsigned __int64)
+])#
+
+
@ -99,75 +100,8 @@ https://dev.openwrt.org/browser/packages/libs/ucl/patches/002-missing-macros.pat
+])# mfx_ACC_ACCCHK
+
+
+# /***********************************************************************
+# // Check for ACC_conformance
+# ************************************************************************/
+
+AC_DEFUN([mfx_MINIACC_ACCCHK], [
+mfx_tmp=$1
+mfx_save_CPPFLAGS=$CPPFLAGS
+dnl in Makefile.in $(INCLUDES) will be before $(CPPFLAGS), so we mimic this here
+test "X$mfx_tmp" = "X" || CPPFLAGS="$mfx_tmp $CPPFLAGS"
+
+AC_MSG_CHECKING([whether your compiler passes the ACC conformance test])
+
+AC_LANG_CONFTEST([AC_LANG_PROGRAM(
+[[#define ACC_CONFIG_NO_HEADER 1
+#define ACC_WANT_ACC_INCD_H 1
+#include $2
+
+#define ACC_WANT_ACC_CHK_CH 1
+#undef ACCCHK_ASSERT
+#define ACCCHK_ASSERT(expr) ACC_COMPILE_TIME_ASSERT_HEADER(expr)
+#include $2
+
+#define ACC_WANT_ACC_CHK_CH 1
+#undef ACCCHK_ASSERT
+#define ACCCHK_ASSERT(expr) ACC_COMPILE_TIME_ASSERT(expr)
+static void test_acc_compile_time_assert(void) {
+#include $2
+}
+
+#undef NDEBUG
+#include <assert.h>
+#define ACC_WANT_ACC_CHK_CH 1
+#undef ACCCHK_ASSERT
+#define ACCCHK_ASSERT(expr) assert(expr);
+static int test_acc_run_time_assert(int r) {
+#include $2
+return r;
+}
+]], [[
+test_acc_compile_time_assert();
+if (test_acc_run_time_assert(1) != 1) return 1;
+]]
+)])
+
+mfx_tmp=FAILED
+_AC_COMPILE_IFELSE([], [mfx_tmp=yes])
+rm -f conftest.$ac_ext conftest.$ac_objext
+
+CPPFLAGS=$mfx_save_CPPFLAGS
+
+AC_MSG_RESULT([$mfx_tmp])
+case x$mfx_tmp in
+ xpassed | xyes) ;;
+ *)
+ AC_MSG_NOTICE([])
+ AC_MSG_NOTICE([Your compiler failed the ACC conformance test - for details see ])
+ AC_MSG_NOTICE([`config.log'. Please check that log file and consider sending])
+ AC_MSG_NOTICE([a patch or bug-report to <${PACKAGE_BUGREPORT}>.])
+ AC_MSG_NOTICE([Thanks for your support.])
+ AC_MSG_NOTICE([])
+ AC_MSG_ERROR([ACC conformance test failed. Stop.])
+dnl AS_EXIT
+ ;;
+esac
+])# mfx_MINIACC_ACCCHK
+
+
+
+# serial 1
+# dnl serial 1
+
+AC_DEFUN([mfx_PROG_CPPFLAGS], [
+AC_MSG_CHECKING([whether the C preprocessor needs special flags])
@ -209,12 +143,14 @@ https://dev.openwrt.org/browser/packages/libs/ucl/patches/002-missing-macros.pat
+esac
+])# mfx_PROG_CPPFLAGS
+
+# serial 3
+
+
+# dnl serial 3
+
+AC_DEFUN([mfx_CHECK_HEADER_SANE_LIMITS_H], [
+AC_CACHE_CHECK([whether limits.h is sane],
+mfx_cv_header_sane_limits_h,
+[AC_COMPILE_IFELSE([AC_LANG_PROGRAM([[#include <limits.h>
+[AC_TRY_COMPILE([#include <limits.h>
+#if (32767 >= 4294967295ul) || (65535u >= 4294967295ul)
+# if defined(__APPLE__) && defined(__GNUC__)
+# error "your preprocessor is broken - use compiler option -no-cpp-precomp"
@ -278,7 +214,7 @@ https://dev.openwrt.org/browser/packages/libs/ucl/patches/002-missing-macros.pat
+#if (UINT_MAX > ULONG_MAX)
+# include "error UINT_MAX vs ULONG_MAX"
+#endif
+]], [[
+],[
+#if (USHRT_MAX == MFX_0xffff)
+{ typedef char a_short2a[1 - 2 * !(sizeof(short) == 2)]; }
+#elif (USHRT_MAX >= MFX_0xffff)
@ -294,13 +230,11 @@ https://dev.openwrt.org/browser/packages/libs/ucl/patches/002-missing-macros.pat
+#elif (ULONG_MAX >= MFX_0xffff)
+{ typedef char a_long2b[1 - 2 * !(sizeof(long) > 2)]; }
+#endif
+#if !defined(_CRAY1) /* CRAY PVP systems */
+#if (USHRT_MAX == MFX_0xffffffffL)
+{ typedef char a_short4a[1 - 2 * !(sizeof(short) == 4)]; }
+#elif (USHRT_MAX >= MFX_0xffffffffL)
+{ typedef char a_short4b[1 - 2 * !(sizeof(short) > 4)]; }
+#endif
+#endif /* _CRAY1 */
+#if (UINT_MAX == MFX_0xffffffffL)
+{ typedef char a_int4a[1 - 2 * !(sizeof(int) == 4)]; }
+#elif (UINT_MAX >= MFX_0xffffffffL)
@ -311,21 +245,12 @@ https://dev.openwrt.org/browser/packages/libs/ucl/patches/002-missing-macros.pat
+#elif (ULONG_MAX >= MFX_0xffffffffL)
+{ typedef char a_long4b[1 - 2 * !(sizeof(long) > 4)]; }
+#endif
+]])],
+[mfx_cv_header_sane_limits_h=yes],
+[mfx_cv_header_sane_limits_h=no])])
+],
+mfx_cv_header_sane_limits_h=yes,
+mfx_cv_header_sane_limits_h=no)])
+])
+
+# /***********************************************************************
+# // standard
+# ************************************************************************/
+
+AC_DEFUN([mfx_LZO_CHECK_ENDIAN], [
+AC_C_BIGENDIAN([AC_DEFINE(LZO_ABI_BIG_ENDIAN,1,[Define to 1 if your machine is big endian.])],[AC_DEFINE(LZO_ABI_LITTLE_ENDIAN,1,[Define to 1 if your machine is little endian.])])
+])#
+
+
+# /***********************************************************************
+# //
+# ************************************************************************/
+
@ -333,6 +258,7 @@ https://dev.openwrt.org/browser/packages/libs/ucl/patches/002-missing-macros.pat
+
+AC_DEFUN([mfx_CHECK_SIZEOF], [
+AC_CHECK_SIZEOF(__int32)
+AC_CHECK_SIZEOF(unsigned __int32)
+AC_CHECK_SIZEOF(intmax_t)
+AC_CHECK_SIZEOF(uintmax_t)
+AC_CHECK_SIZEOF(intptr_t)
@ -355,11 +281,12 @@ https://dev.openwrt.org/browser/packages/libs/ucl/patches/002-missing-macros.pat
+AC_DEFUN([mfx_CHECK_LIB_WINMM], [
+if test "X$GCC" = Xyes; then
+case $host_os in
+cygwin* | mingw* | pw32*)
+ test "X$LIBS" != "X" && LIBS="$LIBS "
+ LIBS="${LIBS}-lwinmm" ;;
+cygwin* | msys* | mingw* | pw32*)
+ LIBS="$LIBS -lwinmm" ;;
+*)
+ ;;
+esac
+fi
+])#
+
+

View File

@ -0,0 +1,11 @@
--- ucl-1.03/src/Makefile.am.orig 2015-02-22 22:24:15.619000000 +0300
+++ ucl-1.03/src/Makefile.am 2015-02-22 22:24:26.663800000 +0300
@@ -12,7 +12,7 @@
lib_LTLIBRARIES = libucl.la
-libucl_la_LDFLAGS = -version-info 1:0:0
+libucl_la_LDFLAGS = -version-info 1:0:0 -no-undefined
libucl_la_SOURCES = \
alloc.c \

View File

@ -5,44 +5,63 @@
# Contributor (Arch Linux): arjan <arjan@archlinux.org>
# Contributor (Arch Linux): Tom Newsom <Jeepster@gmx.co.uk>
pkgname=ucl
_realname=ucl
pkgname=("ucl" "ucl-devel")
pkgver=1.03
pkgrel=1
pkgdesc="Portable lossless data compression library written in ANSI C"
arch=('i686' 'x86_64')
license=('GPL')
url="http://www.oberhumer.com/opensource/ucl/"
source=("http://www.oberhumer.com/opensource/$pkgname/download/$pkgname-$pkgver.tar.gz"
source=("http://www.oberhumer.com/opensource/${_realname}/download/${_realname}-$pkgver.tar.gz"
"000-msys2.patch"
"001-autoconf-compat.patch"
"002-missing-macros.patch")
"002-missing-macros.patch"
"003-no-undefined.patch")
md5sums=('852bd691d8abc75b52053465846fba34'
'130fd74b245e68acd6f005115f1412b0'
'7b000001507b42dcc047c8786f180d9b'
'9b596d8cec6144b6cd746efa6693e46e')
'6643b0a658d818075533e09046ce9ac9'
'd370f7a7d07a76b0bfc76c50c73aaaad'
'c18f77b87934abda7948dbbada817b14'
'39ca38f60c03df634284552e69d5b775')
prepare() {
cd "$pkgname-$pkgver"
cd "${_realname}-$pkgver"
rm -f acinclude.m4
patch -p1 -i "${srcdir}/000-msys2.patch"
patch -p1 -i "${srcdir}/001-autoconf-compat.patch"
patch -p1 -i "${srcdir}/002-missing-macros.patch"
patch -p1 -i "${srcdir}/003-no-undefined.patch"
# no luck with that
# WANT_AUTOMAKE=1.15 autoreconf -fi
touch ChangeLog
WANT_AUTOMAKE=latest autoreconf -fiv
}
build() {
cd "$pkgname-$pkgver"
cd "${_realname}-$pkgver"
./configure \
--build=${CHOST} \
--prefix=/usr \
--enable-shared \
--disable-static
--enable-static
make
make DESTDIR=${srcdir}/dest install
}
package() {
cd "$pkgname-$pkgver"
make DESTDIR="$pkgdir" install
package_ucl() {
mkdir -p ${pkgdir}/usr
cp -rf $srcdir/dest/usr/bin ${pkgdir}/usr/
install -Dm644 "${srcdir}/${pkgname}-${pkgver}/COPYING" "${pkgdir}/usr/share/licenses/${pkgname}/COPYING"
}
package_ucl-devel() {
groups=('development')
options=(staticlibs)
depends=("ucl=${pkgver}")
pkgdesc="ucl headers and libraries"
mkdir -p ${pkgdir}/usr
cp -rf $srcdir/dest/usr/include ${pkgdir}/usr/
cp -rf $srcdir/dest/usr/lib ${pkgdir}/usr/
}