[Scummvm-cvs-logs] SF.net SVN: scummvm:[49977] scummvm/branches/gsoc2010-plugins/backends/ platform/gp2xwiz/gp2xwiz-loader.h
toneman1138 at users.sourceforge.net
toneman1138 at users.sourceforge.net
Fri Jun 18 02:18:26 CEST 2010
Revision: 49977
http://scummvm.svn.sourceforge.net/scummvm/?rev=49977&view=rev
Author: toneman1138
Date: 2010-06-18 00:18:26 +0000 (Fri, 18 Jun 2010)
Log Message:
-----------
added ELF loader header for gp2xwiz
Added Paths:
-----------
scummvm/branches/gsoc2010-plugins/backends/platform/gp2xwiz/gp2xwiz-loader.h
Added: scummvm/branches/gsoc2010-plugins/backends/platform/gp2xwiz/gp2xwiz-loader.h
===================================================================
--- scummvm/branches/gsoc2010-plugins/backends/platform/gp2xwiz/gp2xwiz-loader.h (rev 0)
+++ scummvm/branches/gsoc2010-plugins/backends/platform/gp2xwiz/gp2xwiz-loader.h 2010-06-18 00:18:26 UTC (rev 49977)
@@ -0,0 +1,67 @@
+/* ScummVM - Graphic Adventure Engine
+ *
+ * ScummVM is the legal property of its developers, whose names
+ * are too numerous to list here. Please refer to the COPYRIGHT
+ * file distributed with this source distribution.
+ *
+ * This program is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU General Public License
+ * as published by the Free Software Foundation; either version 2
+ * of the License, or (at your option) any later version.
+
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU General Public License for more details.
+
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
+ *
+ * $URL$
+ * $Id$
+ *
+ */
+
+#ifndef GP2XWIZ_LOADER_H
+#define GP2XWIZ_LOADER_H
+
+#include "elf32.h"
+
+#define MAXDLERRLEN 80
+
+class DLObject {
+ protected:
+ char *errbuf; /* For error messages, at least MAXDLERRLEN in size */
+
+ void *_segment, *_symtab;
+ char *_strtab;
+ int _symbol_cnt;
+ void *_dtors_start, *_dtors_end;
+
+ void seterror(const char *fmt, ...);
+ void unload();
+ bool relocate(int fd, unsigned long offset, unsigned long size);
+ bool load(int fd);
+
+ public:
+ bool open(const char *path);
+ bool close();
+ void *symbol(const char *name);
+ void discard_symtab();
+
+ DLObject(char *errbuf = NULL) : errbuf(_errbuf), _segment(NULL),_symtab(NULL),
+ _strtab(NULL), _symbol_cnt(0), _dtors_start(NULL), _dtors_end(NULL) {}
+};
+
+#define RTLD_LAZY 0
+
+extern "C" {
+ void *dlopen(const char *filename, int flags);
+ int dlclose(void *handle);
+ void *dlsym(void *handle, const char *symbol);
+ const char *dlerror();
+ void dlforgetsyms(void *handle);
+}
+
+#endif /* GP2XWIZ_LOADER_H */
Property changes on: scummvm/branches/gsoc2010-plugins/backends/platform/gp2xwiz/gp2xwiz-loader.h
___________________________________________________________________
Added: svn:mime-type
+ text/plain
Added: svn:keywords
+ Id URL
Added: svn:eol-style
+ native
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
More information about the Scummvm-git-logs
mailing list