Port to mingw+msys, BeOS and others.
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
libmms |
Won't Fix
|
Undecided
|
Unassigned |
Bug Description
Hello,
I did several fixes for porting LibMMS to Mingw+MSys, BeOS and minor fixes for Sun station and HP-UX.
Here you are the description of my changes:
configure.in
- Added AC_CANONICAL_HOST for detecting target host.
- Added AC_LIBTOOL_
- Added detection of some include files
- Added a case statement where you could add system dependant flags (actually only mingw and BeOS are using it).
src/bswap.h
- if types like u_int16_t are not available, it will use stdint types (required by mingw and others).
src/mms.c
- Some include files may not be present, so I added conditional includes.
- In Windows, the errors made with the network are not done with errno, but you must read/write them with WSA functions. So the errors are now handled with simple macros.
- In Windows, close() works for files only. If you want to close a socket you must call closesocket(). This has been unified too with a macro.
- In Windows, read() and write() work for files only. If you want to interact with a socket you must call send() and recv(). I made an #ifdef for fixing it.
- Added non blocking configuration on the socket for BeOS and Win32.
- Added function mms_internal_
- I simplified a piece of code by calling mms_close() instead of freeing everything manually.
- fixed mms_close(), now it does not crash if "this" is NULL.
src/mmsh.c
See all notes on mms.c
src/mmsio.h
- Added sys/types.h because you may need it for off_t declaration, otherwise mmsx may fail its compilation (fix for mingw).
src/mmsh.h
- Removed sys/types.h since it has been added into src/mmsio.h
src/mms.h
- Removed sys/types.h since it has been added into src/mmsio.h
Sincerely,
Carlo Bramini.
Changed in libmms: | |
status: | New → Won't Fix |
For the record, the patch is completely unmergeable to 0.6. 0.5 merged and worked here.