diff options
author | Alexander von Gluck <kallisti5@unixzen.com> | 2011-12-26 16:23:03 -0700 |
---|---|---|
committer | Brian Paul <brianp@vmware.com> | 2011-12-26 16:23:03 -0700 |
commit | a5608a5098e059510ba3fc79c8c0ba928db60257 (patch) | |
tree | 75d5ea8e8e452d4242132b85513f4e620d53c9a5 /bin | |
parent | aa284042a3116224f623ce8ec1680997c6818827 (diff) | |
download | external_mesa3d-a5608a5098e059510ba3fc79c8c0ba928db60257.zip external_mesa3d-a5608a5098e059510ba3fc79c8c0ba928db60257.tar.gz external_mesa3d-a5608a5098e059510ba3fc79c8c0ba928db60257.tar.bz2 |
mklib: Add Haiku build support
Signed-off-by: Brian Paul <brianp@vmware.com>
Diffstat (limited to 'bin')
-rwxr-xr-x | bin/mklib | 37 |
1 files changed, 37 insertions, 0 deletions
@@ -959,6 +959,43 @@ case $ARCH in fi ;; + 'Haiku') + if [ $STATIC = 1 ] ; then + LIBNAME="lib${LIBNAME}.a" + if [ "x$LINK" = "x" ] ; then + # -linker was not specified so set default link command now + if [ $CPLUSPLUS = 1 ] ; then + LINK=g++ + else + LINK=gcc + fi + fi + + OPTS="-ru" + if [ "${ALTOPTS}" ] ; then + OPTS=${ALTOPTS} + fi + + echo "mklib: Making static library for Haiku: " ${LIBNAME} + + # expand .a into .o files + NEW_OBJECTS=`expand_archives ${LIBNAME}.obj $OBJECTS` + + # make static lib + FINAL_LIBS=`make_ar_static_lib ${OPTS} 1 ${LIBNAME} ${NEW_OBJECTS}` + + # remove temporary extracted .o files + rm -rf ${LIBNAME}.obj + else + LIBNAME="lib${LIBNAME}.so" # prefix with "lib", suffix with ".so" + OPTS="-shared" + + echo "mklib: Making shared library for Haiku: " ${LIBNAME} + ${LINK} ${OPTS} ${LDFLAGS} ${OBJECTS} ${DEPS} -o ${LIBNAME} + FINAL_LIBS="${LIBNAME}" + fi + ;; + 'example') # If you're adding support for a new architecture, you can # start with this: |