$NetBSD: patch-ab,v 1.16 2013/01/06 03:21:47 ryoon Exp $

(1.9) Convert -lossaudio to portable $(LIBOSSAUDIO)
      Make this work with audio/oss again.

(1.13) Add NetBSDArchitecture

(1.14) In server/Imakefile add a target for $(VOXWARELIBS) that call make for
the targets directory.

This should fix the occasional problem were make complains with
"don't know how to make dda/voxware/libvoxware.a"

(1.5) Taking care nasd.conf (etc)

--- server/Imakefile.orig	Thu Feb 26 01:16:01 2009
+++ server/Imakefile
@@ -60,8 +60,8 @@ XCOMM $NCDId: @(#)Imakefile,v 1.17 1995/12/06 01:33:07
         SYSLIBS =
 #endif
 
-#ifdef NetBSDArchitecture
-        SYSLIBS = -lossaudio
+#if defined(NetBSDArchitecture) || defined(OpenBSDArchitecture)
+        SYSLIBS = $(LIBOSSAUDIO)
 #endif
 
            CBRT =
@@ -96,7 +96,7 @@ ALL1 = nasd
 #endif
 
 
-#if defined(i386SVR4Architecture) || defined(__FreeBSD_kernel__) || defined(__FreeBSD__) || defined(FreeBSDArchitecture) || defined(LinuxArchitecture) || defined(i386BsdArchitecture) || defined(USLArchitecture) || defined(cygwinArchitecture) || defined(__DragonFly__)
+#if defined(i386SVR4Architecture) || defined(__FreeBSD_kernel__) || defined(__FreeBSD__) || defined(NetBSDArchitecture) || defined(FreeBSDArchitecture) || defined(LinuxArchitecture) || defined(i386BsdArchitecture) || defined(USLArchitecture) || defined(cygwinArchitecture) || defined(__DragonFly__) || defined(OpenBSDArchitecture)
 # define CanBuildAuServer	YES
 
 #if !defined(GNUMachArchitecture)
@@ -206,23 +206,34 @@ dirs: FRC								@@\
 	$(MAKE) $(MFLAGS) PassCDebugFlags all				@@\
 									@@\
 FRC:
+
 #endif /* ForceSubdirs */
 #endif /* Project X < 5 */
 
 ForceSubdirs($(DEPDIRS) $(SUBDIRS))
 
+$(VOXWARELIBS):
+	@echo "making all in $(CURRENT_DIR)/${@D}..."
+	@(cd ${@D} && $(MAKE) $(MFLAGS) $(PARALLELMFLAGS) \		@@\ 
+		PassCDebugFlags all) || exit $$?
+
 clean::
 	$(RM) $(ALL)
 
  ETCDIR = NasConfigSearchPath
+ EGDIR = ${PREFIX}/share/examples/nas
 
 InstallManPage(nasd,$(MANDIR))
 #ifdef InstallGenManPage
 InstallGenManPage(nasd.conf,$(FILEMANDIR),$(FILEMANSUFFIX))
 #else
+#ifdef InstallNamedTarget
+InstallNamedTarget(install.man,nasd.conf.man,$(INSTMANFLAGS),$(FILEMANDIR),nasd.conf.$(FILEMANSUFFIX))
+#else
 InstallManPage(nasd.conf,$(FILEMANDIR))
 #endif
-InstallNonExecFile(nasd.conf.eg,$(ETCDIR))
+#endif
+InstallNonExecFile(nasd.conf.eg,$(EGDIR))
 
 #else /* CanBuildAuServer */
 
