Return-Path: owner-postman Received: from localhost.Berkeley.EDU (localhost.Berkeley.EDU [127.0.0.1]) by nobozo.CS.Berkeley.EDU (8.6.9/8.6.3) with SMTP id VAA23724 for postgres-redist; Mon, 31 Oct 1994 21:31:57 -0800 Resent-From: POSTGRES mailing list Resent-Message-Id: <199411010531.VAA23724@nobozo.CS.Berkeley.EDU> X-Authentication-Warning: nobozo.CS.Berkeley.EDU: Host localhost.Berkeley.EDU didn't use HELO protocol Sender: owner-postman@postgres.Berkeley.EDU X-Return-Path: owner-postman Received: from beaver.cs.washington.edu (beaver.cs.washington.edu [128.95.1.1]) by nobozo.CS.Berkeley.EDU (8.6.9/8.6.3) with ESMTP id VAA23714 for ; Mon, 31 Oct 1994 21:31:55 -0800 From: bachesta@angst.tera.com Received: from tera.com (tera.com [128.95.3.1]) by beaver.cs.washington.edu (8.6.9/7.1be+) with SMTP id VAA26211 for ; Mon, 31 Oct 1994 21:31:28 -0800 Received: from angst.tera.com by tera.com (4.1/SMI-4.0) id AA03888; Mon, 31 Oct 94 21:31:00 PST Received: from localhost by angst.tera.com (4.1/SMI-4.1) id AA24046; Mon, 31 Oct 94 21:30:59 PST Message-Id: <9411010530.AA24046@angst.tera.com> To: postgres@postgres.Berkeley.EDU Subject: problems building src/backend/storage/ipc/s_lock.c Date: Mon, 31 Oct 94 21:30:59 PST Resent-To: postgres-redist@postgres.Berkeley.EDU Resent-Date: Mon, 31 Oct 94 21:31:57 -0800 Resent-XMts: smtp I'm busy porting postgres 4.2 to NetBSD 1.0 and I came across the following error: cc -O -DPORTNAME_netbsd -DPOSTPORT='"4321"' -DDEADLOCK_TIMEOUT=60 -DPOSTGRESDIR='"/usr/local/postgres"' -DDATADIR='"/usr/local/postgres/data"' -DBINDIR='"/usr/local/postgres/bin"' -I/usr/postgres/src/backend/. -I/usr/postgres/src/backend/obj -I/usr/postgres/src/backend/tmp -I/usr/postgres/src/backend/port/netbsd -c /usr/postgres/src/backend/storage/ipc/s_lock.c /usr/postgres/src/backend/storage/ipc/s_lock.c: In function `tas': /usr/postgres/src/backend/storage/ipc/s_lock.c:283: `m' undeclared (first use this function) /usr/postgres/src/backend/storage/ipc/s_lock.c:283: (Each undeclared identifier is reported only once /usr/postgres/src/backend/storage/ipc/s_lock.c:283: for each function it appears in.) *** Error code 1 The code segment that is giving me the problem looks like this #if defined(__i386__) && defined(__GNUC__) tas(lock) slock_t *lock; { slock_t res; __asm__("xchgb %0,%1":"=q" (res),"=m" (*m):"0" (0x1)); return(res); } line 283 is the __asm__ line. My questin is where is "m" supposed to be defined and why does this compile for other OS's (i.e. linux freebsd), or does it. I'm not an assembly guru so any help you can give me is appreciated. Thanks, Jim Bachesta bachesta@tera.com ============================================================================== To add/remove yourself to/from the POSTGRES mailing list: send mail with the subject line ADD or DEL to "postgres-request@postgres.Berkeley.EDU" If this fails, send mail to "post_questions@postgres.Berkeley.EDU" and a human will deal with it. DO NOT post to the "postgres" mailing list. ==============================================================================