Subject: Problems with buildiing DLL for AFsp-Routines
From: [email-masked] (Lampos Ferekidis)

13 Jan 1999 23:40:24 -0800
Message-ID: <D0516DFA9EB9D1118F3200A0249D0F8A0D94FA.cygnus.gnu-win32@EXCHANGE>
Mime-Version: 1.0
Content-Type: text/plain;
	charset="iso-8859-1"
To: "'GNU-win32'" <[email-masked]>
Cc: "'mailto:[email-masked]'" <mailto:[email-masked]>

I'm trying to build a DLL from the AFsp-Routines (to those who
unfamiliar wtih this routines: the library contains powerful routines
for Audio File Signal Processing (AFsp))

As a starting point I have used the description given by John Cerney
<[email-masked]> in his mail from Wed, 5 Mar 1997 with the subject
"Building a relocatable DLL - example".

The given script works quite well apart from the fact that each time the
linker (ld) is called the following error message appears:

C:/Global/B20/H-i586-cygwin32/i586-cygwin32/lib/libcygwin.a(libccrt0.o):

In function `cygwin_crt0_common(int (*)(int, char **, char **))':
/home/noer/src/b20/comp-tools/devo/winsup/libccrt0.cc:65: undefined
reference to
 `GetModuleHandleA@4'

If possible, please tell me if this is a major problem (unsupported
function/bug) or just a stupid fault.

Thanks very much Lampos.

PS.: Please send a copy of your mail additionally to
CC:[email-masked] ,because I'm registered to this list with
another EMail address, cheers!

>>>>>>>>>>>>>>>>>>>>>> BEGIN shellscript: dllmake
<<<<<<<<<<<<<<<<<<<<<<<<<<<<
#!/bin/sh	
#  Example Script to compile and link a relocatable DLL
#  Files that make up the DLL = foo.c foo2.c init.cc fixup.c.
#  (init.cc and fixup.c are housekeeping routines needed for the DLL. 
#  The actual library routines are in foo.c and foo2.c)

#  ***Fill in your path to libcygwin.a here (with no trailing slash)***
#  LIBPATH=/Global/B19/H-i586-cygwin32/i586-cygwin32/lib

# Make .def file:
# LIBPATH=/Global/B20/H-i586-cygwin32/i586-cygwin32/lib

gcc -c fixup.c -o fixup.o
gcc -c init.cc -o init.o

echo EXPORTS > libtspB.def 
nm ??/*.o ??/*/*.o init.o fixup.o | grep '^........ [T] _' | sed
's/[^_]*_//' >> libtspB.def

# Link DLL:
ld --verbose --base-file libtspB.base --dll -o libtspB.dll ??/*.o
??/*/*.o init.o fixup.o $GCC_LIBRARY_PATH/libcygwin.a -e _dll_entry@12

dlltool --as=as --dllname libtspB.dll --def libtspB.def --base-file
libtspB.base --output-exp libtspB.exp

ld --verbose --base-file libtspB.base libtspB.exp --dll -o libtspB.dll
??/*.o ??/*/*.o init.o fixup.o $GCC_LIBRARY_PATH/libcygwin.a -e
_dll_entry@12

dlltool --as=as --dllname libtspB.dll --def libtspB.def --base-file
libtspB.base --output-exp libtspB.exp

ld --verbose libtspB.exp --dll -o libtspB.dll ??/*.o ??/*/*.o init.o
fixup.o $GCC_LIBRARY_PATH/libcygwin.a -e _dll_entry@12

# Build the libtspB.a lib to link to:
dlltool --as=as --dllname libtspB.dll --def libtspB.def --output-lib
libtspB.a
cp libtspB.dll ../lib/libtsp.dll
>>>>>>>>>>>>>>>>>>>>>> END shellscript: dllmake
<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<

Attached you will find a file containing the system setup information
generated with 'cygcheck -s'.

Cygnus Win95/NT Configuration Diagnostics
Current System Time: Wed Jan 13 11:53:20 1999

WinNT Ver 4.0 build 1381 Service Pack 3

Path:	.
	/c/Global/B20/H-i586-cygwin32/bin
	/c/global/bin
	/c/global/emacs-20.3.1/bin
	/c/global/vim-5.3
	/c/WINNT/system32
	/c/WINNT
	/c/Global/B20/H-i586-cygwin32/i586-cygwin32/lib
	.

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

GCC_EXEC_PREFIX = `C:\Global\B20\H-i586-cygwin32\lib\gcc-lib\'
HOME = `/c'
MAKE_MODE = `UNIX'
PWD = `/c_project/AFsp-v4r0/libtsp'
TCL_LIBRARY = `C:/Global/B20/share/tcl8.0/'

Use `-r' to scan registry

c:\ hd  NTFS    6142Mb  33% CP CS UN PA FC     
d:\ cd  CDFS     642Mb 100%    CS UN           NT_BACKUP
e:\ net NTFS   12283Mb  50% CP CS UN PA FC     Data 5
f:\ net NTFS    8675Mb  68% CP CS UN PA FC     Data 3
z:\ net NTFS    8675Mb  68% CP CS UN PA FC     Data 3

C:                                /          native  text!=binary
e:                                /Lampos    native  text!=binary
f:                                /Transfer  native  text!=binary
C:\Global\bin                     /bin       native  text!=binary
C:                                /c         native  text!=binary
D:                                /d         native  text!=binary
\\.\a:                            /dev/fd0   native  text!=binary
\\.\b:                            /dev/fd1   native  text!=binary
\\.\tape0:                        /dev/st0   native  text!=binary
\\.\tape1:                        /dev/st1   native  text!=binary
E:                                /e         native  text!=binary
F:                                /f         native  text!=binary
\Global\B19\info                  /info      native  text!=binary
c:\temp                           /tmp       native  text!=binary
c:\Program Files\MyOwn\Ml\MFILES  matlab     native  text!=binary

Found: C:\Global\B20\H-i586-cygwin32\bin\bash.exe
Found: C:\Global\B20\H-i586-cygwin32\bin\cat.exe
Not Found: cpp (good!)
Found: C:\Global\B20\H-i586-cygwin32\bin\find.exe
Found: C:\Global\B20\H-i586-cygwin32\bin\gcc.exe
Found: C:\Global\B20\H-i586-cygwin32\bin\gdb.exe
Found: C:\Global\B20\H-i586-cygwin32\bin\ld.exe
Found: C:\Global\B20\H-i586-cygwin32\bin\ls.exe
Found: C:\Global\B20\H-i586-cygwin32\bin\make.exe
Found: C:\Global\B20\H-i586-cygwin32\bin\sh.exe
Found: C:\global\bin\sh.exe

  371k 1998/12/01 C:\Global\B20\H-i586-cygwin32\bin\cygtcl80.dll
    5k 1998/12/01 C:\Global\B20\H-i586-cygwin32\bin\cygtclpip80.dll
   10k 1998/12/01 C:\Global\B20\H-i586-cygwin32\bin\cygtclreg80.dll
  600k 1998/12/01 C:\Global\B20\H-i586-cygwin32\bin\cygtk80.dll
  446k 1998/12/03 C:\Global\B20\H-i586-cygwin32\bin\cygwin1.dll
  446k 1998/12/03
C:\Global\B20\H-i586-cygwin32\i586-cygwin32\lib\cygwin1.dll
  385k 1998/09/25
C:\Global\B20\H-i586-cygwin32\i586-cygwin32\lib\cygwinb19.dll
Use -h to see help about each section

-----------------------------------------------------------------------
Dipl.-Ing. Lampos Ferekidis		New Transducers Ltd.

Unit 7 Spitfire Close			work:    +44-(0)1480-451777
Ermine Business Park			fax:     +44-(0)1480-437177
Huntingdon PE 18 6YA
UK

Klewergarten 12				private: +49-(0)511-4583804
30449 Hannover
Germany
mailto:[email-masked]
----------------------------------------------------------------------- 
-
For help on using this list (especially unsubscribing), send a message to
"[email-masked]" with one line of text: "help".