Subject: gcc vs g++ bizarre behaviour (newbie - sorry to say)
From: [email-masked] (Allan Peda)

29 Nov 1998 19:39:32 -0800
Message-ID: <[email-masked]>
Mime-Version: 1.0
Content-Type: multipart/mixed;
 boundary="------------591DF1D04C4A113261410241"
To: cygwin <[email-masked]>

This is a multi-part message in MIME format.
--------------591DF1D04C4A113261410241
Content-Type: text/plain; charset=us-ascii
Content-Transfer-Encoding: 7bit

I am not having success invoking g++ via gcc.  Rather than describe
it... take a look:
I tried it both with and without the -x c++ option, quoted and
unquoted.  As you see g++ directly works fine.  Specifics are waay down
below

bash-2.02$ ./hellocc
hello C++ GNUish world!
bash-2.02$ rm ./hellocc.exe
bash-2.02$ gcc -x "c++" hellocc.cxx -o hellocc
C:\TEMP\cccQV0Xf.o(.text+0x2a):hellocc.cc: undefined reference to `cout'

C:\TEMP\cccQV0Xf.o(.text+0x2f):hellocc.cc: undefined reference to
`ostream::oper
ator<<(char const *)'
bash-2.02$ ./hellocc
bash: ./hellocc: No such file or directory
bash-2.02$ g++ hellocc.cxx -o hellocc
bash-2.02$ ./hellocc
hello C++ GNUish world!

Thanks
Allan

****
Here are some specifics:
bash-2.02$ cygcheck -s -v -r

Cygnus Win95/NT Configuration Diagnostics
Current System Time: Sun Nov 29 14:59:14 1998

WinNT Ver 4.0 build 1381 Service Pack 4

Path:   /bin
        /usr/bin
        //C/WINNT/system32
        //C/MSDEVSTD/BIN

SysDir: C:\WINNT\System32
WinDir: C:\WINNT

CYGWIN = `"noexport title strip_title glob notty nobinmode strace=n ntea
noreset
_com noenvcache"'
C_INCLUDE_PATH = `/usr/local/include;/usr/include'
GCC_EXEC_PREFIX = `/usr/bin;/usr/local/bin;/bin'
HOME = `/home/allan'
LIBRARY_PATH = `/usr/local/lib;/usr/lib'
MAKE_MODE = `UNIX'
PWD = `/home/allan/work_area/programs'

!C: = `C:\WINNT\Profiles\allan\Desktop'
COMPUTERNAME = `NTBOX'
COMSPEC = `C:\WINNT\system32\cmd.exe'
CPLUS_INCLUDE_PATH = `/usr/include/g++;/usr/local/include;/usr/include'
HOMEDRIVE = `c:'
HOMEPATH = `\home\allan'
HOSTNAME = `NTBOX'
HOSTTYPE = `i586'
INCLUDE = `C:\msdevstd\include;C:\msdevstd\mfc\include'
LIB = `C:\msdevstd\lib;C:\msdevstd\mfc\lib'
LOGONSERVER = `\\NTBOX'
MACHTYPE = `i586-pc-cygwin32'
MSDEVDIR = `C:\MSDEVSTD'
NUMBER_OF_PROCESSORS = `1'
OS2LIBPATH = `C:\WINNT\system32\os2\dll;'
OS = `Windows_NT'
OSTYPE = `cygwin32'
PATHEXT = `.COM;.EXE;.BAT;.CMD'
PROCESSOR_ARCHITECTURE = `x86'
PROCESSOR_IDENTIFIER = `x86 Family 6 Model 1 Stepping 7, GenuineIntel'
PROCESSOR_LEVEL = `6'
PROCESSOR_REVISION = `0107'
PROMPT = `$P$G'
SHELL = `/bin/sh'
SHLVL = `1'
SYSTEMDRIVE = `C:'
SYSTEMROOT = `C:\WINNT'
TEMP = `C:\TEMP'
TERM = `dumb'
TMP = `C:\TEMP'
USERDOMAIN = `NTBOX'
USERNAME = `allan'
USERPROFILE = `C:\WINNT\Profiles\allan'
WINDIR = `C:\WINNT'
_ = `/usr/bin/cygcheck'

HKEY_CURRENT_USER\Software\Cygnus Solutions
HKEY_CURRENT_USER\Software\Cygnus Solutions\CYGWIN.DLL setup
HKEY_CURRENT_USER\Software\Cygnus Solutions\CYGWIN.DLL setup\b15.0
HKEY_CURRENT_USER\Software\Cygnus Solutions\CYGWIN.DLL
setup\b15.0\mounts
HKEY_CURRENT_USER\Software\Cygnus Solutions\CYGWIN.DLL
setup\b15.0\mounts\00
  (default) = `C:\TEMP'
  unix = `/tmp'
  fbinary = 0x00000000
  fsilent = 0x00000000
HKEY_CURRENT_USER\Software\Cygnus Solutions\CYGWIN.DLL
setup\b15.0\mounts\01
  (default) = `C:\home'
  unix = `/home'
  fbinary = 0x00000000
  fsilent = 0x00000000
HKEY_CURRENT_USER\Software\Cygnus Solutions\CYGWIN.DLL
setup\b15.0\mounts\02
  (default) = `C:\etc'
  unix = `/etc'
  fbinary = 0x00000000
  fsilent = 0x00000000
HKEY_CURRENT_USER\Software\Cygnus Solutions\CYGWIN.DLL
setup\b15.0\mounts\03
  (default) = `G:'
  unix = `/cdrom'
  fbinary = 0x00000001
  fsilent = 0x00000000
HKEY_CURRENT_USER\Software\Cygnus Solutions\CYGWIN.DLL
setup\b15.0\mounts\04
  (default) = `F:'
  unix = `/cdrec'
  fbinary = 0x00000001
  fsilent = 0x00000000
HKEY_CURRENT_USER\Software\Cygnus Solutions\CYGWIN.DLL
setup\b15.0\mounts\05
  (default) = `C:\ROOT'
  unix = `/'
  fbinary = 0x00000000
  fsilent = 0x00000000
HKEY_CURRENT_USER\Software\Microsoft\RAS
Autodial\Addresses\sourceware.cygnus.co
m
  (default) = 0x00000004
  LastModified = 0x365b5795
  Network = `NETWORK0'
HKEY_CURRENT_USER\Software\Microsoft\RAS
Autodial\Addresses\www.cygnus.com
  (default) = 0x00000002
  LastModified = 0x365b56f4
  Network = `NETWORK0'
HKEY_LOCAL_MACHINE\SOFTWARE\Cygnus Solutions
HKEY_LOCAL_MACHINE\SOFTWARE\Cygnus Solutions\Cygwin B20
HKEY_LOCAL_MACHINE\SOFTWARE\Cygnus Solutions\Cygwin B20\B20
HKEY_LOCAL_MACHINE\SOFTWARE\Cygnus Solutions\CYGWIN.DLL setup
HKEY_LOCAL_MACHINE\SOFTWARE\Cygnus Solutions\CYGWIN.DLL setup\b15.0
HKEY_LOCAL_MACHINE\SOFTWARE\Cygnus Solutions\CYGWIN.DLL
setup\b15.0\mounts
HKEY_LOCAL_MACHINE\SOFTWARE\Cygnus Solutions\CYGWIN.DLL
setup\b15.0\mounts\00
HKEY_LOCAL_MACHINE\SOFTWARE\Cygnus Solutions\CYGWIN.DLL
setup\b15.0\mounts\01
HKEY_LOCAL_MACHINE\SOFTWARE\Cygnus Solutions\CYGWIN.DLL
setup\b15.0\mounts\02
HKEY_LOCAL_MACHINE\SOFTWARE\Cygnus Solutions\CYGWIN.DLL
setup\b15.0\mounts\03
HKEY_LOCAL_MACHINE\SOFTWARE\Cygnus Solutions\CYGWIN.DLL
setup\b15.0\mounts\04
HKEY_LOCAL_MACHINE\SOFTWARE\Cygnus Solutions\CYGWIN.DLL
setup\b15.0\mounts\05
HKEY_LOCAL_MACHINE\SOFTWARE\Cygnus Solutions\CYGWIN.DLL
setup\b15.0\mounts\06
HKEY_LOCAL_MACHINE\SOFTWARE\Cygnus Solutions\CYGWIN.DLL
setup\b15.0\mounts\07
HKEY_LOCAL_MACHINE\SOFTWARE\Cygnus Solutions\CYGWIN.DLL
setup\b15.0\mounts\08
HKEY_LOCAL_MACHINE\SOFTWARE\Cygnus Solutions\CYGWIN.DLL
setup\b15.0\mounts\09
HKEY_LOCAL_MACHINE\SOFTWARE\Cygnus Solutions\CYGWIN.DLL
setup\b15.0\mounts\0A
HKEY_LOCAL_MACHINE\SOFTWARE\Cygnus Solutions\CYGWIN.DLL
setup\b15.0\mounts\0B
HKEY_LOCAL_MACHINE\SOFTWARE\Cygnus Solutions\CYGWIN.DLL
setup\b15.0\mounts\0C
HKEY_LOCAL_MACHINE\SOFTWARE\Cygnus Solutions\CYGWIN.DLL
setup\b15.0\mounts\0D
HKEY_LOCAL_MACHINE\SOFTWARE\Cygnus Solutions\CYGWIN.DLL
setup\b15.0\mounts\0E
HKEY_LOCAL_MACHINE\SOFTWARE\Cygnus Solutions\CYGWIN.DLL
setup\b15.0\mounts\0F
HKEY_LOCAL_MACHINE\SOFTWARE\Cygnus Solutions\CYGWIN.DLL
setup\b15.0\mounts\10
HKEY_LOCAL_MACHINE\SOFTWARE\Cygnus Solutions\CYGWIN.DLL
setup\b15.0\mounts\11
HKEY_LOCAL_MACHINE\SOFTWARE\Cygnus Solutions\CYGWIN.DLL
setup\b15.0\mounts\12
HKEY_LOCAL_MACHINE\SOFTWARE\Cygnus Solutions\CYGWIN.DLL
setup\b15.0\mounts\13
HKEY_LOCAL_MACHINE\SOFTWARE\Cygnus Solutions\CYGWIN.DLL
setup\b15.0\mounts\14
HKEY_LOCAL_MACHINE\SOFTWARE\Cygnus Solutions\CYGWIN.DLL
setup\b15.0\mounts\15
HKEY_LOCAL_MACHINE\SOFTWARE\Cygnus Solutions\CYGWIN.DLL
setup\b15.0\mounts\16
HKEY_LOCAL_MACHINE\SOFTWARE\Cygnus Solutions\CYGWIN.DLL
setup\b15.0\mounts\17
HKEY_LOCAL_MACHINE\SOFTWARE\Cygnus Solutions\CYGWIN.DLL
setup\b15.0\mounts\18
HKEY_LOCAL_MACHINE\SOFTWARE\Cygnus Solutions\CYGWIN.DLL
setup\b15.0\mounts\19
HKEY_LOCAL_MACHINE\SOFTWARE\Cygnus Solutions\CYGWIN.DLL
setup\b15.0\mounts\1A
HKEY_LOCAL_MACHINE\SOFTWARE\Cygnus Solutions\CYGWIN.DLL
setup\b15.0\mounts\1B
HKEY_LOCAL_MACHINE\SOFTWARE\Cygnus Solutions\CYGWIN.DLL
setup\b15.0\mounts\1C
HKEY_LOCAL_MACHINE\SOFTWARE\Cygnus Solutions\CYGWIN.DLL
setup\b15.0\mounts\1D
HKEY_LOCAL_MACHINE\SOFTWARE\Cygnus Solutions\GNUPro
HKEY_LOCAL_MACHINE\SOFTWARE\Cygnus Solutions\GNUPro\i586-cygwin32
HKEY_LOCAL_MACHINE\SOFTWARE\Cygnus
Solutions\GNUPro\i586-cygwin32\i586-cygwin32
HKEY_LOCAL_MACHINE\SOFTWARE\Cygnus
Solutions\GNUPro\i586-cygwin32\i586-cygwin32\
cygwin-B20
  (default) = `c:\cygnus\cygwin-b20'
HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows\CurrentVersion\Uninstall\Cygnus
Cy
gwin B20
  (default) = `C:\WINNT\IsUninst.exe -fc:\cygnus\cygwin-b20\Uninst.isu'
  DisplayName = `Cygwin B20'

a:\ fd           N/A    N/A
c:\ hd  NTFS    1702Mb  76% CP CS UN PA FC
d:\ hd  NTFS     305Mb  67% CP CS UN PA FC     emergency_boot
e:\ fd           N/A    N/A
f:\ cd           N/A    N/A
g:\ cd           N/A    N/A

C:\ROOT  /        native  text!=binary
F:       /cdrec   native  text=binary
G:       /cdrom   native  text=binary
C:\etc   /etc     native  text!=binary
C:\home  /home    native  text!=binary
C:\TEMP  /tmp     native  text!=binary

Found: C:\ROOT\bin\bash.exe
Found: C:\ROOT\usr\bin\cat.exe
Found: C:\ROOT\usr\bin\cpp.exe
Found: C:\ROOT\usr\bin\find.exe
Found: C:\ROOT\usr\bin\gcc.exe
Found: C:\ROOT\usr\bin\gdb.exe
Found: C:\ROOT\usr\bin\ld.exe
Found: C:\ROOT\usr\bin\ls.exe
Found: C:\ROOT\usr\bin\make.exe
Found: C:\ROOT\bin\sh.exe

  429k 1998/11/02 C:\ROOT\bin\cygwin1.dll - os=4.0 img=1.0 sys=4.0
                  "cygwin1.dll" v0.0 ts=1998/11/2 9:00
  371k 1998/11/02 C:\ROOT\usr\bin\cygtcl80.dll - os=4.0 img=1.0 sys=4.0
                  "cygtcl80.dll" v0.0 ts=1998/11/2 8:22
    5k 1998/11/02 C:\ROOT\usr\bin\cygtclpip80.dll - os=4.0 img=1.0
sys=4.0
   10k 1998/11/02 C:\ROOT\usr\bin\cygtclreg80.dll - os=4.0 img=1.0
sys=4.0
                  "cygtclreg80.dll" v0.0 ts=1998/11/2 8:22
  600k 1998/11/02 C:\ROOT\usr\bin\cygtk80.dll - os=4.0 img=1.0 sys=4.0
                  "cygtk80.dll" v0.0 ts=1998/11/2 8:27
Use -h to see help about each section
bash-2.02$

and for good measure, the mounts:
bash-2.02$ mount
Device           Directory           Type        Flags
C:\TEMP          /tmp                native      text!=binary
C:\home          /home               native      text!=binary
C:\etc           /etc                native      text!=binary
G:               /cdrom              native      text=binary
F:               /cdrec              native      text=binary
C:\ROOT          /                   native      text!=binary

--------------591DF1D04C4A113261410241
Content-Type: text/x-vcard; charset=us-ascii;
 name="allan.vcf"
Content-Transfer-Encoding: 7bit
Content-Description: Card for Allan Peda
Content-Disposition: attachment;
 filename="allan.vcf"

begin:vcard 
n:Peda;Allan
tel;work:718-243-1721
x-mozilla-html:FALSE
adr:;;;;;;
version:2.1
email;internet:[email-masked]
fn:Allan Peda
end:vcard

--------------591DF1D04C4A113261410241--

-
For help on using this list (especially unsubscribing), send a message to
"[email-masked]" with one line of text: "help".