This is the mail archive of the
gcc-bugs@gcc.gnu.org
mailing list for the GCC project.
#pragma pack problem
- To: gcc-bugs at gcc dot gnu dot org, bug-gcc at gnu dot org
- Subject: #pragma pack problem
- From: Radhika S <rad at miel dot mot dot com>
- Date: Mon, 08 May 2000 17:54:33 +0530
hi
in the attached program i use #pragma pack(1) . I compile the program
with gcc version 2.95.2
and linked using gnu linker 2.9.1 and ran it gives the Bus Error (core
dumped) as it was trying to access the integer variable with
odd_address.
whereas if i compile the same program with
cc: Workshop Compilers 4.2 with -misalign option (cc -misalign stru.c
) with solaris linker it doesn;t dump core
Is there any option like -misalign for the gnu linker to make the linker
accept the odd address
access.