From owner-freebsd-questions Wed Sep 13 11:25:15 2000 Delivered-To: freebsd-questions@freebsd.org Received: from mail.disney.com (mail.disney.com [204.128.192.15]) by hub.freebsd.org (Postfix) with ESMTP id 3BCE437B423 for ; Wed, 13 Sep 2000 11:25:12 -0700 (PDT) Received: from pain10.corp.disney.com (root@pain10.corp.disney.com [153.7.110.100]) by mail.disney.com (Switch-2.0.1/Switch-2.0.1) with SMTP id e8DIP8S15303 for ; Wed, 13 Sep 2000 11:25:08 -0700 (PDT) Received: from louie.fa.disney.com by pain.corp.disney.com with ESMTP for freebsd-questions@freebsd.org; Wed, 13 Sep 2000 11:25:37 -0700 Received: from mercury.fan.fa.disney.com (mercury.fan.fa.disney.com [153.7.119.1]) by louie.fa.disney.com (8.9.2/8.9.2) with ESMTP id LAA18477 for ; Wed, 13 Sep 2000 11:25:06 -0700 (PDT) (envelope-from Jim.Pirzyk@disney.com) Received: from snoopy.fan.fa.disney.com by mercury.fan.fa.disney.com for freebsd-questions@freebsd.org; Wed, 13 Sep 2000 11:25:06 -0700 From: Jim Pirzyk Organization: Walt Disney Feature Animation To: freebsd-questions@freebsd.org Subject: ifdef SMP in lkm source and Makefile questions. Date: Wed, 13 Sep 2000 11:24:41 -0700 X-Mailer: KMail [version 1.0.28] Content-Type: text/plain MIME-Version: 1.0 Message-Id: <00091311251005.42186@snoopy.fan.fa.disney.com> Content-Transfer-Encoding: 8bit Sender: owner-freebsd-questions@FreeBSD.ORG Precedence: bulk X-Loop: FreeBSD.ORG I am trying to compile a Loadable kernel module that needs the SMP flag. How would I get the Makefile to read that SMP flag if the system really is SMP? So in my .c file I have #ifdef SMP Do special code here #endif What I can see, SMP is only defined when compiling kernel, but not the /sys/modules subdirs. Also how do I include in the makefile a file from a different dir? I had in the SRCS= line ../../foo/bar.c, but then the .o file was in the wrong dir. I changed it to bar.c and created a sym link back to ../../foo/bar.c - JimP -- --- @(#) $Id: dot.signature,v 1.9 2000/07/10 16:43:05 pirzyk Exp $ __o Jim.Pirzyk@disney.com ------------------------------------- _'\<,_ Senior Systems Engineer, Walt Disney Feature Animation (*)/ (*) To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-questions" in the body of the message