From owner-freebsd-questions Mon Jul 1 6:38:35 2002 Delivered-To: freebsd-questions@freebsd.org Received: from mx1.FreeBSD.org (mx1.FreeBSD.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 46CE537B400; Mon, 1 Jul 2002 06:38:31 -0700 (PDT) Received: from crag.niss.com (niss.com [169.207.33.46]) by mx1.FreeBSD.org (Postfix) with ESMTP id 1DD6243E09; Mon, 1 Jul 2002 06:38:30 -0700 (PDT) (envelope-from listS+freebsd-questions@niss.com) Received: from crag.niss.com (localhost.niss.com [127.0.0.1]) by crag.niss.com (8.11.6/8.11.6) with ESMTP id g61DcQ601786; Mon, 1 Jul 2002 08:38:26 -0500 (CDT) (envelope-from listS+freebsd-questions@niss.com) Message-Id: <200207011338.g61DcQ601786@crag.niss.com> From: Scott Bolte To: pfeifer@dbai.tuwien.ac.at Cc: freebsd-questions@FreeBSD.ORG, freebsd-emulators@FreeBSD.ORG Subject: heads up: wine 20020605 broken on FreeBSD, workaround included MIME-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-ID: <1783.1025530706.1@crag.niss.com> Date: Mon, 01 Jul 2002 08:38:26 -0500 Sender: owner-freebsd-questions@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG Over the weekend I tried to get wine 20020605 to run on a new installation of FreeBSD 4.6. It took a while, I haven't tried wine since 1997 after all, but I determined that my problems were due to configure's reentrant libc test failing when building the port. The wine_cv_libc_reentrant test in configure.ac first checks for Linux (__errno_location) and then tests for FreeBSD (__error). I don't have more time to figure out why, but nesting the FreeBSD test that way results in a false negative. The configuration will continue, as will the build, but the resulting non-reentrant code goes into an endless loop when trying to spawn threads. A crude workaround, for FreeBSD users at least, is to replace the Linux test with the FreeBSD one. This needs to be done before configure is run. I did it by hand, but I expect the following code would do the trick. % cd /usr/ports/emulators/wine % make patch % perl -i -pe 's/__errno_location/__error/' work/wine-20020605/configure.ac % make % make install Below is the autoconf test script that demonstrates the problem. It needs to be run in /usr/ports/emulators/wine/work/wine-20020605/configure.ac Scott P.S. I'm not on the freebsd-emulators mailing list, but I see from freebsd-questions that at least one other person got wine to compile on 4.6. I can't explain why it worked for him and not for me. However, I installed a brand new copy of 4.6 from the standard ISO images just to run wine. ---- testconf.ac dnl Process this file with autoconf to produce a configure script. dnl Original author: Michael Patra dnl See ChangeLog file for detailed change history. m4_define(WINE_VERSION,regexp(m4_include(VERSION),[version \([-.0-9A-Za-z]+\)],[\1])) AC_PREREQ(2.53) AC_INIT([Wine],WINE_VERSION) AC_CONFIG_SRCDIR(server/atom.c) AC_CONFIG_AUX_DIR(tools) dnl **** Check for some programs **** AC_PROG_CC dnl **** Check for reentrant libc **** wine_cv_libc_reentrant=no dnl ##### dnl ##### There is a problem if the FreeBSD test is nested dnl ##### after the Linux test. In that instance, it fails. dnl ##### If, on the other hand, it is tested first, it works. dnl ##### dnl ##### Swap the order of two following test case to see dnl ##### how they differ. (Ignore the second case since it dnl ##### will use cached data.) dnl ##### dnl FreeBSD style errno location WINE_CHECK_ERRNO([__error], [wine_cv_libc_reentrant=__error]) dnl Linux style errno location WINE_CHECK_ERRNO([__errno_location], [wine_cv_libc_reentrant=__errno_location], dnl FreeBSD style errno location WINE_CHECK_ERRNO([__error], [wine_cv_libc_reentrant=__error] )) To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-questions" in the body of the message