diff options
author | Brian Paul <[email protected]> | 2003-12-15 16:14:55 +0000 |
---|---|---|
committer | Brian Paul <[email protected]> | 2003-12-15 16:14:55 +0000 |
commit | b3b725b1e6044d29fb5f484979766d1ef8a7fa9f (patch) | |
tree | 89b271c27a71618e92bbade62b35956e22d76ee7 | |
parent | f80220d05015c851879f4b347021f98c1690f93b (diff) |
Assorted mklib tweaks.
Added Intel icc support to mklib.
-rw-r--r-- | Make-config | 7 | ||||
-rwxr-xr-x | bin/mklib | 40 | ||||
-rw-r--r-- | src/glu/sgi/Makefile.X11 | 3 | ||||
-rw-r--r-- | src/glut/glx/Makefile.X11 | 2 | ||||
-rw-r--r-- | src/glw/Makefile.X11 | 3 |
5 files changed, 49 insertions, 6 deletions
diff --git a/Make-config b/Make-config index 2abc9d80673..85d9b660000 100644 --- a/Make-config +++ b/Make-config @@ -461,7 +461,7 @@ linux-x86-sse: "GL_LIB_DEPS = -L/usr/X11R6/lib -lX11 -lXext -lm -lpthread" \ "GLU_LIB_DEPS = -L$(TOP)/lib -lGL -lm" \ "GLUT_LIB_DEPS = -L$(TOP)/lib -lGLU -lGL -L/usr/X11R6/lib -lX11 -lXmu -lXt -lXi -lm" \ - "APP_LIB_DEPS = -lm" \ + "APP_LIB_DEPS = -lglut -lGLU -lGL -lm" \ "ASM_SOURCES = $(X86_SOURCES)" linux-icc: @@ -477,8 +477,9 @@ linux-icc: "GL_LIB_DEPS = -L/usr/X11R6/lib -lX11 -lXext -lm -lpthread" \ "GLU_LIB_DEPS = -L$(TOP)/lib -lGL -lm" \ "GLUT_LIB_DEPS = -L$(TOP)/lib -lGLU -lGL -L/usr/X11R6/lib -lX11 -lXmu -lXt -lXi -lm" \ - "APP_LIB_DEPS = -lm" \ - "ASM_SOURCES = $(X86_SOURCES)" + "APP_LIB_DEPS = -lglut -lGLU -lGL -lm" \ + "ASM_SOURCES = $(X86_SOURCES)" \ + "MKLIB_OPTIONS = -arch icc" # Contributed by [email protected] linux-ggi: diff --git a/bin/mklib b/bin/mklib index 327fd8ccf22..3dc4cd91c16 100755 --- a/bin/mklib +++ b/bin/mklib @@ -335,6 +335,46 @@ case $ARCH in FINAL_LIBS="${LIBNAME}" ;; + 'icc') + # Intel C compiler + LIBNAME="lib${LIBNAME}" # prefix with "lib" + + if [ $STATIC = 1 ] ; then + echo "mklib: Making Intel ICC static library: " ${LIBNAME}.a + LINK="ar" + OPTS="-ruv" + # make lib + ${LINK} ${OPTS} ${LIBNAME}.a ${OBJECTS} + # finish up + FINAL_LIBS="${LIBNAME}.a" + else + OPTS="-shared" + VERSION="${MAJOR}.${MINOR}.${PATCH}" + + echo "mklib: Making Intel ICC shared library: " ${LIBNAME}.so.${VERSION} + + if [ $CPLUSPLUS = 1 ] ; then + LINK="icc" + else + LINK="icc" + fi + + # rm any old libs + rm -f ${LIBNAME}.so.${VERSION} + rm -f ${LIBNAME}.so.${MAJOR} + rm -f ${LIBNAME}.so + + # make lib + ${LINK} ${OPTS} -o ${LIBNAME}.so.${VERSION} ${OBJECTS} ${DEPS} + # make usual symlinks + ln -s ${LIBNAME}.so.${VERSION} ${LIBNAME}.so.${MAJOR} + ln -s ${LIBNAME}.so.${MAJOR} ${LIBNAME}.so + # finish up + FINAL_LIBS="${LIBNAME}.so.${VERSION} ${LIBNAME}.so.${MAJOR} ${LIBNAME}.so" + fi + ;; + + 'example') # If you're adding support for a new architecture, you can # start with this: diff --git a/src/glu/sgi/Makefile.X11 b/src/glu/sgi/Makefile.X11 index 7202aa84ffb..5102528585f 100644 --- a/src/glu/sgi/Makefile.X11 +++ b/src/glu/sgi/Makefile.X11 @@ -142,7 +142,8 @@ targets: $(LIBDIR)/$(GLU_LIB) $(LIBDIR)/$(GLU_LIB): $(OBJECTS) $(TOP)/bin/mklib -o $(GLU_LIB_NAME) -major $(GLU_MAJOR) \ -minor $(GLU_MINOR) -patch $(GLU_TINY) \ - $(GLU_LIB_DEPS) -cplusplus -install $(LIBDIR) $(OBJECTS) + $(GLU_LIB_DEPS) -cplusplus -install $(LIBDIR) \ + $(MKLIB_OPTIONS) $(OBJECTS) diff --git a/src/glut/glx/Makefile.X11 b/src/glut/glx/Makefile.X11 index 0ef132d451c..89b920bea9e 100644 --- a/src/glut/glx/Makefile.X11 +++ b/src/glut/glx/Makefile.X11 @@ -103,7 +103,7 @@ targets: $(LIBDIR)/$(GLUT_LIB) $(LIBDIR)/$(GLUT_LIB): $(OBJECTS) $(TOP)/bin/mklib -o glut -major $(GLUT_MAJOR) -minor $(GLUT_MINOR) \ -patch $(GLUT_TINY) $(GLUT_LIB_DEPS) -install $(LIBDIR) \ - $(OBJECTS) + $(MKLIB_OPTIONS) $(OBJECTS) include $(TOP)/Make-config diff --git a/src/glw/Makefile.X11 b/src/glw/Makefile.X11 index 888aebd52cd..b38ef50d4c7 100644 --- a/src/glw/Makefile.X11 +++ b/src/glw/Makefile.X11 @@ -46,7 +46,8 @@ targets: $(LIBDIR)/$(GLW_LIB) message # Make the library $(LIBDIR)/$(GLW_LIB): $(OBJECTS) $(TOP)/bin/mklib -o GLw -major $(MAJOR) -minor $(MINOR) \ - -patch $(TINY) $(GLW_LIB_DEPS) -install $(LIBDIR) $(OBJECTS) + -patch $(TINY) $(GLW_LIB_DEPS) -install $(LIBDIR) \ + $(MKLIB_OPTIONS) $(OBJECTS) message: |