From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from pigeon.gentoo.org ([208.92.234.80] helo=lists.gentoo.org) by finch.gentoo.org with esmtp (Exim 4.60) (envelope-from ) id 1P2WXG-0005mn-9i for garchives@archives.gentoo.org; Sun, 03 Oct 2010 21:56:00 +0000 Received: from pigeon.gentoo.org (localhost [127.0.0.1]) by pigeon.gentoo.org (Postfix) with SMTP id 2A1A8E063D; Sun, 3 Oct 2010 21:55:55 +0000 (UTC) Received: from smtp.gentoo.org (smtp.gentoo.org [140.211.166.183]) by pigeon.gentoo.org (Postfix) with ESMTP id EE8A2E063D for ; Sun, 3 Oct 2010 21:55:54 +0000 (UTC) Received: from flycatcher.gentoo.org (flycatcher.gentoo.org [81.93.255.6]) (using TLSv1 with cipher ADH-CAMELLIA256-SHA (256/256 bits)) (No client certificate requested) by smtp.gentoo.org (Postfix) with ESMTPS id D567F1B4087 for ; Sun, 3 Oct 2010 21:55:53 +0000 (UTC) Received: by flycatcher.gentoo.org (Postfix, from userid 2162) id 71FC920054; Sun, 3 Oct 2010 21:55:52 +0000 (UTC) From: "Sebastien Fabbro (bicatali)" To: gentoo-commits@lists.gentoo.org Reply-To: gentoo-dev@lists.gentoo.org, bicatali@gentoo.org Subject: [gentoo-commits] gentoo-x86 commit in media-libs/qhull/files: qhull-2010.1-overflows.patch qhull-2010.1-cmake-install.patch X-VCS-Repository: gentoo-x86 X-VCS-Files: qhull-2010.1-overflows.patch qhull-2010.1-cmake-install.patch X-VCS-Directories: media-libs/qhull/files X-VCS-Committer: bicatali X-VCS-Committer-Name: Sebastien Fabbro Content-Type: text/plain; charset=utf8 Message-Id: <20101003215552.71FC920054@flycatcher.gentoo.org> Date: Sun, 3 Oct 2010 21:55:52 +0000 (UTC) Precedence: bulk List-Post: List-Help: List-Unsubscribe: List-Subscribe: List-Id: Gentoo Linux mail X-BeenThere: gentoo-commits@lists.gentoo.org Content-Transfer-Encoding: quoted-printable X-Archives-Salt: f6ed4716-8ccf-497c-9209-b7790626da49 X-Archives-Hash: 5580c66949b8cd28d62e8e62ebe95864 bicatali 10/10/03 21:55:52 Added: qhull-2010.1-overflows.patch qhull-2010.1-cmake-install.patch Log: Added a patch for overflows. Add a patch that allows to install everyth= ing with cmake, so install include file and libararies properly now fixin= g bug #338964. Added longdescription and a static-libs use flag. =20 (Portage version: 2.2_rc88/cvs/Linux x86_64) Revision Changes Path 1.1 media-libs/qhull/files/qhull-2010.1-overflows.patch file : http://sources.gentoo.org/viewvc.cgi/gentoo-x86/media-libs/qhull/f= iles/qhull-2010.1-overflows.patch?rev=3D1.1&view=3Dmarkup plain: http://sources.gentoo.org/viewvc.cgi/gentoo-x86/media-libs/qhull/f= iles/qhull-2010.1-overflows.patch?rev=3D1.1&content-type=3Dtext/plain Index: qhull-2010.1-overflows.patch =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D >From 176c01851026125f574a8223ad49ec58b2b58ec0 Mon Sep 17 00:00:00 2001 From: Johannes Obermayr Date: Fri, 23 Jul 2010 20:02:19 +0200 Subject: [PATCH] Fix some serious compiler warnings causing build breakag= e on openSUSE. --- src/global.c | 2 +- src/rboxlib.c | 6 +++--- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/src/global.c b/src/global.c index 3c6141a..4c9f56c 100644 --- a/src/global.c +++ b/src/global.c @@ -614,7 +614,7 @@ void qh_initflags(char *command) { if (command <=3D &qh qhull_command[0] || command > &qh qhull_command[0= ] + sizeof(qh qhull_command)) { if (command !=3D &qh qhull_command[0]) { *qh qhull_command=3D '\0'; - strncat( qh qhull_command, command, sizeof( qh qhull_command)); + strncat(qh qhull_command, command, sizeof(qh qhull_command)-strlen= (qh qhull_command)-1); } while (*s && !isspace(*s)) /* skip program name */ s++; diff --git a/src/rboxlib.c b/src/rboxlib.c index 4f11d22..17d01ac 100644 --- a/src/rboxlib.c +++ b/src/rboxlib.c @@ -124,7 +124,7 @@ int qh_rboxpoints(FILE* fout, FILE* ferr, char* rbox_= command) { } =20 *command=3D '\0'; - strncat(command, rbox_command, sizeof(command)); + strncat(command, rbox_command, sizeof(command)-strlen(command)-1); =20 while (*s && !isspace(*s)) /* skip program name */ s++; @@ -346,8 +346,8 @@ int qh_rboxpoints(FILE* fout, FILE* ferr, char* rbox_= command) { } }else if (israndom) { seed=3D (int)time(&timedata); - sprintf(seedbuf, " t%d", seed); /* appends an extra t, not worth re= moving */ - strncat(command, seedbuf, sizeof(command)); + printf(seedbuf, " t%d", seed); /* appends an extra t, not worth rem= oving */ + strncat(command, seedbuf, sizeof(command)-strlen(command)-1); t=3D strstr(command, " t "); if (t) strcpy(t+1, t+3); /* remove " t " */ --=20 1.6.1 1.1 media-libs/qhull/files/qhull-2010.1-cmake-install.pa= tch file : http://sources.gentoo.org/viewvc.cgi/gentoo-x86/media-libs/qhull/f= iles/qhull-2010.1-cmake-install.patch?rev=3D1.1&view=3Dmarkup plain: http://sources.gentoo.org/viewvc.cgi/gentoo-x86/media-libs/qhull/f= iles/qhull-2010.1-cmake-install.patch?rev=3D1.1&content-type=3Dtext/plain Index: qhull-2010.1-cmake-install.patch =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D diff -Nur qhull-2010.1.orig/CMakeLists.txt qhull-2010.1/CMakeLists.txt --- qhull-2010.1.orig/CMakeLists.txt 2010-01-10 00:07:32.000000000 +0000 +++ qhull-2010.1/CMakeLists.txt 2010-10-03 22:16:50.000000000 +0100 @@ -1,8 +1,44 @@ project(qhull) -cmake_minimum_required(VERSION 2.4) -if(COMMAND cmake_policy) - cmake_policy(SET CMP0003 NEW) -endif(COMMAND cmake_policy) +cmake_minimum_required(VERSION 2.6) + + +set(QHULL_VERSION "2010.1") + +if(INCLUDE_INSTALL_DIR) +else() +set(INCLUDE_INSTALL_DIR ${CMAKE_INSTALL_PREFIX}/include) +endif() +if(LIB_INSTALL_DIR) +else() +set(LIB_INSTALL_DIR ${CMAKE_INSTALL_PREFIX}/lib) +endif() +if(BIN_INSTALL_DIR) +else() +set(BIN_INSTALL_DIR ${CMAKE_INSTALL_PREFIX}/bin) +endif() +if(DOC_INSTALL_DIR) +else() +set(DOC_INSTALL_DIR ${CMAKE_INSTALL_PREFIX}/share/doc/qhull) +endif() + +message(STATUS) +message(STATUS "=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D qhull Build Information =3D= =3D=3D=3D=3D=3D=3D=3D=3D=3D") +message(STATUS "Build Version: ${QHULL_VERSION}") +message(STATUS "Install Prefix (CMAKE_INSTALL_PREFIX): ${CMAKE_INSTALL_P= REFIX}") +message(STATUS "Binary Directory (BIN_INSTALL_DIR): ${BIN_INSTALL_DIR}") +message(STATUS "Library Directory (LIB_INSTALL_DIR): ${LIB_INSTALL_DIR}"= ) +message(STATUS "Include Directory (INCLUDE_INSTALL_DIR): ${INCLUDE_INSTA= LL_DIR}") +message(STATUS "Documentation Directory (DOC_INSTALL_DIR): ${DOC_INSTALL= _DIR}") +message(STATUS) +message(STATUS "To change any of these options, override them using -D{O= PTION_NAME} on the commandline.") +message(STATUS "To build and install qhull, run \"make\" and \"make inst= all\"") +message(STATUS) + =20 add_subdirectory(src) +option(WITH_STATIC_LIBS "Build with a static library" OFF) +option(WITH_DOCS "Install HTML documentation" OFF) =20 +if (WITH_DOCS) +install(DIRECTORY html/ DESTINATION ${DOC_INSTALL_DIR}) +endif (WITH_DOCS) diff -Nur qhull-2010.1.orig/src/CMakeLists.txt qhull-2010.1/src/CMakeList= s.txt --- qhull-2010.1.orig/src/CMakeLists.txt 2010-01-10 00:07:32.000000000 +0= 000 +++ qhull-2010.1/src/CMakeLists.txt 2010-10-03 22:21:34.000000000 +0100 @@ -23,8 +23,25 @@ =20 file(GLOB qhull_hdr *.h) =20 -add_library(qhull ${qhull_src}) +add_library(qhull SHARED ${qhull_src}) target_link_libraries(qhull m) +if(UNIX) + if(APPLE) + set_target_properties(qhull PROPERTIES=20 + INSTALL_NAME_DIR "${LIB_INSTALL_DIR}") + else(APPLE) + set_target_properties(qhull PROPERTIES=20 + INSTALL_RPATH "${LIB_INSTALL_DIR}" + INSTALL_RPATH_USE_LINK_PATH TRUE + BUILD_WITH_INSTALL_RPATH FALSE) + endif(APPLE) +endif(UNIX) + +if(WITH_STATIC_LIBS) + add_library(qhullstatic STATIC ${qhull_src}) + set_property(TARGET qhullstatic PROPERTY OUTPUT_NAME "qhull") + install(TARGETS qhullstatic ARCHIVE DESTINATION ${LIB_INSTALL_DIR}) +endif(WITH_STATIC_LIBS) =20 set(qhullcmd_SOURCES unix.c) set(rbox_SOURCES rbox.c) @@ -36,6 +53,7 @@ =20 add_executable(qhullcmd ${qhullcmd_SOURCES}) target_link_libraries(qhullcmd qhull) +set_property(TARGET qhullcmd PROPERTY OUTPUT_NAME "qhull") =20 add_executable(rbox ${rbox_SOURCES}) target_link_libraries(rbox qhull) @@ -52,3 +70,7 @@ add_executable(qhalf ${qhalf_SOURCES}) target_link_libraries(qhalf qhull) =20 +install(TARGETS qhull qhullcmd rbox qconvex qdelaunay qvoronoi qhalf + RUNTIME DESTINATION ${BIN_INSTALL_DIR}=20 + LIBRARY DESTINATION ${LIB_INSTALL_DIR}) +install(FILES libqhull.h DESTINATION ${INCLUDE_INSTALL_DIR})