xref: /illumos-gate/usr/src/lib/libxcurses/Makefile.com (revision 63f91fbc3c024870d86dc3332a4a0080fb29bc40)
1#
2# CDDL HEADER START
3#
4# The contents of this file are subject to the terms of the
5# Common Development and Distribution License (the "License").
6# You may not use this file except in compliance with the License.
7#
8# You can obtain a copy of the license at usr/src/OPENSOLARIS.LICENSE
9# or http://www.opensolaris.org/os/licensing.
10# See the License for the specific language governing permissions
11# and limitations under the License.
12#
13# When distributing Covered Code, include this CDDL HEADER in each
14# file and include the License file at usr/src/OPENSOLARIS.LICENSE.
15# If applicable, add the following below this CDDL HEADER, with the
16# fields enclosed by brackets "[]" replaced with your own identifying
17# information: Portions Copyright [yyyy] [name of copyright owner]
18#
19# CDDL HEADER END
20#
21#
22# Copyright 2006 Sun Microsystems, Inc.  All rights reserved.
23# Use is subject to license terms.
24#
25# Copyright (c) 2018, Joyent, Inc.
26
27LIBRARY=	libcurses.a
28VERS=	.1
29
30# objects are grouped by source directory
31# all of the libxcurses source files are in src/libc
32OBJECTS= \
33$(XCURSES)	$(GEN)		$(I18N)		$(MKS) \
34$(STDIO)	$(WIDE)
35
36# XCURSES source files are in src/libc/xcurses
37XCURSES= \
38add_wch.o	dupwin.o	longname.o	strname.o	wbrdr.o \
39addch.o		echo_wch.o	m_cc.o		termattr.o	wbrdr_st.o \
40addchn.o	echochar.o	meta.o		tgetent.o	wchgat.o \
41addnstr.o	endwin.o	move.o		tgetflag.o	wclear.o \
42addnws.o	flushinp.o	mvcur.o		tgetnum.o	wclrbot.o \
43addwchn.o	get_wch.o	mvwin.o		tgetstr.o	wclreol.o \
44attr_on.o	getcchar.o	napms.o		tgoto.o		wdelch.o \
45attron.o	getch.o		newpad.o	tigetfla.o	wget_wch.o \
46baudrate.o	getn_ws.o	newterm.o	tigetnum.o	wgetch.o \
47beep.o		getnstr.o	newwin.o	tigetstr.o	wgetn_ws.o \
48bkgd.o		getwin.o	noecho.o	timeout.o	whln.o \
49bkgdset.o	has.o		nonl.o		touched.o	whln_st.o \
50bkgrnd.o	hln.o		numcode.o	touchwin.o	win_wch.o \
51bkgrndst.o	hln_st.o	numfnam.o	tparm.o		win_wchn.o \
52boolcode.o	in_wch.o	numname.o	tputs.o		winch.o \
53boolfnam.o	in_wchn.o	overlay.o	trace.o		winchn.o \
54boolname.o	inch.o		pecho_wc.o	unctrl.o	winnstr.o \
55box.o		inchn.o		pechoch.o	vid_attr.o	winnwstr.o \
56box_set.o	initscr.o	prefresh.o	vid_puts.o	wins_nws.o \
57brdr.o		innstr.o	printw.o	vidattr.o	wins_wch.o \
58brdr_st.o	innwstr.o	ptrmove.o	vw_print.o	winsch.o \
59cbreak.o	ins_nws.o	qiflush.o	vw_scanw.o	winsdel.o \
60chgat.o		ins_wch.o	redraw.o	vwprintw.o	winsnstr.o \
61clear.o		insch.o		refresh.o	vwscanw.o	wmove.o \
62clearok.o	insnstr.o	savetty.o	wacs.o		wredraw.o \
63clrbot.o	intrflsh.o	scanw.o		wadd_wch.o	wrefresh.o \
64clreol.o			scr_dump.o	waddch.o	wscrl.o \
65color.o		isendwin.o	scrl.o		waddchn.o	wscrreg.o \
66copywin.o	key_name.o	scrreg.o	waddnstr.o	wsyncdn.o \
67curs_set.o	keyindex.o	setcchar.o	waddnws.o	wsyncup.o \
68delay.o		keyname.o	setup.o		waddwchn.o	wtimeout.o \
69delch.o		keypad.o	slk.o		wattr_on.o	wtouchln.o \
70deleteln.o	killchar.o	strcode.o	wattron.o	wunctrl.o \
71doupdate.o	killwch.o	strfnam.o	wbkgrnd.o
72
73# GEN source files are in src/libc/gen
74GEN= \
75base.o		eprintf.o
76
77# I18N source files are in src/libc/i18n
78I18N= \
79m_strmsg.o	m_text.o
80
81# MKS source files are in src/libc/mks
82MKS= \
83m_cmdnam.o	m_errorx.o	m_ord.o		m_strdup.o \
84m_crcpos.o	m_getenv.o	m_pathca.o	m_vsscan.o \
85m_error.o	m_malloc.o	m_pathma.o
86
87# STDIO source files are in src/libc/stdio
88STDIO= \
89vfscanf.o
90
91# WIDE source files are in src/libc/wide
92WIDE= \
93m_mbstow.o	m_wcsdup.o	wio_get.o	wio_put.o
94
95# include library definitions
96include ../../Makefile.lib
97
98SRCDIR =	../src
99
100SRCS=		$(XCURSES:%.o=../src/libc/xcurses/%.c) \
101		$(GEN:%.o=../src/libc/gen/%.c) \
102		$(I18N:%.o=../src/libc/i18n/%.c) \
103		$(MKS:%.o=../src/libc/mks/%.c) \
104		$(STDIO:%.o=../src/libc/stdio/%.c) \
105		$(WIDE:%.o=../src/libc/wide/%.c)
106
107LIBS =		$(DYNLIB)
108
109# definitions for install target
110ROOTLIBDIR=	$(ROOT)/usr/xpg4/lib
111ROOTLIBDIR64=	$(ROOT)/usr/xpg4/lib/$(MACH64)
112ROOTLIBS=	$(LIBS:%=$(ROOTLIBDIR)/%)
113
114
115CERRWARN +=	$(CNOWARN_UNINIT)
116CERRWARN +=	-_gcc=-Wno-unused-variable
117CERRWARN +=	-_gcc=-Wno-unused-label
118CERRWARN +=	-_gcc=-Wno-unused-function
119
120# not linted
121SMATCH=off
122
123LDLIBS += -lc
124
125CPPFLAGS = -I../h -I../h/solaris2 -I../src/libc/xcurses $(CPPFLAGS.master)
126
127#
128# If and when somebody gets around to messaging this, CLOBBERFILE should not
129# be cleared (so that any .po file will be clobbered.
130#
131CLOBBERFILES=	libcurses.so libcurses.so$(VERS)
132
133.KEEP_STATE:
134
135all: $(LIBS)
136
137
138#
139# Include library targets
140#
141include ../../Makefile.targ
142
143objs/%.o pics/%.o:	../src/libc/xcurses/%.c
144	$(COMPILE.c) -o $@ $<
145	$(POST_PROCESS_O)
146
147objs/%.o pics/%.o:	../src/libc/gen/%.c
148	$(COMPILE.c) -o $@ $<
149	$(POST_PROCESS_O)
150
151objs/%.o pics/%.o:	../src/libc/i18n/%.c
152	$(COMPILE.c) -o $@ $<
153	$(POST_PROCESS_O)
154
155objs/%.o pics/%.o:	../src/libc/mks/%.c
156	$(COMPILE.c) -o $@ $<
157	$(POST_PROCESS_O)
158
159objs/%.o pics/%.o:	../src/libc/narrow/%.c
160	$(COMPILE.c) -o $@ $<
161	$(POST_PROCESS_O)
162
163objs/%.o pics/%.o:	../src/libc/stdio/%.c
164	$(COMPILE.c) -o $@ $<
165	$(POST_PROCESS_O)
166
167objs/%.o pics/%.o:	../src/libc/wide/%.c
168	$(COMPILE.c) -o $@ $<
169	$(POST_PROCESS_O)
170