Cleanups.

committer: mfx <mfx> 1059739807 +0000
This commit is contained in:
Markus F.X.J. Oberhumer
2003-08-01 12:10:07 +00:00
parent ab37b5ea0c
commit 365a3c0432
8 changed files with 20 additions and 12 deletions
+2 -2
View File
@@ -419,7 +419,7 @@ ifeq ($(DEBUG),1)
CFLAGS += -Od -ZI
LINK_EXE_LDFLAGS += /debug
else
CFLAGS += -O1 -GF -Gy
CFLAGS += -O1 -GF
LINK_EXE_LDFLAGS += /release
endif
RESOURCES := $(subst .rc,.res,$(notdir $(wildcard $(srcdir)/*.rc)))
@@ -491,7 +491,7 @@ ifeq ($(DEBUG),1)
CFLAGS += -Od -ZI
LINK_EXE_LDFLAGS += /debug
else
CFLAGS += -O1 -GF -Gy
CFLAGS += -O1 -GF
LINK_EXE_LDFLAGS += /release
##LINK_EXE_LDFLAGS += /opt:nowin98
endif
+1 -1
View File
@@ -282,7 +282,7 @@
#undef __attribute_packed
#if defined(__GNUC__) || defined(__INTEL_COMPILER)
# if (1 && ACC_ARCH_IA32)
# if (1 && (ACC_ARCH_IA32 || ACC_ARCH_IA64))
# define __attribute_packed
# else
# define __attribute_packed __attribute__((__packed__,__aligned__(1)))
+1 -1
View File
@@ -139,7 +139,7 @@ void MemBuffer::fill(unsigned off, unsigned len, int value)
//
**************************************************************************/
#define PTR(p) ((unsigned)(p) & 0xffffffff)
#define PTR(p) ((unsigned) ((acc_uintptr_t)(p) & 0xffffffff))
#define MAGIC1(p) (PTR(p) ^ 0xfefdbeeb)
#define MAGIC2(p) (PTR(p) ^ 0xfefdbeeb ^ 0x80024001)
+4 -1
View File
@@ -76,8 +76,11 @@ PackPs1::PackPs1(InputFile *f) :
COMPILE_TIME_ASSERT(sizeof(ps1_exe_t) == 188);
COMPILE_TIME_ASSERT(PS_HDR_SIZE > sizeof(ps1_exe_t));
COMPILE_TIME_ASSERT(SZ_IH_BKUP == 40);
#if defined(WITH_NRV)
COMPILE_TIME_ASSERT(NRV_LOADER_CRC32 == 0xd78b1eb4);
#endif
fdata_size = file_size-PS_HDR_SIZE;
fdata_size = file_size - PS_HDR_SIZE;
}
+2 -2
View File
@@ -703,7 +703,7 @@ static size_t dopr(char *buffer, size_t maxlen, const char *format, va_list args
strvalue = va_arg (args, const char *);
if (!strvalue) strvalue = "(NULL)";
if (max == -1) {
max = strlen(strvalue);
max = (int) strlen(strvalue);
}
if (min > 0 && max >= 0 && min > max) max = min;
fmtstr (buffer, &currlen, maxlen, strvalue, flags, min, max);
@@ -728,7 +728,7 @@ static size_t dopr(char *buffer, size_t maxlen, const char *format, va_list args
} else {
int *num;
num = va_arg (args, int *);
*num = currlen;
*num = (int) currlen;
}
break;
case '%':
+2 -2
View File
@@ -71,8 +71,8 @@ vpath %.ash $(UCL_MR3K)
# // tools
# ************************************************************************/
NASM = nasm -O2 -w+macro-params -w+orphan-labels
NASM += -i$(srcdir)/
NASM = nasm -O2 -w+macro-params -w+macro-selfref -w+number-overflow -w+orphan-labels
NASM += -I$(srcdir)/
APP_I386 = perl -w $(srcdir)/scripts/app_i386.pl
BIN2H = perl -w $(srcdir)/scripts/bin2h.pl
+1 -1
View File
@@ -454,7 +454,7 @@ void UiPacker::doCallback(unsigned isize, unsigned osize)
if (osize > 0)
ratio = get_ratio(isize, osize);
int buflen = &s->msg_buf[sizeof(s->msg_buf)] - m;
int buflen = (int) (&s->msg_buf[sizeof(s->msg_buf)] - m);
upx_snprintf(m, buflen, " %3d.%1d%% %c ",
ratio / 10000, (ratio % 10000) / 1000,
spinner[s->spin_counter & 3]);
+7 -2
View File
@@ -35,7 +35,12 @@
/* avoid -W4 warnings in <windows.h> */
# pragma warning(disable: 4201 4214 4514)
#endif
#include "acc/acc_lib.ch"
#if 0
# include "acc/acc_lib.ch"
#else
# include "acc/acc_inci.h"
# include "acc/acclib/misc.ch"
#endif
/*************************************************************************
@@ -246,7 +251,7 @@ int upx_tolower(int c)
// filename util
**************************************************************************/
#if (ACC_OS_CYGWIN || ACC_OS_DOS16 || ACC_OS_DOS32 || ACC_OS_EMX || ACC_OS_TOS || ACC_OS_WIN16 || ACC_OS_WIN32 || ACC_OS_WIN64)
#if (ACC_OS_CYGWIN || ACC_OS_DOS16 || ACC_OS_DOS32 || ACC_OS_EMX || ACC_OS_OS2 || ACC_OS_OS16 || ACC_OS_TOS || ACC_OS_WIN16 || ACC_OS_WIN32 || ACC_OS_WIN64)
static const char dir_sep[] = "/\\";
#define fn_is_drive(s) (s[0] && s[1] == ':')