Added new install rules for makefiles and updated makedefs and makerules... more to come
This commit is contained in:
parent
34c05db393
commit
114c18532a
58
Make/instrules.new
Normal file
58
Make/instrules.new
Normal file
@ -0,0 +1,58 @@
|
||||
install : instbin instdev
|
||||
|
||||
instbin :
|
||||
@$(MAKE) INSTSRC=$(TOPDIR)/bin INSTDEST=$(INST_DEMOS) \
|
||||
INSTARGS="$(INSTARGS) -m 755" __install
|
||||
@$(MAKE) INSTSRC=$(TOPDIR)/lib INSTDEST=$(INST_LIBS) \
|
||||
INSTARGS="$(INSTARGS) -m 755" __install
|
||||
@$(MAKE) INSTSRC=$(TOPDIR)/lib/osgPlugins INSTDEST=$(INST_PLUGINS)\
|
||||
INSTARGS="$(INSTARGS) -m 755" __install
|
||||
|
||||
|
||||
instdev :
|
||||
@for d in `ls -1 $(TOPDIR)/include/ | grep -v CVS`; \
|
||||
do\
|
||||
if [ -d $(TOPDIR)/include/$$d ]; \
|
||||
then \
|
||||
$(MAKE) INSTSRC=$(TOPDIR)/include/$$d INSTDEST=$(INST_INCLUDE)/$$d\
|
||||
INSTARGS="$(INSTARGS) -m 644" __install;\
|
||||
fi\
|
||||
done
|
||||
@for d in `ls -1 $(TOPDIR)/src/Demos | grep -v CVS`; \
|
||||
do\
|
||||
if [ -d $(TOPDIR)/src/Demos/$$d ]; \
|
||||
then \
|
||||
$(MAKE) INSTSRC=$(TOPDIR)/src/Demos/$$d INSTDEST=$(INST_DEMO_SRC)/$$d\
|
||||
INSTARGS="$(INSTARGS) -m 644" __install;\
|
||||
fi\
|
||||
done
|
||||
|
||||
instlinks : instlinksbin instlinksdev
|
||||
|
||||
instlinksbin :
|
||||
@$(MAKE) INSTARGS=" -t " instbin
|
||||
|
||||
instlinksdev :
|
||||
@$(MAKE) INSTARGS=" -t " instdev
|
||||
|
||||
|
||||
__install :
|
||||
@[ -n "$(INSTSRC)" ] || echo "Internal error (INSTSRC definition)"
|
||||
@[ -n "$(INSTSRC)" ] && echo > /dev/null
|
||||
@[ -n "$(INSTDEST)" ] || echo "Internal error (INSTDEST definition)"
|
||||
@[ -n "$(INSTDEST)" ] && echo > /dev/null
|
||||
@[ -d $(INSTDEST) ] || mkdir -p $(INSTDEST)
|
||||
@cd $(INSTSRC);\
|
||||
if [ -n "`ls -1 | grep -v CVS`" ]; then\
|
||||
for f in `ls -1 | grep -v CVS`; \
|
||||
do\
|
||||
if [ -f $$f ] ; \
|
||||
then \
|
||||
echo install $(INSTARGS) $$f $(INSTDEST);\
|
||||
install $(INSTARGS) $$f $(INSTDEST);\
|
||||
fi\
|
||||
done\
|
||||
fi
|
||||
|
||||
|
||||
|
@ -22,6 +22,16 @@ BININST = bin
|
||||
LIBINST = lib
|
||||
PLUGININST = lib/osgPlugins
|
||||
|
||||
INST_DEMOS = /usr/share/OpenSceneGraph/bin
|
||||
INST_LIBS = /usr/share/OpenSceneGraph/lib
|
||||
INST_PLUGINS = /usr/share/OpenSceneGraph/lib/osgPlugins
|
||||
INST_INCLUDE = /usr/share/OpenSceneGraph/include
|
||||
INST_DEMO_SRC = /usr/share/OpenSceneGraph/src/demos
|
||||
INST_DATA = /usr/share/OpenSceneGraph/data
|
||||
|
||||
LINK = ln -sf
|
||||
|
||||
|
||||
ALL_TARGETS = \
|
||||
opt\
|
||||
debug\
|
||||
@ -46,8 +56,6 @@ ifeq ($(OS),SunOS)
|
||||
ARCHARGS =
|
||||
LINKARGS =
|
||||
DYNAMICLIBRARYLIB = -ldl
|
||||
OSGUTIL = -losgUtil
|
||||
OSGDB = -losgDB
|
||||
OSG_LIBS = -losgGLUT -losgDB -losgUtil -losg
|
||||
FREETYPE_LIB = -lfreetype
|
||||
GLUT_LIB = -lglut
|
||||
@ -75,15 +83,13 @@ ifeq ($(OS),IRIX)
|
||||
ARCHARGS =
|
||||
LINKARGS = -LANG:std -OPT:Olimit=0
|
||||
DYNAMICLIBRARYLIB = -ldl
|
||||
OSGUTIL = -losgUtil
|
||||
OSGDB = -losgDB
|
||||
OSG_LIBS = -losgGLUT -losgDB -losgUtil -losg
|
||||
FREETYPE_LIB = -lfreetype
|
||||
GLUT_LIB = -lglut
|
||||
GL_LIBS = -lGLU -lGL
|
||||
X_LIBS = -lXext -lXi -lXmu -lX11
|
||||
SOCKET_LIBS =
|
||||
OTHER_LIBS =
|
||||
OTHER_LIBS = -lm
|
||||
SO_EXT = so
|
||||
PLUGIN_EXT = so
|
||||
|
||||
@ -101,8 +107,6 @@ ifeq ($(OS),Linux)
|
||||
ARCHARGS =
|
||||
LINKARGS = -L/usr/X11R6/lib
|
||||
DYNAMICLIBRARYLIB = -ldl
|
||||
OSGUTIL = -losgUtil
|
||||
OSGDB = -losgDB
|
||||
OSG_LIBS = -losgGLUT -losgDB -losgUtil -losg
|
||||
FREETYPE_LIB = -lfreetype
|
||||
GLUT_LIB = -lglut
|
||||
@ -126,8 +130,6 @@ ifeq ($(OS),FreeBSD)
|
||||
ARCHARGS =
|
||||
LINKARGS = -L/usr/X11R6/lib -L/usr/local/lib -rpath /usr/local/lib
|
||||
DYNAMICLIBRARYLIB = -ldl
|
||||
OSGUTIL = -losgUtil
|
||||
OSGDB = -losgDB
|
||||
OSG_LIBS = -losgGLUT -losgDB -losgUtil -losg
|
||||
FREETYPE_LIB = -lfreetype
|
||||
GLUT_LIB = -lglut
|
||||
@ -151,8 +153,6 @@ ifeq ($(OS),MacOSX)
|
||||
ARCHARGS =
|
||||
LINKARGS = -all_load -L/usr/local/lib -L/usr/lib
|
||||
DYNAMICLIBRARYLIB =
|
||||
OSGUTIL = -losgUtil
|
||||
OSGDB = -losgDB
|
||||
OSG_LIBS = -losgGLUT -losgDB -losgUtil -losg
|
||||
FREETYPE_LIB = -lfreetype
|
||||
GLUT_LIB =
|
||||
@ -189,8 +189,6 @@ ifeq ($(OS),CYGWIN_NT-5.0)
|
||||
ARCHARGS =
|
||||
LINKARGS = -W -Wall
|
||||
DYNAMICLIBRARYLIB =
|
||||
OSGUTIL = -losgutil
|
||||
OSGDB = -losgdb
|
||||
|
||||
OSG_LIBS = -losgGLUT -losgDB -losgUtil -losg
|
||||
GL_LIBS = -lglu32 -lopengl32
|
||||
@ -216,6 +214,7 @@ ifeq ($(OS),CYGWIN_NT-5.0)
|
||||
OTHER_LIBS = $(GL_LIBS)
|
||||
SO_EXT = dll
|
||||
PLUGIN_EXT = dll
|
||||
LINK = cp -f
|
||||
endif
|
||||
|
||||
|
||||
|
@ -207,7 +207,7 @@ __link :
|
||||
'{ print substr($$1,length($$2)+2,512) }'`/`basename $(LNDEST)`;\
|
||||
cd `dirname $(LNDEST)`;\
|
||||
rm -f `basename $(LNDEST)`;\
|
||||
ln -sf $$LINK `basename $(LNDEST)`;\
|
||||
$(LINK) $$LINK `basename $(LNDEST)`;\
|
||||
fi
|
||||
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user