Path: utzoo!utgpu!news-server.csri.toronto.edu!rpi!think.com!spool.mu.edu!agate!ucbvax!osf.org!dbrooks From: dbrooks@osf.org Newsgroups: comp.windows.x.motif Subject: Re: Problems compiling FileSelectionBox Widget Message-ID: <9105221736.AA00920@osf.osf.org> Date: 22 May 91 17:36:29 GMT Article-I.D.: osf.9105221736.AA00920 Sender: daemon@ucbvax.BERKELEY.EDU Distribution: inet Organization: The Internet Lines: 46 |>|I'm attempting to add a File selection box to an application, but |>|can't get past compiling it without the following error: |>| |>|ld: Undefined external - |>|_regcmp |>|_regex |>|ld: output file still contains undefined symbols |>|ld: (Warning) did not generate an output file |>| |> Semi-obviously you're missing a library; Maybe. > No, an unresolved external caused by a missing library or > object module is exactly what's wrong. Maybe. The correct solution, if you have access to the Motif source, or you can put your hands round the throat of whoever supplied the binaries, is to re-compile FileSB.c with -DNO_REGEX, as described in the release notes. This was actually working by 1.0.2, and in all of 1.1.x. (The above, and the below, assumes that if you don't have regcmp in your libc, you do have re_comp. Everyone I've met has one or the other). If you can't get at the source, link in a module patterned something like this (not tested; it's been a while since we dealt with this). char *regcmp(a, b) char *a, *b; { char *re_comp(); return re_comp(a) ? (char *)0 : a; } int regex(a, b) char *a, *b; { int re_exec(); return re_exec(b); } David Brooks Systems Engineering Open Software Foundation