On Thu, Jan 10, 2013 at 6:33 PM, Ribhi Kamal <rbhka...@gmail.com> wrote:
> So even though the names differ by a prefixed underscore in ( _SHA1_Update
> vs SHA1_Update ), the names are actually the same? I wonder what linker
> logic is behind this
Yes. That's a 'C' decoration. The underscore'd name is what the linker
sees and uses.

C++ is a different beast (C++ name mangling).

$ lipo -info /usr/local/ssl/iphoneos/lib/libcrypto.a
input file /usr/local/ssl/iphoneos/lib/libcrypto.a is not a fat file
Non-fat file: /usr/local/ssl/iphoneos/lib/libcrypto.a is architecture: armv7

$ nm /usr/local/ssl/iphoneos/lib/libcrypto.a | grep -i "FIPS"
/usr/local/ssl/iphoneos/lib/libcrypto.a(o_fips.o):
00000000 T _FIPS_mode
00000010 T _FIPS_mode_set
         U _FIPS_module_mode
         U _FIPS_module_mode_set
         U _FIPS_rand_get_method
         U _FIPS_set_error_callbacks
         U _FIPS_set_locking_callbacks
         U _FIPS_set_malloc_callbacks
         U _RAND_init_fips
...

Jeff

> On Thu, Jan 10, 2013 at 6:09 PM, Jeffrey Walton <noloa...@gmail.com> wrote:
>>
>> On Thu, Jan 10, 2013 at 5:50 PM, Ribhi Kamal <rbhka...@gmail.com> wrote:
>> > Never mind, the application (virtualbox) was incorrectly trying to use
>> > the
>> > 32bit version of openssl. But I still don't understand why a 32bit
>> > version
>> > has different symbols that the 64bit one.
>> The message is probably similar to "Symbol not found for architecture
>> X". The names are the same - its the architecture that is different.
>>
>> > On Thu, Jan 10, 2013 at 12:01 PM, Ribhi Kamal <rbhka...@gmail.com>
>> > wrote:
>> >>
>> >> Thanks Jakob, I'm using MASM (ml and ml64) and it seems to work ok for
>> >> the
>> >> 32bit build at least. Should I be using nasm for 64bit instead?
>> >>
>> >> The functionality for SHA512 and the rest seems to be implemented
>> >> because
>> >> the test for SHA512 (sha512t.exe) is compiled and works correctly. And
>> >> I
>> >> think the symbols are missing from the lib (libeay32.lib) and not from
>> >> the
>> >> DLL so I did a grep on SHA512 and I found the following:
>> >> SHA*_*
>> >> __imp_SHA*_*
>> >>
>> >> However, I found nothing starting with an underscore like (
>> >> _SHA512_Update
>> >> ) while the 32bit build had these symbols as well... any ideas?
>> >>
>> >> On Thu, Jan 10, 2013 at 4:23 AM, Jakob Bohm <jb-open...@wisemo.com>
>> >> wrote:
>> >>>
>> >>> On 1/9/2013 6:40 PM, Ribhi Kamal wrote:
>> >>>>
>> >>>> Hi all,
>> >>>> I've compiled openssl 0.9.8x on windows 7 using VS2010 pro using the
>> >>>> following steps:
>> >>>> perl Configure VC-WIN64A --prefix=%LIB_OUT%
>> >>>> CALL ms\do_win64a
>> >>>> nmake -f ms\ntdll.mak
>> >>>> nmake -f ms\ntdll.mak test
>> >>>> nmake -f ms\ntdll.mak install
>> >>>>
>> >>>> Unfortunately the resulting libraries do not have any of the
>> >>>> following
>> >>>> symbols:
>> >>>> _SHA512_Init
>> >>>> _SHA512_Update
>> >>>> _SHA512_Final
>> >>>> _SHA256_Init
>> >>>> _SHA256_Update
>> >>>> _SHA256_Final
>> >>>> _SHA1_Init
>> >>>> _SHA1_Update
>> >>>> _SHA1_Final
>> >>>>
>> >>>> On the other hand, the 32bit compilation works fine. Any suggestions
>> >>>> on
>> >>>> what I might be doing wrong.
>> >>>>
>> >>>> Please any help would greatly appreciated.
>> >>>>
>> >>>
>> >>> Did you remember to install NASM?
>> >>>
>> >>> Are the functions completely missing or just not exported from the
>> >>> resulting DLLs?
______________________________________________________________________
OpenSSL Project                                 http://www.openssl.org
User Support Mailing List                    openssl-users@openssl.org
Automated List Manager                           majord...@openssl.org

Reply via email to