Wireshark-bugs: [Wireshark-bugs] [Bug 1267] wireshark crashes mid-startup
Date: Wed, 12 Mar 2008 00:04:37 +0000 (GMT)
http://bugs.wireshark.org/bugzilla/show_bug.cgi?id=1267





--- Comment #14 from paul <ephraim_owns@xxxxxxxxxxx>  2008-03-12 00:04:34 GMT ---
0.99.8 tarball

In file included from /usr/include/dirent.h:67,
                 from
/Source/wireshark/wireshark/epan/dissectors/packet-xml.c:35:
/usr/include/sys/dirent.h:76: error: parse error before "u_int32_t"
/usr/include/sys/dirent.h:78: error: parse error before "d_type"
/usr/include/sys/dirent.h:79: error: parse error before "d_namlen"
/usr/include/sys/dirent.h:86: error: parse error before '}' token
make[4]: *** [libcleandissectors_la-packet-xml.lo] Error 1

In file included from /usr/include/dirent.h:67,
                 from /Source/wireshark/wireshark/epan/filesystem.c:30:
/usr/include/sys/dirent.h:76: error: parse error before "u_int32_t"
/usr/include/sys/dirent.h:78: error: parse error before "d_type"
/usr/include/sys/dirent.h:79: error: parse error before "d_namlen"
/usr/include/sys/dirent.h:86: error: parse error before '}' token
make[2]: *** [filesystem.o] Error 1

#include'd <sys/types.h> before dirent.h clears that up

/Source/wireshark/wireshark/epan/emem.c: In function `ep_init_chunk':
/Source/wireshark/wireshark/epan/emem.c:234: error: `_SC_PAGESIZE' undeclared
(first use in this function)
/Source/wireshark/wireshark/epan/emem.c:234: error: (Each undeclared identifier
is reported only once
/Source/wireshark/wireshark/epan/emem.c:234: error: for each function it
appears in.)

replaced sysconf(_SC_PAGESIZE); with getpagesize();

my personal preference is to have all libraries and modules build with
-no-undefined

libwiretap needs -lglib-2.0 added to link line

ld: Undefined symbols:
_mpa_bitrate
_mpa_frequency
_mpa_layer
_mpa_padding
_mpa_samples
_mpa_version
_wtap_pcap_encap_to_wtap_encap
/usr/bin/libtool: internal link edit command failed
make[3]: *** [libwireshark.la] Error 1

apparently for linking libwireshark, -lwiretap should be added to the link line

/Source/wireshark/wireshark/version_info.c: In function
`get_runtime_version_info':
/Source/wireshark/wireshark/version_info.c:424: error:
`gestaltSystemVersionMajor' undeclared (first use in this function)
/Source/wireshark/wireshark/version_info.c:424: error: (Each undeclared
identifier is reported only once
/Source/wireshark/wireshark/version_info.c:424: error: for each function it
appears in.)
/Source/wireshark/wireshark/version_info.c:425: error:
`gestaltSystemVersionMinor' undeclared (first use in this function)
/Source/wireshark/wireshark/version_info.c:426: error:
`gestaltSystemVersionBugFix' undeclared (first use in this function)

somehow (i believe my AvailabilityMacros.h is too new), it thought i was
running 10.4 or higher, i just deleted the offending code

ld: dftest.o illegal reference to symbol: _pi defined in indirectly referenced
dynamic library
/System/Library/Frameworks/CoreServices.framework/Versions/A/Frameworks/CarbonCore.framework/Versions/A/CarbonCore

added -Wl,-framework,Carbon to dftest

installed fine, then i ran it

% wireshark 
Xlib:  extension "RANDR" missing on display ":0.0".
Duplicate field detected in call to proto_register_field_array: alc.lct is
already registered
Bus error
Exit 138
% gdb /opt/local/bin/wireshark 
GNU gdb 5.3-20030128 (Apple version gdb-282) (Fri Jun 13 03:33:07 GMT 2003)
Copyright 2003 Free Software Foundation, Inc.
GDB is free software, covered by the GNU General Public License, and you are
welcome to change it and/or distribute copies of it under certain conditions.
Type "show copying" to see the conditions.
There is absolutely no warranty for GDB.  Type "show warranty" for details.
This GDB was configured as "powerpc-apple-darwin".
Reading symbols for shared libraries ......................................
done
(gdb) r
Starting program: /opt/local/bin/wireshark 
Reading symbols for shared libraries
++++++++++++++++++++++++++++++++....................................................
done
Xlib:  extension "RANDR" missing on display ":0.0".
Reading symbols for shared libraries . done
Reading symbols for shared libraries . done
Reading symbols for shared libraries . done
Duplicate field detected in call to proto_register_field_array: alc.lct is
already registered

Program received signal EXC_BAD_ACCESS, Could not access memory.
0x048958ac in proto_register_subtree_array (indices=0x574e568, num_indices=7)
at /Source/wireshark/wireshark/epan/proto.c:3995
3995                    **ptr = num_tree_types;
(gdb) bt
#0  0x048958ac in proto_register_subtree_array (indices=0x574e568,
num_indices=7) at /Source/wireshark/wireshark/epan/proto.c:3995
#1  0x04db4be0 in proto_register_alc () at
/Source/wireshark/wireshark/epan/dissectors/packet-rmt-alc.c:281
#2  0x04487f08 in register_all_protocols (cb=0x56718 <splash_update>,
client_data=0x5b3000) at register.c:45
#3  0x0488a0e0 in proto_init (register_all_protocols=0x44877c4
<register_all_protocols>, register_all_protocol_handoffs=0x449052c
<register_all_protocol_handoffs>, cb=0x56718 <splash_update>,
client_data=0x5b3000) at /Source/wireshark/wireshark/epan/proto.c:380
#4  0x0487243c in epan_init (register_all_protocols=0x44877c4
<register_all_protocols>, register_all_handoffs=0x449052c
<register_all_protocol_handoffs>, cb=0x56718 <splash_update>,
client_data=0x5b3000, report_failure=0xbfd0 <failure_alert_box>,
report_open_failure=0xc014 <open_failure_alert_box>, report_read_failure=0xc06c
<read_failure_alert_box>) at /Source/wireshark/wireshark/epan/epan.c:94
#5  0x00024778 in main (argc=1, argv=0xbffffa2c) at
/Source/wireshark/wireshark/gtk/main.c:2651
(gdb) 


-- 
Configure bugmail: http://bugs.wireshark.org/bugzilla/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the assignee for the bug.