Mailing-List: contact cygwin-help AT cygwin DOT com; run by ezmlm List-Subscribe: List-Archive: List-Post: List-Help: , Sender: cygwin-owner AT cygwin DOT com Mail-Followup-To: cygwin AT cygwin DOT com Delivered-To: mailing list cygwin AT cygwin DOT com To: cygwin AT cygwin DOT com From: Mishel Subject: How to print out from DLL Date: Tue, 17 Feb 2004 10:42:01 +0000 (UTC) Lines: 58 Message-ID: Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 7bit X-Complaints-To: usenet AT sea DOT gmane DOT org X-Gmane-NNTP-Posting-Host: main.gmane.org User-Agent: Loom/3.14 (http://gmane.org/) X-Loom-IP: 217.110.211.78 (Mozilla/4.0 (compatible; MSIE 6.0; Windows NT 5.0)) Hi, I have a problem with printing to the standart output from DLL. 1. I create simple DLL(aaaDll.dll) in the MVS 6.0. This DLL has only one function(fnAaaDll()), which prints some strings. 2. I create another console application project(aaaTestDll.cpp) in MVS 6.0 which has only main function. In this function I call function from DLL(befor a link the interface library for DLL). In this case I have all printings in the console! 3. I cleate the interface library for this DLL in the Cygwin: cd ./Release echo EXPORTS > aaaDll.def echo fnAaaDll >> aaaDll.def dlltool --def aaaDll.def --dllname aaaDll.dll --output-lib libAaa.a cp libAaa.a /usr/local/lib/libAaa.a cd .. and I compile my test programm in the Cygwin(see makefile): AAALDPATH = -L/usr/local/lib CC = g++ -pipe -Wno-deprecated LN = g++ -static LIBS = -lAaa LDPATH = $(AAALDPATH) WARN = -Wall -Wbad-function-cast -Wcast-qual \ -Wwrite-strings -Wstrict-prototypes -Wmissing-prototypes \ # -Wcast-align -Wredundant-decls -Winline CFLAGS = $(WARN) APPNAME = aaa APPOBJS = aaaTestDll.o $(APPNAME) :$(APPOBJS) $(LN) -o $@ $(APPOBJS) $(LDPATH) $(LIBS) strip $@.exe %.o: %.c $(CC) -c -g -Wall $(DEF) $(INCL) $< -o $@ clean: rm -f *.o rm -f .depend rm -f $(APPNAME).exe make -f makefile .depend .depend: $(CC) $(DEF) $(INCL) -E -M -MG $(shell ls *.c*) > .depend include .depend I run result and no printings on the console! Question: How I can print from the DLL under Cygwin? Best regards, Mishel. -- Unsubscribe info: http://cygwin.com/ml/#unsubscribe-simple Problem reports: http://cygwin.com/problems.html Documentation: http://cygwin.com/docs.html FAQ: http://cygwin.com/faq/