1 /* Find out if we need the pad field in the header for this machine
2 Copyright (C) 1991 Free Software Foundation
4 This program is free software; you can redistribute it and/or
5 modify it under the terms of the GNU General Public License as
6 published by the Free Software Foundation; either version 2, or (at
7 your option) any later version.
9 This program is distributed in the hope that it will be useful, but
10 WITHOUT ANY WARRANTY; without even the implied warranty of
11 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
12 General Public License for more details.
14 You should have received a copy of the GNU General Public License
15 along with this program; if not, write to the Free Software
16 Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
46 FILE *fp = fopen ("testpad.h", "w");
50 fprintf (stderr, "testpad: cannot open ");
56 t1diff = (char *) &t1.in[0] - (char *) &t1;
57 t2diff = (char *) &t2.in[0] - (char *) &t2;
59 if (t2diff == t1diff + 1)
60 fprintf (fp, "#define NEEDPAD\n");
61 else if (t1diff != t2diff)
62 fprintf (stderr, "Cannot determine padding for tar struct, \n\
63 will try with none.\n");