Merge pull request #261441 from wegank/texmacs-bump

texmacs: 2.1 -> 2.1.2
This commit is contained in:
Weijia Wang 2023-10-21 14:56:00 +02:00 committed by GitHub
commit 9fc01a01a7
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
2 changed files with 32 additions and 11 deletions

View File

@ -1,5 +1,5 @@
{ lib, mkDerivation, callPackage, fetchurl, { lib, stdenv, callPackage, fetchurl,
guile_1_8, qtbase, xmodmap, which, freetype, guile_1_8, xmodmap, which, freetype,
libjpeg, libjpeg,
sqlite, sqlite,
tex ? null, tex ? null,
@ -8,6 +8,11 @@
python3 ? null, python3 ? null,
cmake, cmake,
pkg-config, pkg-config,
wrapQtAppsHook,
xdg-utils,
qtbase,
qtsvg,
qtmacextras,
ghostscriptX ? null, ghostscriptX ? null,
extraFonts ? false, extraFonts ? false,
chineseFonts ? false, chineseFonts ? false,
@ -15,32 +20,49 @@
koreanFonts ? false }: koreanFonts ? false }:
let let
pname = "TeXmacs"; pname = "texmacs";
version = "2.1"; version = "2.1.2";
common = callPackage ./common.nix { common = callPackage ./common.nix {
inherit tex extraFonts chineseFonts japaneseFonts koreanFonts; inherit tex extraFonts chineseFonts japaneseFonts koreanFonts;
}; };
in in
mkDerivation { stdenv.mkDerivation {
inherit pname version; inherit pname version;
src = fetchurl { src = fetchurl {
url = "https://www.texmacs.org/Download/ftp/tmftp/source/TeXmacs-${version}-src.tar.gz"; url = "https://www.texmacs.org/Download/ftp/tmftp/source/TeXmacs-${version}-src.tar.gz";
sha256 = "1gl6k1bwrk1y7hjyl4xvlqvmk5crl4jvsk8wrfp7ynbdin6n2i48"; hash = "sha256-Ds9gxOwMYSttEWrawgxLHGxHyMBvt8WmyPIwBP2g/CM=";
}; };
nativeBuildInputs = [ cmake pkg-config ]; postPatch = common.postPatch + ''
substituteInPlace configure \
--replace "-mfpmath=sse -msse2" ""
'';
nativeBuildInputs = [
guile_1_8
pkg-config
wrapQtAppsHook
xdg-utils
] ++ lib.optionals (!stdenv.isDarwin) [
cmake
];
buildInputs = [ buildInputs = [
guile_1_8 guile_1_8
qtbase qtbase
qtsvg
ghostscriptX ghostscriptX
freetype freetype
libjpeg libjpeg
sqlite sqlite
git git
python3 python3
] ++ lib.optionals stdenv.isDarwin [
qtmacextras
]; ];
NIX_LDFLAGS = "-lz";
env.NIX_LDFLAGS = "-lz";
qtWrapperArgs = [ qtWrapperArgs = [
"--suffix" "PATH" ":" (lib.makeBinPath [ "--suffix" "PATH" ":" (lib.makeBinPath [
@ -58,10 +80,8 @@ mkDerivation {
wrapQtApp $out/bin/texmacs wrapQtApp $out/bin/texmacs
''; '';
inherit (common) postPatch;
meta = common.meta // { meta = common.meta // {
maintainers = [ lib.maintainers.roconnor ]; maintainers = [ lib.maintainers.roconnor ];
platforms = lib.platforms.gnu ++ lib.platforms.linux; # arbitrary choice platforms = lib.platforms.all;
}; };
} }

View File

@ -13836,6 +13836,7 @@ with pkgs;
tewisay = callPackage ../tools/misc/tewisay { }; tewisay = callPackage ../tools/misc/tewisay { };
texmacs = libsForQt5.callPackage ../applications/editors/texmacs { texmacs = libsForQt5.callPackage ../applications/editors/texmacs {
stdenv = if stdenv.isDarwin then darwin.apple_sdk_11_0.stdenv else stdenv;
tex = texlive.combined.scheme-small; tex = texlive.combined.scheme-small;
extraFonts = true; extraFonts = true;
}; };