From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 18217 invoked by alias); 18 May 2011 22:47:52 -0000 Received: (qmail 18207 invoked by uid 22791); 18 May 2011 22:47:51 -0000 X-SWARE-Spam-Status: Yes, hits=6.2 required=5.0 tests=AWL,BAYES_00,DKIM_SIGNED,DKIM_VALID,FREEMAIL_FROM,RCVD_IN_DNSWL_LOW,RFC_ABUSE_POST,T_TO_NO_BRKTS_FREEMAIL X-Spam-Check-By: sourceware.org Received: from mail-wy0-f171.google.com (HELO mail-wy0-f171.google.com) (74.125.82.171) by sourceware.org (qpsmtpd/0.43rc1) with ESMTP; Wed, 18 May 2011 22:47:37 +0000 Received: by wyb32 with SMTP id 32so2058366wyb.2 for ; Wed, 18 May 2011 15:47:36 -0700 (PDT) MIME-Version: 1.0 Received: by 10.216.142.133 with SMTP id i5mr2343776wej.43.1305758855597; Wed, 18 May 2011 15:47:35 -0700 (PDT) Received: by 10.216.171.65 with HTTP; Wed, 18 May 2011 15:47:35 -0700 (PDT) Date: Wed, 18 May 2011 22:47:00 -0000 Message-ID: Subject: How does one make a bash "builtin" (shared loadable module) on cygwin From: Rocky Bernstein To: cygwin@cygwin.com Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: quoted-printable X-IsSubscribed: yes Mailing-List: contact cygwin-help@cygwin.com; run by ezmlm Precedence: bulk List-Id: List-Subscribe: List-Archive: List-Post: List-Help: , Sender: cygwin-owner@cygwin.com Mail-Followup-To: cygwin@cygwin.com X-SW-Source: 2011-05/txt/msg00258.txt.bz2 =A0I am trying to build a bash "builtin" (a dynamically loadable bash module) on cygwin. Here's the error message I get via automake/make: $ make gcc =A0-g -O2 =A0 -o set0.exe -shared set0-set0.o set0-set0.o: In function `set0_builtin': /tmp/bashdb/builtin/set0.c:46: undefined reference to `_builtin_error' /tmp/bashdb/builtin/set0.c:47: undefined reference to `_builtin_usage' /tmp/bashdb/builtin/set0.c:51: undefined reference to `_dollar_vars' /tmp/bashdb/builtin/set0.c:52: undefined reference to `_xmalloc' /tmp/bashdb/builtin/set0.c:52: undefined reference to `_dollar_vars' /tmp/bashdb/builtin/set0.c:42: undefined reference to `_builtin_error' /tmp/bashdb/builtin/set0.c:43: undefined reference to `_builtin_usage' collect2: ld returned 1 exit status make: *** [set0.exe] Error 1 The complete Makefile.am and code is listed at http://bashdb.git.sourceforge.net/git/gitweb.cgi?p=3Dbashdb/bashdb;a=3Dtree= ;f=3Dbuiltin;h=3D428fd8f3598c88eabb10b3ba800fb900da9f858c;hb=3DHEAD Perhaps I need to tell cygwin that these symbols are supposed to be undefined since they are part of bash? I've tried looking at gcc documentation for linker options but it's all a mystery to me. Thanks in advance for help, suggestions or links to documentation. Regards, =A0 =A0rocky -- Problem reports: http://cygwin.com/problems.html FAQ: http://cygwin.com/faq/ Documentation: http://cygwin.com/docs.html Unsubscribe info: http://cygwin.com/ml/#unsubscribe-simple