Print this page
7612 SGSPROTO lacks structure
Reviewed by: Robert Mustacchi <rm@joyent.com>
Reviewed by: Richard Lowe <richlowe@richlowe.net>

@@ -18,10 +18,11 @@
 #
 # CDDL HEADER END
 #
 #
 # Copyright (c) 1994, 2010, Oracle and/or its affiliates. All rights reserved.
+# Copyright 2016 RackTop Systems.
 #
 
 objs/%.o \
 pics/%.o:       %.c
                 $(COMPILE.c) -o $@ $<

@@ -129,18 +130,19 @@
 
 
 # Special target for native builds (ie. when we need to build a version of ld
 # to build a version of ld :-).
 
-native:         $(SGSPROTO)/$(DYNLIB)
+native:         $(SGSLIBDIR)/$(LIBLINKS)
 
-$(SGSPROTO)/$(DYNLIB): \
-                pics .WAIT $$(PICS)
+$(SGSLIBDIR)/$(DYNLIB): pics .WAIT $$(PICS)
                 $(BUILD.SO)
                 $(POST_PROCESS_SO)
-                -@$(RM) $(SGSPROTO)/$(LIBLINKS)
-                $(SYMLINK) $(DYNLIB) $(SGSPROTO)/$(LIBLINKS)
+
+$(SGSLIBDIR)/$(LIBLINKS): $(SGSLIBDIR)/$(DYNLIB)
+                -@$(RM) $(SGSLIBDIR)/$(LIBLINKS)
+                $(SYMLINK) $(DYNLIB) $(SGSLIBDIR)/$(LIBLINKS)
 
 
 # Derived source and header files (messaging).  Make sure that the sgsmsg
 # command is constructed - libelf might not be built with the whole sgs.