mirror of
https://github.com/openharmony/third_party_lame.git
synced 2026-07-01 23:04:15 -04:00
patch #80 OS/2 patches, submitted by KO Myung-Hun
This commit is contained in:
@@ -765,6 +765,9 @@ case $host_os in
|
||||
*darwin*)
|
||||
NASM_FORMAT="-f macho"
|
||||
;;
|
||||
*os2-emx*)
|
||||
NASM_FORMAT="-f aout -DAOUT"
|
||||
;;
|
||||
*)
|
||||
CYGWIN=no
|
||||
NASM_FORMAT="-f elf"
|
||||
|
||||
@@ -16,6 +16,17 @@
|
||||
<font color="#3366ff">blue = features and bug fixes which affect speed</font> <br>
|
||||
black = usability, portability, other
|
||||
<hr>
|
||||
<h3>LAME 3.100.1 under construction</h3>
|
||||
<ul>
|
||||
<li>
|
||||
Robert Hegemann
|
||||
<ul>
|
||||
<li>Patch submitted by KO Myung-Hun, patch ticket <i>[ #80 ] OS/2 patches</i>
|
||||
</li>
|
||||
</ul>
|
||||
</li>
|
||||
</ul>
|
||||
<br>
|
||||
<h3>LAME 3.100 October 13 2017</h3>
|
||||
<ul>
|
||||
<li>
|
||||
|
||||
+9
-1
@@ -55,6 +55,7 @@ char *strchr(), *strrchr();
|
||||
#endif
|
||||
|
||||
#ifdef __OS2__
|
||||
#define INCL_DOS
|
||||
#include <os2.h>
|
||||
#define PRTYC_IDLE 1
|
||||
#define PRTYC_REGULAR 2
|
||||
@@ -66,6 +67,10 @@ char *strchr(), *strrchr();
|
||||
# include <windows.h>
|
||||
#endif
|
||||
|
||||
#ifdef __EMX__
|
||||
# include <float.h>
|
||||
#endif
|
||||
|
||||
|
||||
/*
|
||||
main.c is example code for how to use libmp3lame.a. To use this library,
|
||||
@@ -201,7 +206,7 @@ setProcessPriority(int Priority)
|
||||
|
||||
#if defined(__OS2__)
|
||||
/* OS/2 priority functions */
|
||||
static void
|
||||
void
|
||||
setProcessPriority(int Priority)
|
||||
{
|
||||
int rc;
|
||||
@@ -475,6 +480,9 @@ c_main(int argc, char *argv[])
|
||||
#ifdef __EMX__
|
||||
/* This gives wildcard expansion on Non-POSIX shells with OS/2 */
|
||||
_wildcard(&argc, &argv);
|
||||
|
||||
/* This prevents SIGFPE */
|
||||
_control87(MCW_EM, MCW_EM);
|
||||
#endif
|
||||
#if defined( _WIN32 ) && !defined(__MINGW32__)
|
||||
set_process_affinity();
|
||||
|
||||
+37
-1
@@ -74,7 +74,43 @@ char *strchr(), *strrchr();
|
||||
#include <locale.h>
|
||||
#include <langinfo.h>
|
||||
#endif
|
||||
#endif
|
||||
#if defined(__KLIBC__) && !defined(iconv_open)
|
||||
/* kLIBC iconv_open() does not support UTF-16LE and //TRANSLIT */
|
||||
static iconv_t os2_iconv_open (const char *tocode, const char *fromcode)
|
||||
{
|
||||
char to[strlen(tocode) + 1];
|
||||
char from[strlen(fromcode) + 1];
|
||||
char *p;
|
||||
|
||||
strcpy(to, tocode);
|
||||
strcpy(from, fromcode);
|
||||
|
||||
if (!strncmp(to, "UTF-16", 6))
|
||||
{
|
||||
strcpy(to, "UCS-2");
|
||||
memmove(to + 5, to + 6, strlen(to + 6));
|
||||
}
|
||||
|
||||
p = strstr(to, "//");
|
||||
if (p)
|
||||
*p = '\0';
|
||||
|
||||
if (!strncmp(from, "UTF-16", 6))
|
||||
{
|
||||
strcpy(from, "UCS-2");
|
||||
memmove(from + 5, from + 6, strlen(from + 6));
|
||||
}
|
||||
|
||||
p = strstr(from, "//");
|
||||
if (p)
|
||||
*p = '\0';
|
||||
|
||||
return iconv_open(to, from);
|
||||
}
|
||||
|
||||
#define iconv_open(t, f) os2_iconv_open(t, f)
|
||||
#endif /* KLIBC iconv */
|
||||
#endif /* HAVE_ICONV */
|
||||
|
||||
#if defined _ALLOW_INTERNAL_OPTIONS
|
||||
#define INTERNAL_OPTS 1
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
|
||||
|
||||
; Copyright (C) 1999 URURI
|
||||
|
||||
; nasm�ѥޥ���
|
||||
@@ -18,7 +18,9 @@
|
||||
|
||||
BITS 32
|
||||
|
||||
%ifnidn __OUTPUT_FORMAT__,aout
|
||||
section .note.GNU-stack noalloc noexec nowrite progbits
|
||||
%endif
|
||||
|
||||
%ifdef YASM
|
||||
%define segment_code segment .text align=16 use32
|
||||
|
||||
@@ -37,7 +37,7 @@
|
||||
# define LAME_MAJOR_VERSION 3 /* Major version number */
|
||||
# define LAME_MINOR_VERSION 100 /* Minor version number */
|
||||
# define LAME_TYPE_VERSION 2 /* 0:alpha 1:beta 2:release */
|
||||
# define LAME_PATCH_VERSION 0 /* Patch level */
|
||||
# define LAME_PATCH_VERSION 1 /* Patch level */
|
||||
# define LAME_ALPHA_VERSION (LAME_TYPE_VERSION==0)
|
||||
# define LAME_BETA_VERSION (LAME_TYPE_VERSION==1)
|
||||
# define LAME_RELEASE_VERSION (LAME_TYPE_VERSION==2)
|
||||
|
||||
Reference in New Issue
Block a user