Merge pull request #156001 from helsinki-systems/upd/tulip

tulip: 5.2.1 -> 5.6.1
This commit is contained in:
ajs124 2022-01-26 23:33:44 +01:00 committed by GitHub
commit 3638ca8be6
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
4 changed files with 9 additions and 192 deletions

View File

@ -1,19 +1,20 @@
{ fetchurl, lib, stdenv, libxml2, freetype, libGLU, libGL, glew, qt4
, cmake, makeWrapper, libjpeg, python2 }:
{ fetchurl, lib, stdenv, libxml2, freetype, libGLU, libGL, glew
, qtbase, wrapQtAppsHook, python3
, cmake, libjpeg }:
let version = "5.2.1"; in
stdenv.mkDerivation rec {
pname = "tulip";
inherit version;
version = "5.6.1";
src = fetchurl {
url = "mirror://sourceforge/auber/${pname}-${version}_src.tar.gz";
sha256 = "0bqmqy6sri87a8xv5xf7ffaq5zin4hiaa13g0l64b84i7yckfwky";
sha256 = "1fy3nvgxv3igwc1d23zailcgigj1d0f2kkh7a5j24c0dyqz5zxmw";
};
buildInputs = [ libxml2 freetype glew libGLU libGL qt4 libjpeg python2 ];
buildInputs = [ libxml2 freetype glew libGLU libGL libjpeg qtbase python3 ];
nativeBuildInputs = [ cmake wrapQtAppsHook ];
nativeBuildInputs = [ cmake makeWrapper ];
qtWrapperArgs = [ ''--prefix PATH : ${lib.makeBinPath [ python3 ]}'' ];
# FIXME: "make check" needs Docbook's DTD 4.4, among other things.
doCheck = false;

View File

@ -1,88 +0,0 @@
{ lib, stdenv, fetchurl, fetchpatch, curl, expat, zlib, bzip2
, useNcurses ? false, ncurses, useQt4 ? false, qt4, ps
}:
with lib;
assert stdenv ? cc;
assert stdenv.cc ? libc;
let
os = lib.optionalString;
majorVersion = "2.8";
minorVersion = "12.2";
version = "${majorVersion}.${minorVersion}";
in
stdenv.mkDerivation rec {
pname = "cmake${os useNcurses "-cursesUI"}${os useQt4 "-qt4UI"}";
inherit version;
inherit majorVersion;
src = fetchurl {
url = "${meta.homepage}files/v${majorVersion}/cmake-${version}.tar.gz";
sha256 = "0phf295a9cby0v7zqdswr238v5aiy3rb2fs6dz39zjxbmzlp8rcc";
};
enableParallelBuilding = true;
patches =
[(fetchpatch { # see https://www.cmake.org/Bug/view.php?id=13959
name = "FindFreetype-2.5.patch";
url = "https://public.kitware.com/Bug/file/4660/0001-Support-finding-freetype2-using-pkg-config.patch";
sha256 = "136z63ff83hnwd247cq4m8m8164pklzyl5i2csf5h6wd8p01pdkj";
})] ++
# Don't search in non-Nix locations such as /usr, but do search in our libc.
[ ./search-path-2.8.patch ] ++
optional (stdenv.hostPlatform != stdenv.buildPlatform) (fetchurl {
name = "fix-darwin-cross-compile.patch";
url = "https://public.kitware.com/Bug/file_download.php?"
+ "file_id=4981&type=bug";
sha256 = "16acmdr27adma7gs9rs0dxdiqppm15vl3vv3agy7y8s94wyh4ybv";
});
postPatch = ''
substituteInPlace Utilities/cmlibarchive/CMakeLists.txt \
--replace '"-framework CoreServices"' '""'
'';
buildInputs = [ setupHook curl expat zlib bzip2 ]
++ optional useNcurses ncurses
++ optional useQt4 qt4;
propagatedBuildInputs = [ ps ];
CMAKE_PREFIX_PATH = concatStringsSep ":"
(concatMap (p: [ (p.dev or p) (p.out or p) ]) buildInputs);
configureFlags = [
"--docdir=/share/doc/${pname}-${version}"
"--mandir=/share/man"
"--system-libs"
"--no-system-libarchive"
] ++ lib.optional useQt4 "--qt-gui";
setupHook = ./setup-hook.sh;
dontUseCmakeConfigure = true;
preConfigure = with stdenv; ''
fixCmakeFiles .
substituteInPlace Modules/Platform/UnixPaths.cmake \
--subst-var-by libc_bin ${getBin cc.libc} \
--subst-var-by libc_dev ${getDev cc.libc} \
--subst-var-by libc_lib ${getLib cc.libc}
configureFlags="--parallel=''${NIX_BUILD_CORES:-1} $configureFlags"
'';
hardeningDisable = [ "format" ];
meta = {
homepage = "https://cmake.org";
description = "Cross-Platform Makefile Generator";
platforms = if useQt4 then qt4.meta.platforms else lib.platforms.unix;
maintainers = with lib.maintainers; [ xfix ];
license = lib.licenses.bsd3;
};
}

View File

@ -1,92 +0,0 @@
diff -ru3 cmake-2.8.12.2/Modules/Platform/Linux.cmake cmake-2.8.12.2-new/Modules/Platform/Linux.cmake
--- cmake-2.8.12.2/Modules/Platform/Linux.cmake 2014-01-16 21:15:08.000000000 +0400
+++ cmake-2.8.12.2-new/Modules/Platform/Linux.cmake 2016-04-13 22:00:32.928575740 +0300
@@ -36,22 +36,11 @@
# checking the platform every time. This option is advanced enough
# that only package maintainers should need to adjust it. They are
# capable of providing a setting on the command line.
- if(EXISTS "/etc/debian_version")
- set(CMAKE_INSTALL_SO_NO_EXE 1 CACHE INTERNAL
- "Install .so files without execute permission.")
- else()
- set(CMAKE_INSTALL_SO_NO_EXE 0 CACHE INTERNAL
- "Install .so files without execute permission.")
- endif()
+ set(CMAKE_INSTALL_SO_NO_EXE 0 CACHE INTERNAL
+ "Install .so files without execute permission.")
endif()
# Match multiarch library directory names.
set(CMAKE_LIBRARY_ARCHITECTURE_REGEX "[a-z0-9_]+(-[a-z0-9_]+)?-linux-gnu[a-z0-9_]*")
include(Platform/UnixPaths)
-
-# Debian has lib64 paths only for compatibility so they should not be
-# searched.
-if(EXISTS "/etc/debian_version")
- set_property(GLOBAL PROPERTY FIND_LIBRARY_USE_LIB64_PATHS FALSE)
-endif()
diff -ru3 cmake-2.8.12.2/Modules/Platform/UnixPaths.cmake cmake-2.8.12.2-new/Modules/Platform/UnixPaths.cmake
--- cmake-2.8.12.2/Modules/Platform/UnixPaths.cmake 2014-01-16 21:15:08.000000000 +0400
+++ cmake-2.8.12.2-new/Modules/Platform/UnixPaths.cmake 2016-04-14 00:09:10.106362636 +0300
@@ -32,9 +32,6 @@
# List common installation prefixes. These will be used for all
# search types.
list(APPEND CMAKE_SYSTEM_PREFIX_PATH
- # Standard
- /usr/local /usr /
-
# CMake install location
"${_CMAKE_INSTALL_DIR}"
@@ -44,44 +41,26 @@
# List common include file locations not under the common prefixes.
list(APPEND CMAKE_SYSTEM_INCLUDE_PATH
- # Windows API on Cygwin
- /usr/include/w32api
-
- # X11
- /usr/X11R6/include /usr/include/X11
-
- # Other
- /usr/pkg/include
- /opt/csw/include /opt/include
- /usr/openwin/include
+ @libc_dev@/include
)
list(APPEND CMAKE_SYSTEM_LIBRARY_PATH
- # Windows API on Cygwin
- /usr/lib/w32api
-
- # X11
- /usr/X11R6/lib /usr/lib/X11
-
- # Other
- /usr/pkg/lib
- /opt/csw/lib /opt/lib
- /usr/openwin/lib
+ @libc_lib@/lib
)
list(APPEND CMAKE_SYSTEM_PROGRAM_PATH
- /usr/pkg/bin
+ @libc_bin@/bin
)
list(APPEND CMAKE_PLATFORM_IMPLICIT_LINK_DIRECTORIES
- /lib /usr/lib /usr/lib32 /usr/lib64
+ @libc_lib@/lib
)
list(APPEND CMAKE_C_IMPLICIT_INCLUDE_DIRECTORIES
- /usr/include
+ @libc_dev@/include
)
list(APPEND CMAKE_CXX_IMPLICIT_INCLUDE_DIRECTORIES
- /usr/include
+ @libc_dev@/include
)
# Enable use of lib64 search path variants by default.

View File

@ -14490,8 +14490,6 @@ with pkgs;
ctmg = callPackage ../tools/security/ctmg { };
cmake_2_8 = callPackage ../development/tools/build-managers/cmake/2.8.nix { };
cmake = libsForQt5.callPackage ../development/tools/build-managers/cmake {
inherit (darwin.apple_sdk.frameworks) SystemConfiguration;
};
@ -32628,9 +32626,7 @@ with pkgs;
astrolabe-generator = callPackage ../applications/science/astronomy/astrolabe-generator { };
tulip = callPackage ../applications/science/misc/tulip {
cmake = cmake_2_8;
};
tulip = libsForQt5.callPackage ../applications/science/misc/tulip { };
vite = callPackage ../applications/science/misc/vite { };