Subject: Pine on AIX UNIX v4.1

From: [email-masked]
Date: Mon, 07 Oct 96 11:58:10

I was finally able to get a good compile of Pine on my AIX 4.1 machine, but only
after some rather serious alteration of several Pine source files.  Somehow, I 
doubt that I should have done this, but since this is (for now at least) a test 
machine ...

Anyway, the problem appears to be related to the way comments in some source 
files are handled.  At least that's what the "C" compiler seemed to be 
complaining about.  For example, in the /pine3.95/pine/osdep/os-a41.h file, 
several comment lines appear like this:

   /* #include <sgtty.h>      /* BSD-based systems */                        

As far as I understand comment lines in "C" source code, the delimiters are the 
/* and */ sequences.  However, in many lines like the one above, two left-hand 
delimiters occur prior to a single right-hand one.  The only way I was able to 
get Pine to properly "build" (compile) was to alter these comments by removing 
the second left-hand delimiter.

After making this change, the compiles seemed to go without a problem.  However,
I noticed that the file sizes ended up dramatically different on AIX 4.1 
compared to AIX 3.2.5.  For example, after compiling all programs on AIX 3.2.5, 
the binary files created were:

     $ ls -l                                                    
     total 21768                                                
     -rwxr-xr-x   1 root     sys      1717607 Sep  8 18:34 imapd
     -rwxr-xr-x   1 root     sys      1557523 Sep  8 18:34 mtest
     -rwxr-xr-x   1 root     sys       861076 Sep  8 18:34 pico 
     -rwxr-xr-x   1 root     sys       858637 Sep  8 18:34 pilot
     -rwxr-xr-x   1 root     sys      6137198 Sep  8 18:34 pine 
     $                                                          
     
but on the AIX 4.1 system, the same binary files looked like this:

     $ ls -l                                           
     total 10936                                                
     -rwxr-xr-x   1 root     audit    1054577 Oct  5 07:42 imapd
     -rwxr-xr-x   1 root     audit    1013146 Oct  5 07:42 mtest
     -rwxr-xr-x   1 root     audit     291237 Oct  5 07:42 pico 
     -rwxr-xr-x   1 root     audit     289062 Oct  5 07:42 pilot
     -rwxr-xr-x   1 root     audit    2938894 Oct  5 07:42 pine 
     $                                                 
     
Despite the differences in file sizes, Pine on the AIX 4.1 system seems to work 
just fine.  Hmmmm.

My questions are:

1.   If alteration of the source code comment lines is NOT the proper way to
     get around the compilation failures, what is the proper method?

2.   If the resulting binary files are not the proper sizes, what happened?

Thank you for any comments you may have.

- Michael

------------------------------------------------------------------
Michael Wright, Systems Analyst         email: [email-masked]
Yakima Products, Inc.                   Ph:    707-826-8175
P.O. Box 4899, Arcata, CA 95521 (USA)   Fx:    707-826-8149
------------------------------------------------------------------

---

From: [email-masked] (Timothy P. Cheney)
Date: 9 Oct 1996 15:58:28 GMT

The compiler or preprocesser will WARN you about "/* /* */"  constructs
but that should not cause the compile to fail.  The message should begin
with (W) which stands for warning which rhymes with ignore ;-)  Sometimes
you might start writing a comment in your code with a /* but forget to end
the comment with a */.  The compiler suspects that's what happened here
and is warning you. 

[email-masked] wrote:

: I was finally able to get a good compile of Pine on my AIX 4.1 machine, but only
: after some rather serious alteration of several Pine source files.  Somehow, I 
: doubt that I should have done this, but since this is (for now at least) a test 
: machine ...

: Anyway, the problem appears to be related to the way comments in some source 
: files are handled.  At least that's what the "C" compiler seemed to be 
: complaining about.  For example, in the /pine3.95/pine/osdep/os-a41.h file, 
: several comment lines appear like this:

:    /* #include <sgtty.h>      /* BSD-based systems */                        

: As far as I understand comment lines in "C" source code, the delimiters are the 
: /* and */ sequences.  However, in many lines like the one above, two left-hand 
: delimiters occur prior to a single right-hand one.  The only way I was able to 
: get Pine to properly "build" (compile) was to alter these comments by removing 
: the second left-hand delimiter.

: After making this change, the compiles seemed to go without a problem.  However,
: I noticed that the file sizes ended up dramatically different on AIX 4.1 
: compared to AIX 3.2.5.  For example, after compiling all programs on AIX 3.2.5, 
: the binary files created were:

:      $ ls -l                                                    
:      total 21768                                                
:      -rwxr-xr-x   1 root     sys      1717607 Sep  8 18:34 imapd
:      -rwxr-xr-x   1 root     sys      1557523 Sep  8 18:34 mtest
:      -rwxr-xr-x   1 root     sys       861076 Sep  8 18:34 pico 
:      -rwxr-xr-x   1 root     sys       858637 Sep  8 18:34 pilot
:      -rwxr-xr-x   1 root     sys      6137198 Sep  8 18:34 pine 
:      $                                                          
:      
: but on the AIX 4.1 system, the same binary files looked like this:

:      $ ls -l                                           
:      total 10936                                                
:      -rwxr-xr-x   1 root     audit    1054577 Oct  5 07:42 imapd
:      -rwxr-xr-x   1 root     audit    1013146 Oct  5 07:42 mtest
:      -rwxr-xr-x   1 root     audit     291237 Oct  5 07:42 pico 
:      -rwxr-xr-x   1 root     audit     289062 Oct  5 07:42 pilot
:      -rwxr-xr-x   1 root     audit    2938894 Oct  5 07:42 pine 
:      $                                                 
:      
: Despite the differences in file sizes, Pine on the AIX 4.1 system seems to work 
: just fine.  Hmmmm.

: My questions are:

: 1.   If alteration of the source code comment lines is NOT the proper way to
:      get around the compilation failures, what is the proper method?

: 2.   If the resulting binary files are not the proper sizes, what happened?

: Thank you for any comments you may have.

: - Michael

: ------------------------------------------------------------------
: Michael Wright, Systems Analyst         email: [email-masked]
: Yakima Products, Inc.                   Ph:    707-826-8175
: P.O. Box 4899, Arcata, CA 95521 (USA)   Fx:    707-826-8149
: ------------------------------------------------------------------

--
=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
|  [email-masked]                                |
|  Timothy P. Cheney              (215) 898-3197        |
|  Population Studies Center                            |
|  239 McNeil/6298                                      |
|  University of Pennsylvania                           |
|  Philadelphia, PA 19104                               |
=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=