635c83753ed04cf3637e019af0e15ba40e07f2fevboxsync/*
635c83753ed04cf3637e019af0e15ba40e07f2fevboxsync * Copyright 1995-1998 by Metro Link, Inc.
635c83753ed04cf3637e019af0e15ba40e07f2fevboxsync *
635c83753ed04cf3637e019af0e15ba40e07f2fevboxsync * Permission to use, copy, modify, distribute, and sell this software and its
635c83753ed04cf3637e019af0e15ba40e07f2fevboxsync * documentation for any purpose is hereby granted without fee, provided that
635c83753ed04cf3637e019af0e15ba40e07f2fevboxsync * the above copyright notice appear in all copies and that both that
635c83753ed04cf3637e019af0e15ba40e07f2fevboxsync * copyright notice and this permission notice appear in supporting
635c83753ed04cf3637e019af0e15ba40e07f2fevboxsync * documentation, and that the name of Metro Link, Inc. not be used in
635c83753ed04cf3637e019af0e15ba40e07f2fevboxsync * advertising or publicity pertaining to distribution of the software without
635c83753ed04cf3637e019af0e15ba40e07f2fevboxsync * specific, written prior permission. Metro Link, Inc. makes no
635c83753ed04cf3637e019af0e15ba40e07f2fevboxsync * representations about the suitability of this software for any purpose.
635c83753ed04cf3637e019af0e15ba40e07f2fevboxsync * It is provided "as is" without express or implied warranty.
635c83753ed04cf3637e019af0e15ba40e07f2fevboxsync *
635c83753ed04cf3637e019af0e15ba40e07f2fevboxsync * METRO LINK, INC. DISCLAIMS ALL WARRANTIES WITH REGARD TO THIS SOFTWARE,
635c83753ed04cf3637e019af0e15ba40e07f2fevboxsync * INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS, IN NO
635c83753ed04cf3637e019af0e15ba40e07f2fevboxsync * EVENT SHALL METRO LINK, INC. BE LIABLE FOR ANY SPECIAL, INDIRECT OR
635c83753ed04cf3637e019af0e15ba40e07f2fevboxsync * CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE,
635c83753ed04cf3637e019af0e15ba40e07f2fevboxsync * DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR OTHER
635c83753ed04cf3637e019af0e15ba40e07f2fevboxsync * TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR
635c83753ed04cf3637e019af0e15ba40e07f2fevboxsync * PERFORMANCE OF THIS SOFTWARE.
635c83753ed04cf3637e019af0e15ba40e07f2fevboxsync */
635c83753ed04cf3637e019af0e15ba40e07f2fevboxsync/*
635c83753ed04cf3637e019af0e15ba40e07f2fevboxsync * Copyright (c) 1997-2001 by The XFree86 Project, Inc.
635c83753ed04cf3637e019af0e15ba40e07f2fevboxsync *
635c83753ed04cf3637e019af0e15ba40e07f2fevboxsync * Permission is hereby granted, free of charge, to any person obtaining a
635c83753ed04cf3637e019af0e15ba40e07f2fevboxsync * copy of this software and associated documentation files (the "Software"),
635c83753ed04cf3637e019af0e15ba40e07f2fevboxsync * to deal in the Software without restriction, including without limitation
635c83753ed04cf3637e019af0e15ba40e07f2fevboxsync * the rights to use, copy, modify, merge, publish, distribute, sublicense,
635c83753ed04cf3637e019af0e15ba40e07f2fevboxsync * and/or sell copies of the Software, and to permit persons to whom the
635c83753ed04cf3637e019af0e15ba40e07f2fevboxsync * Software is furnished to do so, subject to the following conditions:
635c83753ed04cf3637e019af0e15ba40e07f2fevboxsync *
635c83753ed04cf3637e019af0e15ba40e07f2fevboxsync * The above copyright notice and this permission notice shall be included in
635c83753ed04cf3637e019af0e15ba40e07f2fevboxsync * all copies or substantial portions of the Software.
635c83753ed04cf3637e019af0e15ba40e07f2fevboxsync *
635c83753ed04cf3637e019af0e15ba40e07f2fevboxsync * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
635c83753ed04cf3637e019af0e15ba40e07f2fevboxsync * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
635c83753ed04cf3637e019af0e15ba40e07f2fevboxsync * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL
635c83753ed04cf3637e019af0e15ba40e07f2fevboxsync * THE COPYRIGHT HOLDER(S) OR AUTHOR(S) BE LIABLE FOR ANY CLAIM, DAMAGES OR
635c83753ed04cf3637e019af0e15ba40e07f2fevboxsync * OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE,
635c83753ed04cf3637e019af0e15ba40e07f2fevboxsync * ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR
635c83753ed04cf3637e019af0e15ba40e07f2fevboxsync * OTHER DEALINGS IN THE SOFTWARE.
635c83753ed04cf3637e019af0e15ba40e07f2fevboxsync *
635c83753ed04cf3637e019af0e15ba40e07f2fevboxsync * Except as contained in this notice, the name of the copyright holder(s)
635c83753ed04cf3637e019af0e15ba40e07f2fevboxsync * and author(s) shall not be used in advertising or otherwise to promote
635c83753ed04cf3637e019af0e15ba40e07f2fevboxsync * the sale, use or other dealings in this Software without prior written
635c83753ed04cf3637e019af0e15ba40e07f2fevboxsync * authorization from the copyright holder(s) and author(s).
635c83753ed04cf3637e019af0e15ba40e07f2fevboxsync */
635c83753ed04cf3637e019af0e15ba40e07f2fevboxsync
635c83753ed04cf3637e019af0e15ba40e07f2fevboxsync#ifdef HAVE_XORG_CONFIG_H
635c83753ed04cf3637e019af0e15ba40e07f2fevboxsync#include <xorg-config.h>
635c83753ed04cf3637e019af0e15ba40e07f2fevboxsync#endif
635c83753ed04cf3637e019af0e15ba40e07f2fevboxsync
635c83753ed04cf3637e019af0e15ba40e07f2fevboxsync#ifndef _LOADER_H
635c83753ed04cf3637e019af0e15ba40e07f2fevboxsync#define _LOADER_H
635c83753ed04cf3637e019af0e15ba40e07f2fevboxsync
635c83753ed04cf3637e019af0e15ba40e07f2fevboxsync#include <X11/Xosdefs.h>
635c83753ed04cf3637e019af0e15ba40e07f2fevboxsync#include <X11/Xfuncproto.h>
635c83753ed04cf3637e019af0e15ba40e07f2fevboxsync#include <X11/Xmd.h>
635c83753ed04cf3637e019af0e15ba40e07f2fevboxsync
635c83753ed04cf3637e019af0e15ba40e07f2fevboxsync/* LoadModule proc flags; LD_FLAG_GLOBAL adds symbols to global
635c83753ed04cf3637e019af0e15ba40e07f2fevboxsync * namespace, default is to keep symbols local to module. */
635c83753ed04cf3637e019af0e15ba40e07f2fevboxsync#define LD_FLAG_GLOBAL 1
635c83753ed04cf3637e019af0e15ba40e07f2fevboxsync
635c83753ed04cf3637e019af0e15ba40e07f2fevboxsynctypedef struct _loader *loaderPtr;
635c83753ed04cf3637e019af0e15ba40e07f2fevboxsync
635c83753ed04cf3637e019af0e15ba40e07f2fevboxsync/* Each module loaded has a loaderRec */
635c83753ed04cf3637e019af0e15ba40e07f2fevboxsynctypedef struct _loader {
635c83753ed04cf3637e019af0e15ba40e07f2fevboxsync int handle; /* Unique id used to remove symbols from
635c83753ed04cf3637e019af0e15ba40e07f2fevboxsync * this module when it is unloaded */
635c83753ed04cf3637e019af0e15ba40e07f2fevboxsync int module; /* Unique id to identify compilation units */
635c83753ed04cf3637e019af0e15ba40e07f2fevboxsync char *name;
635c83753ed04cf3637e019af0e15ba40e07f2fevboxsync char *cname;
635c83753ed04cf3637e019af0e15ba40e07f2fevboxsync void *private; /* format specific data */
635c83753ed04cf3637e019af0e15ba40e07f2fevboxsync loaderPtr next;
635c83753ed04cf3637e019af0e15ba40e07f2fevboxsync} loaderRec;
635c83753ed04cf3637e019af0e15ba40e07f2fevboxsync
635c83753ed04cf3637e019af0e15ba40e07f2fevboxsync/* Compiled-in version information */
635c83753ed04cf3637e019af0e15ba40e07f2fevboxsynctypedef struct {
635c83753ed04cf3637e019af0e15ba40e07f2fevboxsync int xf86Version;
635c83753ed04cf3637e019af0e15ba40e07f2fevboxsync int ansicVersion;
635c83753ed04cf3637e019af0e15ba40e07f2fevboxsync int videodrvVersion;
635c83753ed04cf3637e019af0e15ba40e07f2fevboxsync int xinputVersion;
635c83753ed04cf3637e019af0e15ba40e07f2fevboxsync int extensionVersion;
635c83753ed04cf3637e019af0e15ba40e07f2fevboxsync int fontVersion;
635c83753ed04cf3637e019af0e15ba40e07f2fevboxsync} ModuleVersions;
635c83753ed04cf3637e019af0e15ba40e07f2fevboxsyncextern const ModuleVersions LoaderVersionInfo;
635c83753ed04cf3637e019af0e15ba40e07f2fevboxsync
635c83753ed04cf3637e019af0e15ba40e07f2fevboxsyncextern unsigned long LoaderOptions;
635c83753ed04cf3637e019af0e15ba40e07f2fevboxsync
635c83753ed04cf3637e019af0e15ba40e07f2fevboxsync/* Internal Functions */
635c83753ed04cf3637e019af0e15ba40e07f2fevboxsyncvoid LoaderDuplicateSymbol(const char *, const int);
635c83753ed04cf3637e019af0e15ba40e07f2fevboxsyncchar *_LoaderModuleToName(int);
635c83753ed04cf3637e019af0e15ba40e07f2fevboxsyncint LoaderOpen(const char *, const char *, int, int *, int *, int *, int);
635c83753ed04cf3637e019af0e15ba40e07f2fevboxsyncint LoaderHandleOpen(int);
635c83753ed04cf3637e019af0e15ba40e07f2fevboxsync
635c83753ed04cf3637e019af0e15ba40e07f2fevboxsync/* object to name lookup routines */
635c83753ed04cf3637e019af0e15ba40e07f2fevboxsyncchar *_LoaderHandleToName(int handle);
635c83753ed04cf3637e019af0e15ba40e07f2fevboxsyncchar *_LoaderHandleToCanonicalName(int handle);
635c83753ed04cf3637e019af0e15ba40e07f2fevboxsync
635c83753ed04cf3637e019af0e15ba40e07f2fevboxsync/* Loader backends. */
635c83753ed04cf3637e019af0e15ba40e07f2fevboxsync#include "dlloader.h"
635c83753ed04cf3637e019af0e15ba40e07f2fevboxsync
635c83753ed04cf3637e019af0e15ba40e07f2fevboxsync#endif /* _LOADER_H */
635c83753ed04cf3637e019af0e15ba40e07f2fevboxsync