XCOMM $XConsortium: bsdLib.tmpl /main/3 1996/09/28 16:09:25 rws $
XCOMM $XFree86: xc/config/cf/bsdLib.tmpl,v 3.3.2.3 1999/12/02 14:27:24 hohndel Exp $

/*
 * FreeBSD/OpenBSD a.out shared library template
 */

#if !UseElfFormat && !defined(NetBSDArchitecture)

#ifndef FixupLibReferences
#define FixupLibReferences()						@@\
XMULIBONLY = -lXmu							@@\
XMULIB = $(XMULIBONLY) $(XTOOLLIB) $(XLIB)
#endif

#ifndef SharedXtReqs
#define SharedXtReqs /**/
#endif
#ifndef SharedXawReqs
#define SharedXawReqs /**/
#endif
#ifndef SharedXmuReqs
# if !defined(Mc68020Architecture) || !defined(OpenBSDArchitecture)
#  define SharedXmuReqs $(LDPRELIBS) $(XTOOLONLYLIB) $(XONLYLIB)
# else
   /* At least the hp300 and the sun3 OpenBSD ports need that */
#  define SharedXmuReqs $(LDPRELIBS) $(XTOOLLIB) $(EXTENSIONLIB) $(XONLYLIB)
# endif
#endif

#else /* UseElfFormat || defined(NetBSDArchitecture) */

/*
 * NetBSD/FreeBSD-ELF/OpenBSD-ELF shared library template
 * Cloned from Linux ELF rules, but with a minor number.
 */

#ifndef FixupLibReferences
#define FixupLibReferences()						@@\
XMULIBONLY = -lXmu							@@\
XMULIB = $(XMULIBONLY) $(XTOOLLIB) $(XLIB)
#endif

#ifndef XawClientLibs
#define XawClientLibs $(XAWLIB) $(XMULIBONLY) $(XTOOLLIB) $(XLIB)
#endif

#define CplusplusLibC
#define FrescoSysLibs	CplusplusLibC MathLibrary

/* Allow for libpthread, as overridden by OS definitions */
#if !defined(SharedThreadReqs)
# if ThreadedX
#  ifdef BuildThreadStubLibrary
#   define SharedThreadReqs	-L$(BUILDLIBDIR) -lXThrStub 
#  else
#   define SharedThreadReqs	-pthread
#  endif
# else
#  define SharedThreadReqs /**/
# endif /* ThreadedX */
#endif /* !defined(SharedThreadReqs) */

#define SharedX11Reqs	SharedThreadReqs
#define SharedOldXReqs	$(LDPRELIBS) $(XLIBONLY)
#define SharedXtReqs	$(LDPRELIBS) $(XLIBONLY) $(SMLIB) $(ICELIB) SharedThreadReqs
#define SharedXawReqs	$(LDPRELIBS) $(XMULIB) $(XTOOLLIB) $(XLIB)
#define SharedXmuReqs	$(LDPRELIBS) $(XTOOLLIB) $(XLIB)
#define SharedXextReqs	$(LDPRELIBS) $(XLIBONLY)
#define SharedXiReqs	$(LDPRELIBS) $(XLIB)
#define SharedPexReqs	$(LDPRELIBS) $(XLIBONLY) MathLibrary
#define SharedXtstReqs	$(LDPRELIBS) $(XLIB)
#define SharedXieReqs	$(LDPRELIBS) $(XLIBONLY)
#define SharedSMReqs	$(LDPRELIBS) $(ICELIB)
#define SharedFrescoReqs	$(LDPRELIBS) $(XLIBONLY) FrescoSysLibs
#define SharedXtfReqs	$(LDPRELIBS) $(FRESCOLIB) $(XTOOLLIB) $(XLIB) FrescoSysLibs

#endif /* !UseElfFormat && !defined(NetBSDArchitecture) */
