1c9f77c52SAndy Stormont# 2c9f77c52SAndy Stormont# This file and its contents are supplied under the terms of the 3c9f77c52SAndy Stormont# Common Development and Distribution License ("CDDL"), version 1.0. 4c9f77c52SAndy Stormont# You may only use this file in accordance with the terms of version 5c9f77c52SAndy Stormont# 1.0 of the CDDL. 6c9f77c52SAndy Stormont# 7c9f77c52SAndy Stormont# A full copy of the text of the CDDL should have accompanied this 8c9f77c52SAndy Stormont# source. A copy of the CDDL is also available via the Internet at 9c9f77c52SAndy Stormont# http://www.illumos.org/license/CDDL. 10c9f77c52SAndy Stormont# 11c9f77c52SAndy Stormont# 121f2ca518SDan McDonald# Copyright 2015, OmniTI Computer Consulting, Inc. All rights reserved. 130ae9a84fSAndrew Stormont# Copyright (c) 2016 Racktop Systems. 145661bb76SJohn Levon# Copyright (c) 2018, Joyent, Inc. 15c9f77c52SAndy Stormont 160ae9a84fSAndrew Stormont# Link against libc as per solaris specs 17*a5619348SRichard LowePICS = $(MODULE).o 18*a5619348SRichard LoweLDLIBS += -lc 19c9f77c52SAndy Stormont# Allow for undefined symbols satisfied by perl 20*a5619348SRichard LoweZDEFS = 21c9f77c52SAndy Stormont 22c7893124SRichard Lowe$(ROOTPERLEXT) := FILEMODE = 0555 23c7893124SRichard Lowe$(ROOTPERLMOD) := FILEMODE = 0444 2474515eeeSDan McDonald 255661bb76SJohn LevonSMATCH=off 265661bb76SJohn Levon 27*a5619348SRichard Lowe.KEEP_STATE: 28c9f77c52SAndy Stormont 29*a5619348SRichard Lowe$(PERLEXT): $(MODULE).o 309894d69cSRobert Mustacchi $(BUILD.SO) 31c9f77c52SAndy Stormont 32*a5619348SRichard Lowe$(MODULE).o: $(MODULE).c 3374515eeeSDan McDonald $(COMPILE.c) $(PCFLAGS) $(C_PICFLAGS) -I$(PERLINCDIR) $< -o $@ 34c9f77c52SAndy Stormont 35*a5619348SRichard Lowe$(MODULE).c: $(PERLXS) 36*a5619348SRichard Lowe $(XSUBPP) $(XSUBPPFLAGS) $(PERLXS) -output $@ 37c9f77c52SAndy Stormont 38*a5619348SRichard Lowe$(ROOTPERLMODDIR): 39c9f77c52SAndy Stormont $(INS.dir) 40c9f77c52SAndy Stormont 41*a5619348SRichard Lowe$(ROOTPERLMOD): $(PERLMOD) $(ROOTPERLMODDIR) 42*a5619348SRichard Lowe $(RM) $@; $(INS) -s -m $(FILEMODE) -f $(@D) $(PERLMOD) 43c9f77c52SAndy Stormont 44*a5619348SRichard Lowe$(ROOTPERLEXTDIR): 45c9f77c52SAndy Stormont $(INS.dir) 46c9f77c52SAndy Stormont 47*a5619348SRichard Lowe$(ROOTPERLEXT): $(PERLEXT) $(ROOTPERLEXTDIR) 48*a5619348SRichard Lowe $(RM) $@; $(INS) -s -m $(FILEMODE) -f $(@D) $(PERLEXT) 490ae9a84fSAndrew Stormont 50*a5619348SRichard Loweclean: 51*a5619348SRichard Lowe $(RM) $(CLEANFILES) 52*a5619348SRichard Lowe 53*a5619348SRichard Loweclobber: clean 54