o_dir.c revision 160815
121173Sjkh/* crypto/o_dir.c -*- mode:C; c-file-style: "eay" -*- */
250479Speter/* Written by Richard Levitte (richard@levitte.org) for the OpenSSL
350479Speter * project 2004.
421173Sjkh */
521173Sjkh/* ====================================================================
621173Sjkh * Copyright (c) 2004 The OpenSSL Project.  All rights reserved.
721173Sjkh *
821173Sjkh * Redistribution and use in source and binary forms, with or without
921173Sjkh * modification, are permitted provided that the following conditions
1021173Sjkh * are met:
1121173Sjkh *
1221173Sjkh * 1. Redistributions of source code must retain the above copyright
1321173Sjkh *    notice, this list of conditions and the following disclaimer.
14159363Strhodes *
15159363Strhodes * 2. Redistributions in binary form must reproduce the above copyright
16159363Strhodes *    notice, this list of conditions and the following disclaimer in
17159363Strhodes *    the documentation and/or other materials provided with the
18159363Strhodes *    distribution.
19159363Strhodes *
20159363Strhodes * 3. All advertising materials mentioning features or use of this
2164057Salex *    software must display the following acknowledgment:
2264057Salex *    "This product includes software developed by the OpenSSL Project
2364057Salex *    for use in the OpenSSL Toolkit. (http://www.openssl.org/)"
2421173Sjkh *
2564057Salex * 4. The names "OpenSSL Toolkit" and "OpenSSL Project" must not be used to
2664057Salex *    endorse or promote products derived from this software without
27100446Swosch *    prior written permission. For written permission, please contact
2821369Smax *    openssl-core@openssl.org.
2964057Salex *
3093217Sru * 5. Products derived from this software may not be called "OpenSSL"
3164057Salex *    nor may "OpenSSL" appear in their names without prior written
3221173Sjkh *    permission of the OpenSSL Project.
3393217Sru *
3421173Sjkh * 6. Redistributions of any form whatsoever must retain the following
3521173Sjkh *    acknowledgment:
3664047Salex *    "This product includes software developed by the OpenSSL Project
3764047Salex *    for use in the OpenSSL Toolkit (http://www.openssl.org/)"
3864047Salex *
3964047Salex * THIS SOFTWARE IS PROVIDED BY THE OpenSSL PROJECT ``AS IS'' AND ANY
4021173Sjkh * EXPRESSED OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
4121173Sjkh * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
4221173Sjkh * PURPOSE ARE DISCLAIMED.  IN NO EVENT SHALL THE OpenSSL PROJECT OR
4321173Sjkh * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
4493217Sru * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT
4521173Sjkh * NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
4621173Sjkh * LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
4721173Sjkh * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT,
4864047Salex * STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE)
4921173Sjkh * ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED
5093217Sru * OF THE POSSIBILITY OF SUCH DAMAGE.
5121173Sjkh * ====================================================================
5221173Sjkh *
5321173Sjkh * This product includes cryptographic software written by Eric Young
5421173Sjkh * (eay@cryptsoft.com).  This product includes software written by Tim
5521173Sjkh * Hudson (tjh@cryptsoft.com).
5621173Sjkh *
5721173Sjkh */
5821173Sjkh
5993217Sru#include <errno.h>
6037283Sjkh#include <e_os.h>
6121173Sjkh
6221173Sjkh/* The routines really come from the Levitte Programming, so to make
6321173Sjkh   life simple, let's just use the raw files and hack the symbols to
6421173Sjkh   fit our namespace.  */
6521173Sjkh#define LP_DIR_CTX OPENSSL_DIR_CTX
6621173Sjkh#define LP_dir_context_st OPENSSL_dir_context_st
67156171Sceri#define LP_find_file OPENSSL_DIR_read
68156171Sceri#define LP_find_file_end OPENSSL_DIR_end
6921173Sjkh
7021173Sjkh#include "o_dir.h"
7165298Smarkm
7221173Sjkh#define LPDIR_H
7321173Sjkh#if defined OPENSSL_SYS_UNIX || defined DJGPP
7421173Sjkh#include "LPdir_unix.c"
7521173Sjkh#elif defined OPENSSL_SYS_VMS
7621173Sjkh#include "LPdir_vms.c"
7721173Sjkh#elif defined OPENSSL_SYS_WIN32
7821173Sjkh#include "LPdir_win32.c"
7921173Sjkh#elif defined OPENSSL_SYS_WINCE
8021173Sjkh#include "LPdir_wince.c"
8121173Sjkh#else
8221173Sjkh#include "LPdir_nyi.c"
8321173Sjkh#endif
8421173Sjkh