Re: [AD] _al_file_size removal |
[ Thread Index |
Date Index
| More lists.liballeg.org/allegro-developers Archives
]
On 2006-06-15, Peter Wang <tjaden@xxxxxxxxxx> wrote:
> On 2006-06-14, Matthew Leverton <meffer@xxxxxxxxxx> wrote:
> > > *** Error !!! ***
> > > symbols missing => DLL binary compatibility broken
> > > you need to add the following symbols:
> > > _al_file_size
> > >
> > I was just looking at that when I got the e-mail...
> >
> > I had to add it to both of these files:
> >
> > include/allegro/internal/aintern.h
> > src/win/wfile.c
>
> Thanks. I think it should be in src/file.c, just to be safe.
I've applied the attached patch.
Peter
----------------------------------------------------------------------
r5875 (orig r5828): tjaden | 2006-06-15 22:57:38 +1000
Add back a definition of _al_file_size for binary compatibility with 4.2.0
(at least on Windows, where _al_file_size was exposed in the DLL).
----------------------------------------------------------------------
--- mirror/allegro/allegro/branches/4.2/src/file.c (revision 5874)
+++ mirror/allegro/allegro/branches/4.2/src/file.c (revision 5875)
@@ -776,7 +776,18 @@ uint64_t file_size_ex(AL_CONST char *fil
/* For binary compatibility with 4.2.0. */
long file_size(AL_CONST char *filename)
{
- return file_size_ex(filename);
+ return file_size_ex(filename);
+}
+
+
+
+/* For binary compatibility with 4.2.0.
+ * This is an internal symbol and only required because _al_file_size was
+ * exposed in the Windows DLL.
+ */
+long _al_file_size(AL_CONST char *filename)
+{
+ return _al_file_size_ex(filename);
}
--- mirror/allegro/allegro/branches/4.2/include/allegro/internal/aintern.h (revision 5874)
+++ mirror/allegro/allegro/branches/4.2/include/allegro/internal/aintern.h (revision 5875)
@@ -123,6 +123,9 @@ AL_FUNC(int, _al_drive_exists, (int driv
AL_FUNC(int, _al_getdrive, (void));
AL_FUNC(void, _al_getdcwd, (int drive, char *buf, int size));
+/* obsolete; only exists for binary compatibility with 4.2.0 */
+AL_FUNC(long, _al_file_size, (AL_CONST char *filename));
+
/* packfile stuff */
AL_VAR(int, _packfile_filesize);