On Solaris, FreeTDS 1.3.18 fails with iconv issue #496
-
Hello, On Solaris:
With following ODBCINI settings:
TDSDUMP shows the following error:
What are we doing wrong? Is it an iconv config issue on the platform, or FreeTDS? Seb |
Beta Was this translation helpful? Give feedback.
Replies: 4 comments 8 replies
-
Trying to debug the code in src/tds/iconv.c:
=> tds_sys_iconv_option() returns -1 for UCS-2BE / UCS-2LE Seb |
Beta Was this translation helpful? Give feedback.
-
I would say is your iconv implementation that has some issues. I know some systems require some additional packages to be installed. I would suggest to install and use GNU libiconv. |
Beta Was this translation helpful? Give feedback.
-
Here are some parts if the configure config.log:
|
Beta Was this translation helpful? Give feedback.
-
I think I found the problem: sh -x ./configure output revealed that it expects the iconv libs under iconv-install-dir/lib/64 or iconv-install-dir/lib/sparcv9: withval=/usr/local/tools/64bits/libiconv/1.16 But in our case, iconv libs where just under iconv-install-dir/lib ! I have created a 'sparcv9' subdir, with the shared libs inside, and now I got this in config.log: am_cv_func_iconv=yes And I could connect to SQL Server. I think the configure script should be fixed (why search in lib/64 and lib/sparcv9? Seb |
Beta Was this translation helpful? Give feedback.
Good that you found a solution. About the search it seems the M4 macro that chooses the library directories comes usually from gettext package (Ubuntu and NetBSD). Specifically the macro is
AC_LIB_PREPARE_MULTILIB
inlib-prefix.m4
. m4 macros are extended and embedded inconfigure
script. Newer version would also uselib
directory for libraries on Solaris (solib
,lib/64
andlib/sparcv9
) while version used and packaged inwww.freetds.org
just useslib/64
andlib/sparcv9
. So updatinglib-prefix.m4
and repackaging (autogen.sh
orautoconf
) should work. Not sure however where I should pick up updated relatedm4
files and how to override system files.