Keep Server Online
If you find the Apache Lounge, the downloads and overall help useful, please express your satisfaction with a donation.
or
A donation makes a contribution towards the costs, the time and effort that's going in this site and building.
Thank You! Steffen
Your donations will help to keep this site alive and well, and continuing building binaries. Apache Lounge is not sponsored.
| |
|
Topic: Compiling httpd + libapr-2 failed on Windows |
|
Author |
|
nono303
Joined: 20 Dec 2016 Posts: 207 Location: Lille, FR, EU
|
Posted: Thu 16 May '24 11:07 Post subject: Compiling httpd + libapr-2 failed on Windows |
|
|
Hi,
I currently try to compile httpd with libapr-2 (trunk) "for fun"
It’s seeming to be able to be done (see https://github.com/apache/httpd/blob/trunk/CMakeLists.txt#L35) but I’m facing some issues:
1. Compiling apr trunk with CMake (shared):
- I had to patch CMakeLists.txt to add mysql dbd support
- With APR_MODULAR_DSO=ON, APR_MODULE_DECLARE_DATA not seems to be set with __declspec(dllexport) (for apr_dbd_sqlite3 & apr_dbd_mysql) - working fine with APR_MODULAR_DSO=OFF
- LDAP support (with CMakeLists.txt to patched too) failed with many missing imports
Finally I can have a working release of libapr-2 with this config
Code: | cmake %CMAKE_OPTS% -G %CMAKE_TGT_NINJA% ^
-DCMAKE_INSTALL_PREFIX=%PATH_INSTALL% ^
-DCMAKE_BUILD_TYPE=%CMAKE_BUILD_TYPE% ^
-DAPR_MINIMAL_BUILD=OFF ^
-DAPU_HAVE_ODBC=ON ^
-DAPU_USE_EXPAT=OFF ^
-DAPU_USE_LIBXML2=ON ^
-DAPU_USE_XMLLITE=OFF ^
-DAPR_INSTALL_PRIVATE_H=ON ^
-DAPU_HAVE_SQLITE3=ON ^
-DAPU_HAVE_MYSQL=ON ^
-DAPU_HAVE_CRYPTO=ON ^
-DAPU_HAVE_ICONV=ON ^
-DAPR_HAVE_IPV6=ON ^
-DAPU_HAVE_LDAP=OFF ^
-DAPU_HAVE_ODBC=ON ^
-DINSTALL_PDB=ON ^
-DAPR_BUILD_TESTAPR=OFF ^
-DAPR_BUILD_SHARED=ON ^
-DAPR_BUILD_STATIC=OFF ^
-DAPR_MODULAR_DSO=OFF ^
-DTEST_STATIC_LIBS=OFF ^
-DOPENSSL_ROOT_DIR=%PATH_INSTALL_OSSL% ^
-DOPENSSL_INCLUDE_DIR=%PATH_INSTALL_OSSL%\include ^
-DCMAKE_MODULE_PATH=cmake ^
-DMYSQL_LIBRARY=%PATH_MYSQL:\=/%/lib/mysqlclient.lib ^
-DMYSQL_INCLUDE_DIR=%PATH_MYSQL:\=/%/include
%PATH_SRC%\%1 |
2. Compiling httpd with libapr-2 (without ldap support...)
Code: | -- APR_HAS_LDAP ............. : FALSE
-- APR_HAS_XLATE ............ : TRUE
-- APU_HAVE_CRYPTO .......... : TRUE
...
-- APR include directory ........... : C:/sdk/release/vs17_x64-avx2/include/apr-2
-- APR libraries ................... : C:/sdk/release/vs17_x64-avx2/lib/libapr-2.lib
|
I have breaking errors 'IF_WIN_OS_IS_UNICODE': undeclared identifier
And effectively, IF_WIN_OS_IS_UNICODE had disappeared from arch/win32/apr_arch_misc.h (see https://github.com/apache/apr/blob/1.8.x/include/arch/win32/apr_arch_misc.h#L140)
Is it known that libapr-2 is not supported with https on windows?
Have someone tried to do it with success?
++NoNo |
|
Back to top |
|
tangent Moderator
Joined: 16 Aug 2020 Posts: 348 Location: UK
|
Posted: Sun 09 Jun '24 20:53 Post subject: |
|
|
I've been tied up lately, so not been able to pick up on your interesting post over building libapr-2 with CMake. At some point this will be directly relevant to the Apache build with CMake How-To script I put together some years ago.
Having built libapr-2 with CMake using the apr-trunk as you did, I forsee problems ahead.
The build evidently checks for a number of support packages, viz:
Code: | -- The C compiler identification is MSVC 19.40.33811.0
-- Detecting C compiler ABI info
-- Detecting C compiler ABI info - done
-- Check for working C compiler: C:/Program Files (x86)/Microsoft Visual Studio/2022/BuildTools/VC/Tools/MSVC/14.40.33807/bin/Hostx64/x64/cl.exe - skipped
-- Detecting C compile features
-- Detecting C compile features - done
-- Found EXPAT: C:/Apache24/lib/libexpat.lib (found version "2.2.6")
-- Found LibXml2: C:/Apache24/lib/libxml2.lib (found version "2.9.9") *** => was actually 2.12.7
-- Found OpenSSL: C:/Apache24/lib/libcrypto.lib (found version "3.1.6")
-- Could NOT find Iconv (missing: Iconv_LIBRARY Iconv_INCLUDE_DIR)
-- Could NOT find SQLite3 (missing: SQLite3_INCLUDE_DIR SQLite3_LIBRARY) |
The lack of Iconv is a problem, since the official libiconv package is GNU based and doesn't currently support building with CMake. That's why to date I've stuck with the old apr-iconv package with nmake.
There are a number of GIT forks of libiconv out there, where people have crafted a CMakeLists.txt file, but they're several revisions down from the latest libiconv package at release 1.17 (2022).
Even if we can find/craft a suitable CMakeLists.txt file, I'm equally not sure where we stand LGPL license wise.
I'd want to crack this libiconv issue before trying to refine the overall HTTPD build script further. |
|
Back to top |
|
nono303
Joined: 20 Dec 2016 Posts: 207 Location: Lille, FR, EU
|
Posted: Wed 12 Jun '24 15:12 Post subject: |
|
|
Thx @tangent for your feedback!
I see that we are more or less at the same point...
Regarding libiconv, I use https://github.com/pffang/libiconv-for-Windows with MSBuild (gnu version iso src, with additional includes - probably coming from a MinGW ./configure)
Code: | config.h
include/iconv.h
include/iconv.h.inst
lib/config.h
lib/libcharset.h
lib/localcharset.h
libcharset/config.h
libcharset/include/libcharset.h
libcharset/include/libcharset.h.inst
libcharset/include/localcharset.h
libcharset/include/localcharset.h.inst |
Not CMake but the release remains fully compatible with the build chain
I can release an apr-2 binary with libiconv support but, as mentioned above, other problems are blocking its integration with httpd.
Code: | -- APR configuration summary:
--
-- Build type ...................... : RelWithDebInfo
-- Install .pdb (if available)...... : ON
-- Install prefix .................. : C:/sdk/release/vs17_x64-avx2
-- Directory for binary files .... : PREFIX/bin
-- Directory for library files ... : PREFIX/lib
-- Directory for include files ... : PREFIX/include/apr-2
-- C compiler ...................... : C:/sdk/softs/vs22/Community/VC/Tools/MSVC/14.40.33807/bin/Hostx64/x64/cl.exe
-- IPv6 ............................ : ON
-- DBD ODBC driver ................. : ON
-- DBD SQLite3 driver .............. : ON
-- DBD MySQL driver ................ : ON
-- Use Expat ....................... : OFF
-- Use LibXml2 ..................... : ON
-- Use XmlLite ..................... : OFF
-- Have Crypto ..................... : ON
-- Have Iconv ...................... : ON
-- Library files for XML ........... : C:/sdk/release/vs17_x64-avx2/lib/libxml2.lib
-- DSO build of modular components.. : OFF
-- Turn on pools debugging ..........: OFF
-- Build shared libs ............... : ON
-- Build static libs ............... : OFF
-- Build test suite ................ : OFF
-- (testing dynamic libraries)
-- Install private .h for httpd .... : ON
-- Configuring done (3.1s) |
Regarding this, I give up for the moment and will probably come back to dig when everything will be drier (or if you have some point for me to dig ) |
|
Back to top |
|
Jan-E
Joined: 09 Mar 2012 Posts: 1266 Location: Amsterdam, NL, EU
|
Posted: Wed 12 Jun '24 15:51 Post subject: |
|
|
Regarding libiconv: clone https://github.com/winlibs/libiconv
And run this in the MSVC16 dir:
Code: | msbuild libiconv.sln /t:Rebuild /p:Configuration=Release /p:Platform=x64 |
|
|
Back to top |
|
tangent Moderator
Joined: 16 Aug 2020 Posts: 348 Location: UK
|
Posted: Wed 12 Jun '24 21:11 Post subject: |
|
|
Thanks both for the feedback over libiconv. Much appreciated.
I've spent some time on this too, and since my challenge is to stick with CMake, had landed on the following site: https://github.com/vovythevov/libiconv-cmake
This provided a well structured CMakeLists.txt file as a starting point, albeit for libiconv 1.14, and have since managed to update this to build the latest release 1.17.
I've tried extending this to build iconv.exe, but accepted this relies on a GNU build environment rather than MSVC, so have for now given up. It's not essential, so when I recover I'll try using this libiconv variant to progress building with APR-2.
@nono303 - I notice you've chosen libxml2 over expat for XML support (APR-2 requires you to choose one or the other).
Extract from APR-2 CMakeLists.txt
Code: | IF(APU_USE_EXPAT AND APU_USE_LIBXML2)
MESSAGE(FATAL_ERROR "Only one of Expat and LibXml2 can be selected")
ENDIF() |
What was the reason you chose libxml2? |
|
Back to top |
|
nono303
Joined: 20 Dec 2016 Posts: 207 Location: Lille, FR, EU
|
Posted: Thu 13 Jun '24 9:52 Post subject: |
|
|
Hi @tangent,
Was looking at CMake libiconv and found https://github.com/AiMiDi/libiconv_cmake which works fine for on 1.17 (and seems to be active).
I'll stick on it.
Just have issued to apply these 2 patches: Quote: | What was the reason you chose libxml2? |
Good question!I’m clearly not an expert on that and if there are good reasons to use expat instead of libxml2, I’ll switch eyes closed 😉 |
|
Back to top |
|
James Blond Moderator
Joined: 19 Jan 2006 Posts: 7374 Location: Germany, Next to Hamburg
|
Posted: Mon 17 Jun '24 11:13 Post subject: |
|
|
Expat is part of apr-util. One of the reasons was mod_proxy_html. At first, it was a standalone project[1] but got integrated into the httpd Apache project. And for that module, you need an XML DOM parser. Expat lags that.
About libiconv, I wonder since Apache has its version[2]
[1] http://apache.webthing.com/mod_proxy_html/
[2] https://apr.apache.org/download.cgi |
|
Back to top |
|
tangent Moderator
Joined: 16 Aug 2020 Posts: 348 Location: UK
|
Posted: Mon 17 Jun '24 20:48 Post subject: |
|
|
Hi @nono303,
Re libiconv, despite several attempts I failed to build the variant at https://github.com/AiMiDi/libiconv_cmake, and accepting their CMakeLists.txt file is somewhat complicated, ended up revising the simpler CMakeLists.txt file that came with https://github.com/vovythevov/libiconv-cmake (still at release 1.14).
The variant I have builds the official libiconv-1.17 source release at https://ftp.gnu.org/gnu/libiconv, albeit without iconv.exe (am sticking to MSVC rather than a GNU build environment). However, the libraries are all we need for building APR-2 and then in turn HTTPD.
APR-2 then duly built, though I haven't tried to add dbd or sqlite3 as yet.
Concerning item 2 in your original post, compiling HTTPD with libapr-2, I've managed to reproduce the results you got, namely it failed with 'IF_WIN_OS_IS_UNICODE': undeclared identifier. And yes, if you compare apr_arch_misc.h with the variant in apr-1.7.4, it's clear this definition along with a block of related logic has been removed.
So, as it stands, it would appear HTTPD won't build with APR-2 on Windows.
I'm no developer, and so don't feel able to post anything back to the APR contributors on this, but am surprised this issue hasn't been spotted and addressed aleady. |
|
Back to top |
|
Steffen Moderator
Joined: 15 Oct 2005 Posts: 3094 Location: Hilversum, NL, EU
|
Posted: Tue 18 Jun '24 8:56 Post subject: |
|
|
Is apr_crypto_openssl-1.dll building ? |
|
Back to top |
|
nono303
Joined: 20 Dec 2016 Posts: 207 Location: Lille, FR, EU
|
Posted: Tue 18 Jun '24 12:15 Post subject: |
|
|
Hi
@tangent, concerning libiconv:
1. https://github.com/AiMiDi/libiconv_cmake works fine for me building libcharset.dll & libiconv.dll
- The two patch I issued ( https://github.com/AiMiDi/libiconv_cmake/issues?q=is%3Aissue+author%3Anono303 ) were merged at current HEAD ( https://github.com/AiMiDi/libiconv_cmake/commit/efdd10399dc49b047e6a50631e0358474a448288 )
2. for /libiconv submodule (src) you must checkout branch [fix-C2016](https://github.com/AiMiDi/libiconv/tree/fix-C2016) for MSVC build _(see https://github.com/AiMiDi/libiconv/issues/1)_
@steffen, compiling apr2 :
1. apr_crypto_openssl is building (named apr_crypto_openssl-2.dll) when DSO=ON
2. but if DSO=ON, I can’t build apr_dbd_sqlite3-2 and apr_dbd_mysql_driver with:
Code: | LNK2001: unresolved external symbol apr_dbd_sqlite3_driver / apr_dbd_mysql_driver |
only apr_dbd_odbc-2.dll can be build
I checked symbols export difference between odbc and sqlite3 / mysql to figure out the issue but didn’t see flagrant linking difference
Code: | CMakeLists.txt:659: SET_PROPERTY(TARGET apr_dbd_odbc-2 APPEND PROPERTY LINK_FLAGS /export:apr_dbd_odbc_driver)
CMakeLists.txt:670: SET_PROPERTY(TARGET apr_dbd_sqlite3-2 APPEND PROPERTY LINK_FLAGS /export:apr_dbd_sqlite3_driver)
CMakeLists.txt:682: SET_PROPERTY(TARGET apr_dbd_mysql-2 APPEND PROPERTY LINK_FLAGS /export:apr_dbd_mysql_driver)
dbd/apr_dbd_mysql.c:1303:APR_MODULE_DECLARE_DATA const apr_dbd_driver_t apr_dbd_mysql_driver
dbd/apr_dbd_odbc.c:1700:APR_MODULE_DECLARE_DATA const apr_dbd_driver_t ODBC_DRIVER_ENTRY
dbd/apr_dbd_sqlite3.c:882:APR_MODULE_DECLARE_DATA const apr_dbd_driver_t apr_dbd_sqlite3_driver |
3. if DSO=OFF I can have libapr-2 buildind with crypto_openssl dbd_mysql dbd_sqlite3 dbd_odbc embeded
4. still have ldap failing to build: sasl mandatory now for apr-2 and I don't have it on my build chain
5. finally, trying to build httpd (mod_ldap disabled) I had Code: | C:\sdk\src\httpd\os\win32\util_win32.c(35): error C2065: 'IF_WIN_OS_IS_UNICODE': undeclared identifier |
Here is my current status |
|
Back to top |
|
James Blond Moderator
Joined: 19 Jan 2006 Posts: 7374 Location: Germany, Next to Hamburg
|
|
Back to top |
|
James Blond Moderator
Joined: 19 Jan 2006 Posts: 7374 Location: Germany, Next to Hamburg
|
|
Back to top |
|
nono303
Joined: 20 Dec 2016 Posts: 207 Location: Lille, FR, EU
|
Posted: Thu 10 Oct '24 8:57 Post subject: |
|
|
Hi @here!
Quick update concerning my httpd build attemps with apr2
Using latest apr2 trunk (where CMakeLists.txt had been mostly refactored) I can have a clean release with dso support enabled, ldap disabled and MySQL support (patch is also simpler and working)
See patch and result
Now trying to build httpd...
- I fixed the undeclared identifier by switching APR_INSTALL_PRIVATE_H from ON to OFF in apr2 cmake option
- I'm now facing a libhttpd.lib linking issue
Code: | ap_regkey.c.obj : error LNK2001: unresolved external symbol __imp_apr_conv_ucs2_to_utf8
ap_regkey.c.obj : error LNK2001: unresolved external symbol __imp_apr_conv_utf8_to_ucs2 |
Ichecked that effectively, libapr-2.lib didn't have theses function entries unlike libapr-1.lib which expose them.
I had a look to apr_app.c
Code: | /* Usage Notes:
*
* this module, and the misc/win32/utf8.c modules must be
* compiled APR_EXPORT_STATIC and linked to an application with
* the /entry:wmainCRTStartup flag (which this module kindly
* provides to the developer who links to libaprapp-1.lib).
* This module becomes the true wmain entry point, and passes
* utf-8 reformatted argv and env arrays to the application's
* main() function as if nothing happened.
*
* This module is only compatible with Unicode operating systems.
* Mixed (Win9x backwards compatible) binaries should refer instead
* to the apr_startup.c module.
*
* _dbg_malloc/realloc is used in place of the usual API, in order
* to convince the MSVCRT that it created these entities. If we
* do not create them as _CRT_BLOCK entities, the crt will fault
* on an assert. We are not worrying about the crt's locks here,
* since we are single threaded [so far].
*/ |
These two functions are called in httpd:
Code: | os/win32/ap_regkey.c:80: apr_status_t rv = apr_conv_utf8_to_ucs2(keyname, &keylen, wkeyname, &wkeylen);
os/win32/ap_regkey.c:142: apr_status_t rv = apr_conv_utf8_to_ucs2(keyname, &keylen, wkeyname, &wkeylen);
os/win32/ap_regkey.c:199: rv = apr_conv_utf8_to_ucs2(valuename, &valuelen, wvalname, &wvallen);
os/win32/ap_regkey.c:240: rv = apr_conv_ucs2_to_utf8(wvalue, &size, *result, &valuelen);
os/win32/ap_regkey.c:305: rv = apr_conv_utf8_to_ucs2(valuename, &valuelen, wvalname, &wvallen);
os/win32/ap_regkey.c:313: rv = apr_conv_utf8_to_ucs2(value, &size, wvalue, &wvallen);
os/win32/ap_regkey.c:319: /* The size is the number of wchars consumed by apr_conv_utf8_to_ucs2
os/win32/ap_regkey.c:360: rv = apr_conv_utf8_to_ucs2(valuename, &valuelen, wvalname, &wvallen);
os/win32/ap_regkey.c:419: rv = apr_conv_utf8_to_ucs2(valuename, &valuelen, wvalname, &wvallen);
os/win32/ap_regkey.c:479: rv = apr_conv_ucs2_to_utf8(value, &size, buf, &valuelen);
os/win32/ap_regkey.c:560: rv = apr_conv_utf8_to_ucs2(elts[i], &size, tmp, &bufrem);
os/win32/ap_regkey.c:622: apr_status_t rv = apr_conv_utf8_to_ucs2(valuename, &valuelen, wvalname, &wvallen);
os/win32/util_win32.c:47: rv = apr_conv_ucs2_to_utf8(wbinpath, &wbinlen, *binpath, &binlen);
server/mpm/winnt/service.c:314: apr_status_t rv = apr_conv_utf8_to_ucs2(full_description, &slen,
server/mpm/winnt/service.c:385: (void)apr_conv_ucs2_to_utf8(argv[0], &wslen, service_name, &slen);
server/mpm/winnt/service.c:433: (void)apr_conv_ucs2_to_utf8(argv[i], &wslen, *(cmb++), &slen);
server/mpm/winnt/service.c:580: rv = apr_conv_utf8_to_ucs2(mpm_service_name, &slen,
server/mpm/winnt/service.c:769: rv = apr_conv_utf8_to_ucs2(mpm_display_name, &slen,
server/mpm/winnt/service.c:1099: rv = apr_conv_utf8_to_ucs2(argv[i], &slen, start_argv_w[i], &wslen); |
If someone here have some clues to upgrade httpd src with apr_app.c I would be keen to test this as a POC |
|
Back to top |
|
James Blond Moderator
Joined: 19 Jan 2006 Posts: 7374 Location: Germany, Next to Hamburg
|
Posted: Thu 10 Oct '24 16:51 Post subject: |
|
|
That function is in APR /include/arch/win32/apr_arch_utf8.h
The "__imp_" is just the call from a so / DLL
it might be a problem with the build order. |
|
Back to top |
|
nono303
Joined: 20 Dec 2016 Posts: 207 Location: Lille, FR, EU
|
Posted: Fri 11 Oct '24 7:41 Post subject: |
|
|
The two functions are declared in apr_arch_utf8.h both in apr-1 & apr-2
I don't think it's a build order because compile is working, linking is failing
Difference is APR_DECLARE in apr-1 (valued with __declspec(dllexport)) which is no more present in apr-2
apr-2.lib doesn't contain / export the functions declared in apr_arch_utf8.h
>> APR-1
Code: |
$ sif /cygdrive/c/sdk/src/apr/* apr_conv_ucs2_to_utf8
file_io/win32/open.c:130: if ((rv = apr_conv_ucs2_to_utf8(srcstr, &srcremains, t, &retlen))) {
include/arch/win32/apr_arch_utf8.h:51:APR_DECLARE(apr_status_t) apr_conv_ucs2_to_utf8(const apr_wchar_t *in,
misc/win32/apr_app.c:79: (void)apr_conv_ucs2_to_utf8(wenv[i], &wcount, env[i], &envlen);
misc/win32/env.c:85: status = apr_conv_ucs2_to_utf8(wvalue, &inchars, val, &outchars);
misc/win32/internal.c:76: (void)apr_conv_ucs2_to_utf8(arr[arg], &len,
misc/win32/start.c:68: (void)apr_conv_ucs2_to_utf8(arrsz, &wsize, strs, &newlen);
misc/win32/utf8.c:68: * apr_conv_ucs2_to_utf8 out words:sizeof(in) / 2 <= Req <= sizeof(in) * 3 / 2
misc/win32/utf8.c:182:APR_DECLARE(apr_status_t) apr_conv_ucs2_to_utf8(const apr_wchar_t *in,
$ sif /cygdrive/c/sdk/src/apr/* apr_conv_utf8_to_ucs2
dso/win32/dso.c:144: rv = apr_conv_utf8_to_ucs2(wsymname, &wsymlen, symname, &symlen);
file_io/win32/open.c:89: if ((rv = apr_conv_utf8_to_ucs2(srcstr, &srcremains, t, &retlen))) {
file_io/win32/open.c:171: if (apr_conv_utf8_to_ucs2(file, &n, wfile + r, &d)) {
include/arch/win32/apr_arch_utf8.h:37:APR_DECLARE(apr_status_t) apr_conv_utf8_to_ucs2(const char *in,
misc/win32/env.c:36: status = apr_conv_utf8_to_ucs2(envvar, &inchars, buffer, &bufflen);
misc/win32/env.c:142: status = apr_conv_utf8_to_ucs2(value, &inchars, wvalue, &outchars);
misc/win32/utf8.c:67: * apr_conv_utf8_to_ucs2 out bytes:sizeof(in) * 1 <= Req <= sizeof(in) * 2
misc/win32/utf8.c:71:APR_DECLARE(apr_status_t) apr_conv_utf8_to_ucs2(const char *in,
test/internal/testucs.c:116: rc = apr_conv_utf8_to_ucs2(s.n, &nl, s.w, &wl);
test/internal/testucs.c:230: nrc = apr_conv_utf8_to_ucs2(ntest.n, &inlen, ntest.w, &ntest.wl);
threadproc/win32/proc.c:268: if ((rv = apr_conv_utf8_to_ucs2(username, &len, wusername, &wlen))
threadproc/win32/proc.c:282: if ((rv = apr_conv_utf8_to_ucs2(password, &len, wpassword, &wlen))
threadproc/win32/proc.c:677: if ((rv = apr_conv_utf8_to_ucs2(env[i], &in,
threadproc/win32/proc.c:733: if ((rv = apr_conv_utf8_to_ucs2(progname, &nprg, wprg, &nwprg))
threadproc/win32/proc.c:749: if ((rv = apr_conv_utf8_to_ucs2(cmdline, &ncmd, wcmd, &nwcmd))
threadproc/win32/proc.c:766: if ((rv = apr_conv_utf8_to_ucs2(attr->currdir, &ncwd, |
Code: | C:\sdk\batch>dumpbin /EXPORTS C:\sdk\release\vs17_x64-avx2\bin\libapr-1.dll | grep -E '(apr_conv_ucs2_to_utf8^|apr_conv_utf8_to_ucs2)'
45 2C 000154B0 apr_conv_ucs2_to_utf8 = apr_conv_ucs2_to_utf8
46 2D 000152E0 apr_conv_utf8_to_ucs2 = apr_conv_utf8_to_ucs2 |
>> APR-2
Code: | $ sif /cygdrive/c/sdk/src/apr2/* apr_conv_ucs2_to_utf8
include/arch/win32/apr_arch_utf8.h:66:#define apr_conv_ucs2_to_utf8(in, inwords, out, outbytes) apr_conv_utf16_to_utf8(in, inwords, out, outbytes)
misc/win32/apr_app.c:78: (void)apr_conv_ucs2_to_utf8(wenv[i], &wcount, env[i], &envlen);
threadproc/win32/thread.c:375: rv = apr_conv_ucs2_to_utf8(wname, &wname_len, *name, &name_len);
$ sif /cygdrive/c/sdk/src/apr2/* apr_conv_utf8_to_ucs2
include/arch/win32/apr_arch_utf8.h:46:#define apr_conv_utf8_to_ucs2(in, inbytes, out, outwords) apr_conv_utf8_to_utf16(in, inbytes, out, outwords)
threadproc/win32/thread.c:333: rv = apr_conv_utf8_to_ucs2(name, &name_len, wname, &wname_len); |
Code: | dumpbin /EXPORTS C:\sdk\release\vs17_x64-avx2\bin\libapr-2.dll | grep -E '(apr_conv_ucs2_to_utf8^|apr_conv_utf8_to_ucs2)' |
[no result] |
|
Back to top |
|
Steffen Moderator
Joined: 15 Oct 2005 Posts: 3094 Location: Hilversum, NL, EU
|
Posted: Thu 17 Oct '24 13:52 Post subject: |
|
|
Got an answer :
Hi Steffen,
1. It will be much easier if you report to dev@ mailing list with all details: it takes a lot of time to dig to some forum to discover details. Thanks for understanding.
2. libapr-2 is not released and doesn't have a stable API/ABI. It is not supposed to be used.
3. It seems the issue comes because of r1869127. This change broke ABI and this is intentional. See discussion here:
https://lists.apache.org/thread/71h1dn0lpownbybz59bj8lo8k9rp25k8
4. In r1881476 compatibility names were added. So most likely code will compile if proper header files is used. |
|
Back to top |
|
nono303
Joined: 20 Dec 2016 Posts: 207 Location: Lille, FR, EU
|
Posted: Sat 19 Oct '24 18:04 Post subject: |
|
|
Thx @Steffen for this feedback!
Quote: | It will be much easier if you report to dev@ mailing list with all details: it takes a lot of time to dig to some forum to discover details. Thanks for understanding. |
not an easy way to interact with
Quote: | 2. libapr-2 is not released and doesn't have a stable API/ABI. It is not supposed to be used. |
ACK
I noticed the lack of arch/win32/apr_arch_utf8.h for os/win32/ap_regkey.c & os/win32/util_win32.c (but not server/mpm/winnt/service.c ...)
Even patched, still have the linking issue.
I understand that's too fresh to test it and for my part I'll will stop here until an apr-2 RC |
|
Back to top |
|
|
|
|
|
|