2001-06-20 03:09:38 -05:00
|
|
|
#*************************************************************************
|
|
|
|
#
|
2005-09-08 03:38:11 -05:00
|
|
|
# OpenOffice.org - a multi-platform office productivity suite
|
2001-06-20 03:09:38 -05:00
|
|
|
#
|
2005-09-08 03:38:11 -05:00
|
|
|
# $RCSfile: pstrules.mk,v $
|
2001-06-20 03:09:38 -05:00
|
|
|
#
|
2007-07-17 01:24:12 -05:00
|
|
|
# $Revision: 1.48 $
|
2001-06-20 03:09:38 -05:00
|
|
|
#
|
2007-07-17 01:24:12 -05:00
|
|
|
# last change: $Author: obo $ $Date: 2007-07-17 07:24:12 $
|
2001-06-20 03:09:38 -05:00
|
|
|
#
|
2005-09-08 03:38:11 -05:00
|
|
|
# The Contents of this file are made available subject to
|
|
|
|
# the terms of GNU Lesser General Public License Version 2.1.
|
2001-06-20 03:09:38 -05:00
|
|
|
#
|
|
|
|
#
|
2005-09-08 03:38:11 -05:00
|
|
|
# GNU Lesser General Public License Version 2.1
|
|
|
|
# =============================================
|
|
|
|
# Copyright 2005 by Sun Microsystems, Inc.
|
|
|
|
# 901 San Antonio Road, Palo Alto, CA 94303, USA
|
2001-06-20 03:09:38 -05:00
|
|
|
#
|
2005-09-08 03:38:11 -05:00
|
|
|
# This library is free software; you can redistribute it and/or
|
|
|
|
# modify it under the terms of the GNU Lesser General Public
|
|
|
|
# License version 2.1, as published by the Free Software Foundation.
|
2001-06-20 03:09:38 -05:00
|
|
|
#
|
2005-09-08 03:38:11 -05:00
|
|
|
# This library is distributed in the hope that it will be useful,
|
|
|
|
# but WITHOUT ANY WARRANTY; without even the implied warranty of
|
|
|
|
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
|
|
|
|
# Lesser General Public License for more details.
|
2001-06-20 03:09:38 -05:00
|
|
|
#
|
2005-09-08 03:38:11 -05:00
|
|
|
# You should have received a copy of the GNU Lesser General Public
|
|
|
|
# License along with this library; if not, write to the Free Software
|
|
|
|
# Foundation, Inc., 59 Temple Place, Suite 330, Boston,
|
|
|
|
# MA 02111-1307 USA
|
2001-06-20 03:09:38 -05:00
|
|
|
#
|
|
|
|
#*************************************************************************
|
2000-09-20 08:43:26 -05:00
|
|
|
|
|
|
|
#++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
|
|
|
|
#+++++++++++ second_build rules +++++++++++++++++++++++++++++++++++++
|
|
|
|
#++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
|
|
|
|
|
|
|
|
.IF "$(SECOND_BUILD)"!=""
|
2001-02-02 05:01:50 -06:00
|
|
|
.IF "$($(SECOND_BUILD)_OBJFILES)"!=""
|
2000-09-20 08:43:26 -05:00
|
|
|
|
|
|
|
$(OBJ)$/$(SECOND_BUILD)_%.obj : %.cxx
|
|
|
|
@echo ------------------------------
|
|
|
|
@echo Making: $@
|
|
|
|
.IF "$(GUI)"=="UNX"
|
|
|
|
@$(RM) $@ $(@:s/.obj/.o/)
|
2006-12-13 08:05:52 -06:00
|
|
|
$(CXX) $(CFLAGS) $(INCLUDE) $(CFLAGSCXX) $(CFLAGSCXXOBJ) $(CFLAGSOBJ) $(CDEFS) $($(SECOND_BUILD)CDEFS) $(CDEFSOBJ) $(!eq,$(EXCEPTIONSFILES),$(subst,$@, $(EXCEPTIONSFILES)) $(LOCAL_EXCEPTIONS_FLAGS) $(GLOBAL_EXCEPTIONS_FLAGS)) $(CFLAGSAPPEND) $(CFLAGSOUTOBJ) $(OBJ)$/$(SECOND_BUILD)_$*.o $(CFLAGSINCXX)$(PWD)$/$*.cxx
|
2004-08-23 03:17:24 -05:00
|
|
|
.IF "$(OS)"=="SOLARIS" && "$(product)"=="full" && "$(debug)"==""
|
|
|
|
$(ADJUSTVISIBILITY) -p $(@:s/.obj/.o/)
|
|
|
|
.ENDIF # "$(OS)"=="SOLARIS" && "$(product)"=="full" && "$(debug)"==""
|
2007-01-25 05:52:21 -06:00
|
|
|
$(IFEXIST) $(@:s/.obj/.o/) $(THEN) $(TOUCH) $@ $(FI)
|
2003-03-27 04:48:49 -06:00
|
|
|
.ELSE
|
2007-01-26 03:59:05 -06:00
|
|
|
@$(IFEXIST) $@ $(THEN) $(RM:s/+//) $@ >& $(NULLDEV) $(FI)
|
2006-12-13 08:05:52 -06:00
|
|
|
$(CXX) $(CFLAGS) $(INCLUDE) $(CFLAGSCXX) $(CFLAGSOBJ) $(CDEFS) $($(SECOND_BUILD)CDEFS) $(CDEFSOBJ) $(!eq,$(EXCEPTIONSFILES),$(subst,$@, $(EXCEPTIONSFILES)) $(LOCAL_EXCEPTIONS_FLAGS) $(GLOBAL_EXCEPTIONS_FLAGS)) $(CFLAGSAPPEND) $(CFLAGSOUTOBJ)$(OBJ)$/$(SECOND_BUILD)_$*.obj $(CFLAGSINCXX)$(PWD)$/$*.cxx
|
2000-09-20 08:43:26 -05:00
|
|
|
.ENDIF
|
|
|
|
|
|
|
|
$(OBJ)$/$(SECOND_BUILD)_%.obj : %.c
|
|
|
|
@echo ------------------------------
|
|
|
|
@echo Making: $@
|
|
|
|
.IF "$(GUI)"=="UNX"
|
|
|
|
.IF "$(TEST)"!=""
|
2006-07-05 15:56:33 -05:00
|
|
|
$(CC) $(CFLAGS) $(INCLUDE_C) $(CFLAGSCC) $(CFLAGSOBJ) $(CDEFS) $($(SECOND_BUILD)CDEFS) $(CDEFSOBJ) -E $(CFLAGSAPPEND) $(CFLAGSOUTOBJ) $(OBJ)$/$(SECOND_BUILD)_$*.o $*.c
|
2000-09-20 08:43:26 -05:00
|
|
|
.ELSE
|
|
|
|
@$(RM) $@ $(@:s/.obj/.o/)
|
2006-07-05 15:56:33 -05:00
|
|
|
$(CC) $(CFLAGS) $(INCLUDE_C) $(CFLAGSCC) $(CFLAGSOBJ) $(CDEFS) $($(SECOND_BUILD)CDEFS) $(CDEFSOBJ) $(CFLAGSAPPEND) $(CFLAGSOUTOBJ) $(OBJ)$/$(SECOND_BUILD)_$*.o $*.c
|
2004-08-23 03:17:24 -05:00
|
|
|
.IF "$(OS)"=="SOLARIS" && "$(product)"=="full" && "$(debug)"==""
|
|
|
|
$(ADJUSTVISIBILITY) -p $(@:s/.obj/.o/)
|
|
|
|
.ENDIF # "$(OS)"=="SOLARIS" && "$(product)"=="full" && "$(debug)"==""
|
2007-01-25 05:52:21 -06:00
|
|
|
$(IFEXIST) $(@:s/.obj/.o/) $(THEN) $(TOUCH) $@ $(FI)
|
2000-09-20 08:43:26 -05:00
|
|
|
.ENDIF
|
|
|
|
.ELSE
|
2007-01-25 05:52:21 -06:00
|
|
|
@$(TYPE) $(mktmp $(CC) $(CFLAGS) $(INCLUDE_C) $(CFLAGSCC) $(CFLAGSOBJ) $(CDEFS) $($(SECOND_BUILD)CDEFS) $(CDEFSOBJ) $(CFLAGSAPPEND) $(CFLAGSOUTOBJ)$(OBJ)\$(SECOND_BUILD)_$*.obj $*.c )
|
2006-10-05 04:37:43 -05:00
|
|
|
@echo.
|
2000-09-20 08:43:26 -05:00
|
|
|
.IF "$(COM)"=="GCC"
|
2006-07-05 15:56:33 -05:00
|
|
|
$(CC) $(CFLAGS) $(INCLUDE_C) $(CFLAGSCC) $(CFLAGSOBJ) $(CDEFS) $($(SECOND_BUILD)CDEFS) $(CDEFSOBJ) $(CFLAGSAPPEND) $(CFLAGSOUTOBJ)$(OBJ)\$(SECOND_BUILD)_$*.obj $*.c
|
2000-09-20 08:43:26 -05:00
|
|
|
.ELSE
|
2006-07-05 15:56:33 -05:00
|
|
|
$(CC) @$(mktmp $(CFLAGS) $(INCLUDE_C) $(CFLAGSCC) $(CFLAGSOBJ) $(CDEFS) $($(SECOND_BUILD)CDEFS) $(CDEFSOBJ) $(CFLAGSAPPEND) $(CFLAGSOUTOBJ)$(OBJ)\$(SECOND_BUILD)_$*.obj $*.c )
|
2000-09-20 08:43:26 -05:00
|
|
|
.ENDIF
|
|
|
|
$(SEMADEBUG)
|
|
|
|
.ENDIF
|
|
|
|
|
2001-02-02 05:01:50 -06:00
|
|
|
.ENDIF # "$($(SECOND_BUILD)_OBJFILES)"!=""
|
2000-09-20 08:43:26 -05:00
|
|
|
|
2001-02-02 05:01:50 -06:00
|
|
|
.IF "$($(SECOND_BUILD)_SLOFILES)"!=""
|
2000-09-20 08:43:26 -05:00
|
|
|
|
|
|
|
$(SLO)$/$(SECOND_BUILD)_%.obj : %.cxx
|
|
|
|
@echo ------------------------------
|
|
|
|
@echo Making: $@
|
|
|
|
.IF "$(GUI)"=="UNX"
|
|
|
|
@$(RM) $@ $(@:s/.obj/.o/)
|
2006-12-13 08:05:52 -06:00
|
|
|
$(CXX) $(CFLAGS) $(INCLUDE) $(CFLAGSCXX) $(CFLAGSCXXSLO) $(CFLAGSSLO) $(CDEFS) $($(SECOND_BUILD)CDEFS) $(CDEFSSLO) $(CDEFSMT) $(!eq,$(EXCEPTIONSFILES),$(subst,$@, $(EXCEPTIONSFILES)) $(LOCAL_EXCEPTIONS_FLAGS) $(GLOBAL_EXCEPTIONS_FLAGS)) $(CFLAGSAPPEND) $(CFLAGSOUTOBJ) $(SLO)$/$(SECOND_BUILD)_$*.o $(CFLAGSINCXX)$(PWD)$/$*.cxx
|
2004-08-23 03:17:24 -05:00
|
|
|
.IF "$(OS)"=="SOLARIS" && "$(product)"=="full" && "$(debug)"==""
|
|
|
|
$(ADJUSTVISIBILITY) -p $(@:s/.obj/.o/)
|
|
|
|
.ENDIF # "$(OS)"=="SOLARIS" && "$(product)"=="full" && "$(debug)"==""
|
2007-01-25 05:52:21 -06:00
|
|
|
$(IFEXIST) $(@:s/.obj/.o/) $(THEN) $(TOUCH) $@ $(FI)
|
2003-03-27 04:48:49 -06:00
|
|
|
.ELSE
|
2007-01-25 05:52:21 -06:00
|
|
|
@-$(RM) $@
|
2007-07-17 01:24:12 -05:00
|
|
|
.IF "$(COM)"=="GCC"
|
|
|
|
$(CXX) $(CFLAGS) $(INCLUDE) $(CFLAGSCXX) $(CFLAGSSLO) $(CDEFS) $($(SECOND_BUILD)CDEFS) $(CDEFSSLO) $(CDEFSMT) $(!eq,$(EXCEPTIONSFILES),$(subst,$@, $(EXCEPTIONSFILES)) $(LOCAL_EXCEPTIONS_FLAGS) $(GLOBAL_EXCEPTIONS_FLAGS)) $(CFLAGSAPPEND) $(CFLAGSOUTOBJ)$(SLO)$/$(SECOND_BUILD)_$*.obj $(CFLAGSINCXX)$(PWD)$/$*.cxx
|
|
|
|
.ELSE
|
2007-05-10 09:10:37 -05:00
|
|
|
$(CXX) @$(mktmp $(CFLAGS) $(INCLUDE) $(CFLAGSCXX) $(CFLAGSSLO) $(CDEFS) $($(SECOND_BUILD)CDEFS) $(CDEFSSLO) $(CDEFSMT) $(!eq,$(EXCEPTIONSFILES),$(subst,$@, $(EXCEPTIONSFILES)) $(LOCAL_EXCEPTIONS_FLAGS) $(GLOBAL_EXCEPTIONS_FLAGS)) $(CFLAGSAPPEND) $(CFLAGSOUTOBJ)$(SLO)$/$(SECOND_BUILD)_$*.obj $(CFLAGSINCXX)$(PWD)$/$*.cxx )
|
2000-09-20 08:43:26 -05:00
|
|
|
.ENDIF
|
2007-07-17 01:24:12 -05:00
|
|
|
.ENDIF
|
2000-09-20 08:43:26 -05:00
|
|
|
|
|
|
|
$(SLO)$/$(SECOND_BUILD)_%.obj : %.c
|
|
|
|
@echo ------------------------------
|
|
|
|
@echo Making: $@
|
|
|
|
.IF "$(GUI)"=="UNX"
|
|
|
|
@$(RM) $@ $(@:s/.obj/.o/)
|
2006-07-05 15:56:33 -05:00
|
|
|
$(CC) $(CFLAGS) $(INCLUDE_C) $(CFLAGSCC) $(CFLAGSSLO) $(CDEFS) $($(SECOND_BUILD)CDEFS) $(CDEFSSLO) $(CDEFSMT) $(CFLAGSAPPEND) $(CFLAGSOUTOBJ) $(SLO)$/$(SECOND_BUILD)_$*.o $*.c
|
2004-08-23 03:17:24 -05:00
|
|
|
.IF "$(OS)"=="SOLARIS" && "$(product)"=="full" && "$(debug)"==""
|
|
|
|
$(ADJUSTVISIBILITY) -p $(@:s/.obj/.o/)
|
|
|
|
.ENDIF # "$(OS)"=="SOLARIS" && "$(product)"=="full" && "$(debug)"==""
|
2007-01-25 05:52:21 -06:00
|
|
|
$(IFEXIST) $(@:s/.obj/.o/) $(THEN) $(TOUCH) $@ $(FI)
|
2003-03-27 04:48:49 -06:00
|
|
|
.ELSE
|
2007-01-25 05:52:21 -06:00
|
|
|
@-$(RM) $@
|
2000-09-20 08:43:26 -05:00
|
|
|
.IF "$(COM)"=="GCC"
|
2006-07-05 15:56:33 -05:00
|
|
|
$(CC) $(CFLAGS) $(INCLUDE_C) $(CFLAGSCC) $(CFLAGSSLO) $(CDEFS) $($(SECOND_BUILD)CDEFS) $(CDEFSSLO) $(CDEFSMT) $(CFLAGSAPPEND) $(CFLAGSOUTOBJ)$(SLO)$/$(SECOND_BUILD)_$*.obj $*.c
|
2000-09-20 08:43:26 -05:00
|
|
|
.ELSE
|
2007-01-25 05:52:21 -06:00
|
|
|
$(TYPE) $(mktmp $(CFLAGS) $(INCLUDE_C) $(CFLAGSCC) $(CFLAGSSLO) $(CDEFS) $($(SECOND_BUILD)CDEFS) $(CDEFSSLO) $(CDEFSMT) $(CFLAGSAPPEND) $(CFLAGSOUTOBJ)$(SLO)$/$(SECOND_BUILD)_$*.obj $*.c )
|
2006-07-05 15:56:33 -05:00
|
|
|
$(CC) @$(mktmp $(CFLAGS) $(INCLUDE_C) $(CFLAGSCC) $(CFLAGSSLO) $(CDEFS) $($(SECOND_BUILD)CDEFS) $(CDEFSSLO) $(CDEFSMT) $(CFLAGSAPPEND) $(CFLAGSOUTOBJ)$(SLO)$/$(SECOND_BUILD)_$*.obj $*.c )
|
2000-09-20 08:43:26 -05:00
|
|
|
.ENDIF
|
2003-03-27 04:48:49 -06:00
|
|
|
.ENDIF
|
2000-09-20 08:43:26 -05:00
|
|
|
|
2001-02-02 05:01:50 -06:00
|
|
|
.ENDIF # "$($(SECOND_BUILD)_SLOFILES)"!=""
|
2000-09-20 08:43:26 -05:00
|
|
|
.ENDIF # "$(SECOND_BUILD)"!=""
|
|
|
|
|
|
|
|
#+++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
|
|
|
|
#+++++++++++ srcipting rules ++++++++++++++++++++++++++++++++++++++++
|
|
|
|
#+++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
|
|
|
|
|
|
|
|
.IF "$(PARFILES)"!=""
|
2004-06-25 10:11:58 -05:00
|
|
|
ULFPARFILES=$(foreach,i,$(ULFFILES) $(foreach,j,$(SCP_PRODUCT_TYPE) $(PAR)$/$j$/$(i:b).par))
|
|
|
|
MOREPARFILES=$(foreach,i,$(PARFILES) $(foreach,j,$(SCP_PRODUCT_TYPE) $(PAR)$/$j$/$i ))
|
|
|
|
ALLPARFILES=$(uniq $(ULFPARFILES) $(MOREPARFILES))
|
2000-09-20 08:43:26 -05:00
|
|
|
|
|
|
|
SCP_PRODUCT_TYPE*=FAT
|
|
|
|
|
2004-10-18 07:55:39 -05:00
|
|
|
.IF "$(GUI)" == "WNT"
|
|
|
|
LANGFILEEXT=mlf
|
|
|
|
.ELSE
|
|
|
|
LANGFILEEXT=jlf
|
|
|
|
.ENDIF
|
|
|
|
|
2004-06-25 10:11:58 -05:00
|
|
|
$(PAR)$/%.par :
|
2000-09-20 08:43:26 -05:00
|
|
|
@echo ------------------------------
|
|
|
|
@echo Making: $@
|
2007-02-06 06:56:39 -06:00
|
|
|
@@-$(MKDIR) $(MISC)$/{$(subst,$(@:d:d:d), $(@:d:d))}
|
2000-09-20 08:43:26 -05:00
|
|
|
.IF "$(GUI)"=="WNT"
|
2006-03-08 06:59:37 -06:00
|
|
|
$(CPPLCC) -+ -P $(INCLUDE) $(CDEFS) $(SCPDEFS) -DDLLPOSTFIX=$(DLLPOSTFIX) $(*:b).scp > $(MISC)$/{$(subst,$(@:d:d:d), $(@:d:d))}$/$(*:b).pre
|
2000-09-20 08:43:26 -05:00
|
|
|
.ENDIF
|
|
|
|
.IF "$(GUI)"=="UNX"
|
2006-03-08 06:59:37 -06:00
|
|
|
cpp.lcc -+ -P $(CDEFS) $(SCPDEFS) -DDLLPOSTFIX=$(DLLPOSTFIX) -I. -I$(INC) -I$(INCLOCAL) -I$(INCGUI) -I$(INCCOM) $(SOLARINC) $(*:b).scp > $(MISC)$/{$(subst,$(@:d:d:d), $(@:d:d))}$/$(*:b).pre
|
2000-09-20 08:43:26 -05:00
|
|
|
.ENDIF
|
2004-06-25 10:11:58 -05:00
|
|
|
.IF "$(common_build_srs)"!=""
|
2007-01-25 05:52:21 -06:00
|
|
|
$(SCPCOMP) -l {$(subst,$(OUTPATH),$(COMMON_OUTDIR) $(MISC))$/$(TARGET)$/$(@:b).$(LANGFILEEXT)} -s $(MISC)$/{$(subst,$(@:d:d:d), $(@:d:d))}$/$(*:b).pre -o $@
|
2004-06-25 10:11:58 -05:00
|
|
|
.ELSE # "$(common_build_srs)"!=""
|
2007-01-25 05:52:21 -06:00
|
|
|
$(SCPCOMP) -l {$(MISC)$/$(TARGET)$/$(@:b).$(LANGFILEEXT)} -s $(MISC)$/{$(subst,$(@:d:d:d), $(@:d:d))}$/$(*:b).pre -o $@
|
2004-06-25 10:11:58 -05:00
|
|
|
.ENDIF # "$(common_build_srs)"!=""
|
|
|
|
# hacked version
|
2007-01-25 05:52:21 -06:00
|
|
|
# $(SCPCOMP) -l $(@:b).$(LANGFILEEXT) -s $(MISC)$/{$(subst,$(@:d:d:d), $(@:d:d))}$/$(*:b).pre -o $@
|
2000-09-20 08:43:26 -05:00
|
|
|
|
|
|
|
.ENDIF # "$(PARFILES)"!=""
|
|
|
|
|
2002-02-13 09:58:18 -06:00
|
|
|
.IF "$(TESTDIR)"!=""
|
|
|
|
|
|
|
|
# workaround for strange dmake bug:
|
|
|
|
# if the previous block was a rule or a target, "\#" isn't recognized
|
|
|
|
# as an escaped "#". if it was an assignment, escaping works...
|
|
|
|
some_unique_variable_name:=1
|
|
|
|
|
|
|
|
.IF "$(OS)" == "WNT"
|
|
|
|
REGEXP:="s/^[\#].*$$//"
|
|
|
|
.ELSE
|
|
|
|
REGEXP:='s/^[\#].*$$//'
|
|
|
|
.ENDIF
|
|
|
|
|
|
|
|
$(MISC)$/%.exp : sce$/%.sce
|
2007-02-06 06:56:39 -06:00
|
|
|
@@-$(RM) $@
|
|
|
|
@@-$(RM) $(@:d)$(@:b).tst
|
2007-01-25 05:52:21 -06:00
|
|
|
$(TYPE) $< | sed $(REGEXP) | sed "s/^/test_/" > $(@:d)$(@:b).tst
|
|
|
|
$(TYPE) $(@:d)$(@:b).tst | sed "/test_./ w $@"
|
2002-02-13 09:58:18 -06:00
|
|
|
|
|
|
|
.ENDIF # "$(TESTDIR)"!=""
|