Back to index

cell-binutils  2.17cvs20070401
testprog.c
Go to the documentation of this file.
00001 /* This program is used to test objcopy, readelf and strip.  */
00002 
00003 extern int strcmp (char *, const char *);
00004 extern int printf (const char *, ...);
00005 
00006 int common;
00007 int global = 1;
00008 static int local = 2;
00009 static char string[] = "string";
00010 
00011 int
00012 fn (void)
00013 {
00014   return 3;
00015 }
00016 
00017 int
00018 main (void)
00019 {
00020   if (common != 0
00021       || global != 1
00022       || local != 2
00023       || strcmp (string, "string") != 0)
00024     {
00025       printf ("failed\n");
00026       return 1;
00027     }
00028 
00029   printf ("ok\n");
00030   return 0;
00031 }