- use -Os to shrink bianries

- remove local shrinked memcpy() from bootxx.c bacause
  now it's identical with __OPTIMIZE_SIZE__ libsa one
  derived from src/common/lib/libc/string/bcopy.c.

Tested netboot from le0 and bootxx + boot from sd0 on SS1+.
This commit is contained in:
tsutsui 2009-03-23 13:47:32 +00:00
parent 9c6c3c68dd
commit 2a6ed85992
2 changed files with 3 additions and 19 deletions

View File

@ -1,4 +1,4 @@
# $NetBSD: Makefile.buildboot,v 1.23 2005/12/11 12:19:08 christos Exp $
# $NetBSD: Makefile.buildboot,v 1.24 2009/03/23 13:47:32 tsutsui Exp $
#
# This file is for the sparc `boot' and `bootxx' only; it does not
# currently play well on a 64-bit system.
@ -34,7 +34,7 @@ RELOC_BOOTXX= 300000
CPPFLAGS+= -D_STANDALONE -DSUN4 -DSUN4C -DSUN4M -DSUN4D -DHEAP_VARIABLE
CPPFLAGS+= -I. -I${.CURDIR}/../../.. -I${.CURDIR}/../../../..
CFLAGS= -O2
CFLAGS= -Os
CFLAGS+= -Wall -Wstrict-prototypes -Wmissing-prototypes -ffreestanding
### find out what to use for libkern

View File

@ -1,4 +1,4 @@
/* $NetBSD: bootxx.c,v 1.22 2009/03/19 14:05:24 he Exp $ */
/* $NetBSD: bootxx.c,v 1.23 2009/03/23 13:47:32 tsutsui Exp $ */
/*-
* Copyright (c) 1998 The NetBSD Foundation, Inc.
@ -140,19 +140,3 @@ loadboot(struct open_file *f, char *addr)
}
}
/*
* We don't need the overlap handling feature that the libkern version
* of memcpy() provides. We DO need code compactness..
*/
void *
memcpy(void *dst, const void *src, size_t n)
{
const char *p = src;
char *q = dst;
while (n-- > 0)
*q++ = *p++;
return dst;
}