[mpich-discuss] static Linking Error

Doha Ehab dohaehab at gmail.com
Mon Nov 30 07:57:41 CST 2015


I have retried it using mpich-3.2 and the following command :

./configure --prefix=/home/doha/mpich-3.2/build/
CC=/home/doha/buildroot-2015.08.1/output/host/usr/bin/arm-buildroot-linux-uclibcgnueabi-gcc
CFLAGS="-DHAVE_DEPRECATED_DNS_FUNCS  -march=armv5 -mfpu=vfp  -fPIC   -O3
 -static" LDFLAGS="--static
 -L/home/doha/buildroot-2015.08.1/output/host/usr/lib/ " --host=arm-linux
 --disable-shared --enable-static --with-device=ch3:sock --disable-f77
--disable-fc --disable-fortran

and I got the following errors

jni/../prebuilt/libmpi.a(lib_libmpi_la-errutil.o):errutil.c:function
checkValidErrcode: error: undefined reference to 'stderr'
jni/../prebuilt/libmpi.a(lib_libmpi_la-errutil.o):errutil.c:function
checkForUserErrcode: error: undefined reference to 'stderr'
jni/../prebuilt/libmpi.a(lib_libmpi_la-errutil.o):errutil.c:function
MPIR_Err_preOrPostInit: error: undefined reference to 'stderr'
jni/../prebuilt/libmpi.a(lib_libmpi_la-errutil.o):errutil.c:function
MPIR_Err_get_string: error: undefined reference to 'stderr'
jni/../prebuilt/libmpi.a(lib_libmpi_la-dbg_printf.o):dbg_printf.c:function
MPIU_dbg_printf: error: undefined reference to 'stdout'
jni/../prebuilt/libmpi.a(lib_libmpi_la-dbg_printf.o):dbg_printf.c:function
MPIU_dump_dbg_memlog_to_stdout: error: undefined reference to 'stdout'
jni/../prebuilt/libmpi.a(lib_libmpi_la-mpid_vc.o):mpid_vc.c:function
MPIDI_Populate_vc_node_ids: error: undefined reference to '__errno_location'
jni/../prebuilt/libmpi.a(lib_libmpi_la-mpid_vc.o):mpid_vc.c:function
MPIDI_Populate_vc_node_ids: error: undefined reference to '__ctype_b'
jni/../prebuilt/libmpi.a(lib_libmpi_la-mpidi_pg.o):mpidi_pg.c:function
getConnInfo: error: undefined reference to 'stdout'
jni/../prebuilt/libmpi.a(lib_libmpi_la-mpidi_pg.o):mpidi_pg.c:function
MPIDI_PG_Create: error: undefined reference to 'stdout'
jni/../prebuilt/libmpi.a(lib_libmpi_la-sock.o):sock.c:function
MPIDU_Socki_event_enqueue.isra.1: error: undefined reference to
'__errno_location'
jni/../prebuilt/libmpi.a(lib_libmpi_la-sock.o):sock.c:function
MPIDU_Socki_wakeup.isra.2: error: undefined reference to '__errno_location'
jni/../prebuilt/libmpi.a(lib_libmpi_la-sock.o):sock.c:function
MPIDU_Sock_SetSockBufferSize: error: undefined reference to
'__errno_location'
jni/../prebuilt/libmpi.a(mplenv.o):mplenv.c:function MPL_env2range: error:
undefined reference to '__ctype_b'
jni/../prebuilt/libmpi.a(mplenv.o):mplenv.c:function MPL_env2int: error:
undefined reference to '__ctype_b'
jni/../prebuilt/libmpi.a(lib_libmpi_la-strerror.o):strerror.c:function
MPIU_Strerror: error: undefined reference to '__xpg_strerror_r'
jni/../prebuilt/libmpi.a(lib_libmpi_la-ch3u_handle_connection.o):ch3u_handle_connection.c:function
MPIDI_CH3U_Get_failed_group: error: undefined reference to '__ctype_b'

any suggestions ?




On Mon, Nov 30, 2015 at 3:11 AM, dave <dave at mynatt.biz> wrote:

> Is it possible to upgrade without doing an uninstall of old version, yet
> still keep setup files?
>
> Dave
> ======================
>
>
> On 11/29/2015 05:52 PM, Balaji, Pavan wrote:
>
>> Also, can you please try a newer version of mpich?  mpich2-1.3 was
>> released before the big bang.  The latest version is mpich-3.2.
>>
>>         http://www.mpich.org/downloads/
>>
>>    -- Pavan
>>
>> On Nov 29, 2015, at 3:26 PM, Min Si <msi at il.is.s.u-tokyo.ac.jp> wrote:
>>>
>>> Hi,
>>>
>>> Please try ./configure --prefix=<your installation directory> CC=<your
>>> compiler> CFLAGS=<your compile flags> LDFLAGS=<your link flags> following
>>> with other options.
>>>
>>> Min
>>> On 11/29/15 2:22 PM, Doha Ehab wrote:
>>>
>>>>
>>>> On Sun, Nov 29, 2015 at 2:01 PM, Doha Ehab <dohaehab at gmail.com> wrote:
>>>> Hello,
>>>> I used buildroot to statically compile MPICH2-1.3 for ARM devices using
>>>> the following commands:
>>>>
>>>> export CFLAGS="-I/home/doha/buildroot-2015.05/output/host/usr/include/
>>>> -DHAVE_DEPRECATED_DNS_FUNCS -fPIC -march=armv5 -mfpu=vfp -O3"
>>>>
>>>> export LDFLAGS="--static
>>>> -L/home/doha/buildroot-2015.05/output/host/usr/lib/ -fPIC"
>>>>
>>>> cc=/home/doha/buildroot-2015.05/output/host/usr/bin/arm-buildroot-linux-uclibcgnueabi-gcc
>>>> ./configure --prefix=/home/doha/mpich/build/
>>>>  --host=arm-linux  --disable-shared --enable-static
>>>>  --with-device=ch3:sock --disable-f77 --disable-fc
>>>>
>>>> when I compile the code using android ndk I get the following error
>>>>
>>>> jni/../prebuilt/libmpich.a(msgprint.o):msgprint.c:function
>>>> MPIU_Usage_printf: error: undefined reference to 'stdout'
>>>> jni/../prebuilt/libmpich.a(msgprint.o):msgprint.c:function
>>>> MPIU_Error_printf: error: undefined reference to 'stderr'
>>>> jni/../prebuilt/libmpich.a(msgprint.o):msgprint.c:function
>>>> MPIU_Internal_error_printf: error: undefined reference to 'stderr'
>>>> jni/../prebuilt/libmpich.a(msgprint.o):msgprint.c:function
>>>> MPIU_Internal_sys_error_printf: error: undefined reference to 'stderr'
>>>> jni/../prebuilt/libmpich.a(msgprint.o):msgprint.c:function
>>>> MPIU_Msg_printf: error: undefined reference to 'stdout'
>>>> jni/../prebuilt/libmpich.a(dbg_printf.o):dbg_printf.c:function
>>>> MPIU_dbg_printf: error: undefined reference to 'stdout'
>>>> jni/../prebuilt/libmpich.a(dbg_printf.o):dbg_printf.c:function
>>>> MPIU_dump_dbg_memlog_to_stdout: error: undefined reference to 'stdout'
>>>> jni/../prebuilt/libmpich.a(mpid_abort.o):mpid_abort.c:function
>>>> MPID_Abort: error: undefined reference to 'stderr'
>>>> jni/../prebuilt/libmpich.a(mpid_vc.o):mpid_vc.c:function
>>>> MPIDI_Populate_vc_node_ids: error: undefined reference to '__errno_location'
>>>> jni/../prebuilt/libmpich.a(mpid_vc.o):mpid_vc.c:function
>>>> MPIDI_Populate_vc_node_ids: error: undefined reference to '__ctype_b'
>>>> jni/../prebuilt/libmpich.a(strerror.o):strerror.c:function
>>>> MPIU_Strerror: error: undefined reference to '__xpg_strerror_r'
>>>> jni/../prebuilt/libmpich.a(simple_pmi.o):simple_pmi.c:function
>>>> accept_one_connection: error: undefined reference to '__errno_location'
>>>> jni/../prebuilt/libmpich.a(simple_pmi.o):simple_pmi.c:function
>>>> PMI_Init: error: undefined reference to '__errno_location'
>>>> jni/../prebuilt/libmpich.a(sock.o):sock.c:function
>>>> MPIDU_Socki_event_enqueue.isra.1: error: undefined reference to
>>>> '__errno_location'
>>>> jni/../prebuilt/libmpl.a(mplenv.o):mplenv.c:function MPL_env2range:
>>>> error: undefined reference to '__ctype_b'
>>>> jni/../prebuilt/libmpl.a(mplenv.o):mplenv.c:function MPL_env2int:
>>>> error: undefined reference to '__ctype_b'
>>>>   I want to know what I'm missing and why it is not linking properly
>>>>
>>>> _______________________________________________
>>>> discuss mailing list     discuss at mpich.org
>>>> To manage subscription options or unsubscribe:
>>>> https://lists.mpich.org/mailman/listinfo/discuss
>>>>
>>>>
>>>>
>>>> _______________________________________________
>>>> discuss mailing list
>>>> discuss at mpich.org
>>>>
>>>> To manage subscription options or unsubscribe:
>>>>
>>>> https://lists.mpich.org/mailman/listinfo/discuss
>>>>
>>> _______________________________________________
>>> discuss mailing list     discuss at mpich.org
>>> To manage subscription options or unsubscribe:
>>> https://lists.mpich.org/mailman/listinfo/discuss
>>>
>> _______________________________________________
>> discuss mailing list     discuss at mpich.org
>> To manage subscription options or unsubscribe:
>> https://lists.mpich.org/mailman/listinfo/discuss
>>
>>
>>
> _______________________________________________
> discuss mailing list     discuss at mpich.org
> To manage subscription options or unsubscribe:
> https://lists.mpich.org/mailman/listinfo/discuss
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.mpich.org/pipermail/discuss/attachments/20151130/48ac1a64/attachment.html>
-------------- next part --------------
_______________________________________________
discuss mailing list     discuss at mpich.org
To manage subscription options or unsubscribe:
https://lists.mpich.org/mailman/listinfo/discuss


More information about the discuss mailing list