1#ident "@(#)i386-netbsd-gcc.rul 1.14 21/04/28 " 2########################################################################### 3# Written 1997-2018 by J. Schilling 4########################################################################### 5# 6# Platform dependent MACROS for NetBSD 7# 8########################################################################### 9# Copyright (c) J. Schilling 10########################################################################### 11# The contents of this file are subject to the terms of the 12# Common Development and Distribution License, Version 1.0 only 13# (the "License"). You may not use this file except in compliance 14# with the License. 15# 16# See the file CDDL.Schily.txt in this distribution for details. 17# A copy of the CDDL is also available via the Internet at 18# http://www.opensource.org/licenses/cddl1.txt 19# 20# When distributing Covered Code, include this CDDL HEADER in each 21# file and include the License file CDDL.Schily.txt from this distribution. 22########################################################################### 23include $(SRCROOT)/$(RULESDIR)/rules.prg 24########################################################################### 25include $(SRCROOT)/$(RULESDIR)/cc-$(C_ARCH).rul 26 27OSDEFS += 28#OSDEFS += -DIS_UNIX 29 30KDEFINES= -DKERNEL -D_KERNEL 31 32LIB_PREFIX= lib 33LIB_SUFFIX= .a 34SHL_SUFFIX= .so.$(DYNMAJOR).$(DYNMINOR) 35 36LIB_SOCKET= 37LIB_MATH= -lm 38LIB_KVM= 39 40# 41# Sunpro C/C++ run on Solaris and Linux and both have linkers 42# that support mapfiles 43# 44MAPVERS= $(_MAPVERS) # This enables to use mapfiles 45# 46# The GNU linker is buggy and does not like the official order in linker map 47# files for symbol versioning. The following command reverses the order of 48# the version names in the linker map file. 49# 50MAPFILE_POST= | sed 's/^SCHILY/+SCHILY/' | tr '\012' '@' | tr '+' '\012' | tail -r | tr '@' '\012' 51 52#LDOPTS= $(LIBS_PATH) $(LDPATH) $(RUNPATH:-R%=-Wl,-R%) 53#LDOPTS= $(LIBS_PATH) $(LDPATH) 54LDOPTMAP= $(PMAPVERS:%=-Wl,--version-script=%) 55LDOPTDYN= -shared -Wl,-soname,$(TARGET) $(LDOPTMAP) 56 57RANLIB= $(NOECHO)echo " ==> RANDOMIZING ARCHIVE \"$@\""; ranlib 58