hipchat: 2.2.1388 -> 4.0.1631
This commit is contained in:
parent
420bc33efa
commit
411b4a1df1
@ -1,58 +1,48 @@
|
|||||||
{ stdenv, fetchurl, libtool, xorg, freetype, fontconfig, openssl, glib
|
{ stdenv, fetchurl, xorg, freetype, fontconfig, openssl, glib, nss, nspr, expat
|
||||||
, mesa, gstreamer, gst_plugins_base, dbus, alsaLib, zlib, libuuid
|
, alsaLib, dbus, zlib, libxml2, libxslt, makeWrapper, xkeyboard_config, systemd
|
||||||
, libxml2, libxslt, sqlite, libogg, libvorbis, xz, libcanberra
|
, mesa_noglu, xcbutilkeysyms }:
|
||||||
, makeWrapper, libredirect, xkeyboard_config, xcbutilkeysyms }:
|
|
||||||
|
|
||||||
let
|
let
|
||||||
|
|
||||||
version = "2.2.1388";
|
version = "4.0.1631";
|
||||||
|
|
||||||
rpath = stdenv.lib.makeSearchPath "lib" [
|
rpath = stdenv.lib.makeSearchPath "lib" [
|
||||||
stdenv.glibc
|
|
||||||
libtool
|
|
||||||
xorg.libXext
|
xorg.libXext
|
||||||
xorg.libSM
|
xorg.libSM
|
||||||
xorg.libICE
|
xorg.libICE
|
||||||
xorg.libX11
|
xorg.libX11
|
||||||
xorg.libXft
|
xorg.libXrandr
|
||||||
xorg.libXau
|
xorg.libXdamage
|
||||||
xorg.libXdmcp
|
|
||||||
xorg.libXrender
|
xorg.libXrender
|
||||||
xorg.libXfixes
|
xorg.libXfixes
|
||||||
xorg.libXcomposite
|
xorg.libXcomposite
|
||||||
|
xorg.libXcursor
|
||||||
xorg.libxcb
|
xorg.libxcb
|
||||||
xorg.libXi
|
xorg.libXi
|
||||||
|
xorg.libXScrnSaver
|
||||||
|
xorg.libXtst
|
||||||
freetype
|
freetype
|
||||||
fontconfig
|
fontconfig
|
||||||
openssl
|
openssl
|
||||||
glib
|
glib
|
||||||
mesa
|
nss
|
||||||
gstreamer
|
nspr
|
||||||
gst_plugins_base
|
|
||||||
dbus
|
dbus
|
||||||
alsaLib
|
alsaLib
|
||||||
zlib
|
zlib
|
||||||
libuuid
|
|
||||||
libxml2
|
libxml2
|
||||||
libxslt
|
libxslt
|
||||||
sqlite
|
expat
|
||||||
libogg
|
|
||||||
libvorbis
|
|
||||||
xz
|
|
||||||
libcanberra
|
|
||||||
xcbutilkeysyms
|
xcbutilkeysyms
|
||||||
] + ":${stdenv.cc.cc}/lib${stdenv.lib.optionalString stdenv.is64bit "64"}";
|
systemd
|
||||||
|
mesa_noglu
|
||||||
|
] + ":${stdenv.cc.cc}/lib64";
|
||||||
|
|
||||||
src =
|
src =
|
||||||
if stdenv.system == "x86_64-linux" then
|
if stdenv.system == "x86_64-linux" then
|
||||||
fetchurl {
|
fetchurl {
|
||||||
url = "http://downloads.hipchat.com/linux/arch/x86_64/hipchat-${version}-x86_64.pkg.tar.xz";
|
url = "https://atlassian.artifactoryonline.com/atlassian/hipchat-apt-client/pool/HipChat4-${version}-Linux.deb";
|
||||||
sha256 = "18vl0c7xgyzd2miwkfzc638z0wzszgsdlbnslkkvxmg95ykdrdnz";
|
sha256 = "1ip79zq7j7842sf254296wvvd236w7c764r8wgjdyxzqyvfjfd81";
|
||||||
}
|
|
||||||
else if stdenv.system == "i686-linux" then
|
|
||||||
fetchurl {
|
|
||||||
url = "http://downloads.hipchat.com/linux/arch/i686/hipchat-${version}-i686.pkg.tar.xz";
|
|
||||||
sha256 = "12q8hf3gmcgrqg6v9xqyknwsmwywpwm76jc54sfniiqv5ngq24hl";
|
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
throw "HipChat is not supported on ${stdenv.system}";
|
throw "HipChat is not supported on ${stdenv.system}";
|
||||||
@ -67,36 +57,37 @@ stdenv.mkDerivation {
|
|||||||
buildInputs = [ makeWrapper ];
|
buildInputs = [ makeWrapper ];
|
||||||
|
|
||||||
buildCommand = ''
|
buildCommand = ''
|
||||||
tar xf ${src}
|
ar x $src
|
||||||
|
tar xfvz data.tar.gz
|
||||||
|
|
||||||
mkdir -p $out/libexec/hipchat/bin
|
mkdir -p $out/libexec/hipchat
|
||||||
d=$out/libexec/hipchat/lib
|
d=$out/libexec/hipchat/lib
|
||||||
rm -rfv opt/HipChat/lib/{libstdc++*,libz*,libuuid*,libxml2*,libxslt*,libsqlite*,libogg*,libvorbis*,liblzma*,libcanberra.*,libcanberra-*}
|
mv opt/HipChat4/* $out/libexec/hipchat/
|
||||||
mv opt/HipChat/lib/ $d
|
|
||||||
mv usr/share $out
|
mv usr/share $out
|
||||||
|
|
||||||
for file in $(find $d -type f); do
|
for file in $(find $d -type f); do
|
||||||
patchelf --set-interpreter "$(cat $NIX_CC/nix-support/dynamic-linker)" $file || true
|
patchelf --set-interpreter "$(cat $NIX_CC/nix-support/dynamic-linker)" $file || true
|
||||||
patchelf --set-rpath ${rpath}:\$ORIGIN $file || true
|
patchelf --set-rpath ${rpath}:$out/libexec/hipchat/lib:\$ORIGIN $file || true
|
||||||
done
|
done
|
||||||
|
|
||||||
substituteInPlace $out/share/applications/hipchat.desktop \
|
substituteInPlace $out/share/applications/hipchat4.desktop \
|
||||||
--replace /opt/HipChat/bin $out/bin
|
--replace /opt/HipChat4/bin/HipChat4 $out/bin/hipchat
|
||||||
|
|
||||||
makeWrapper $d/hipchat.bin $out/bin/hipchat \
|
makeWrapper $d/HipChat.bin $out/bin/hipchat \
|
||||||
--set HIPCHAT_LD_LIBRARY_PATH '"$LD_LIBRARY_PATH"' \
|
--set HIPCHAT_LD_LIBRARY_PATH '"$LD_LIBRARY_PATH"' \
|
||||||
--set HIPCHAT_QT_PLUGIN_PATH '"$QT_PLUGIN_PATH"' \
|
--set HIPCHAT_QT_PLUGIN_PATH '"$QT_PLUGIN_PATH"' \
|
||||||
--set LD_PRELOAD "${libredirect}/lib/libredirect.so" \
|
--set QT_XKB_CONFIG_ROOT ${xkeyboard_config}/share/X11/xkb \
|
||||||
--set NIX_REDIRECTS /usr/share/X11/xkb=${xkeyboard_config}/share/X11/xkb
|
--set QTWEBENGINEPROCESS_PATH $d/QtWebEngineProcess
|
||||||
|
|
||||||
mv opt/HipChat/bin/linuxbrowserlaunch $out/libexec/hipchat/bin/
|
makeWrapper $d/QtWebEngineProcess.bin $d/QtWebEngineProcess \
|
||||||
|
--set QT_PLUGIN_PATH "$d/plugins"
|
||||||
'';
|
'';
|
||||||
|
|
||||||
meta = with stdenv.lib; {
|
meta = with stdenv.lib; {
|
||||||
description = "Desktop client for HipChat services";
|
description = "Desktop client for HipChat services";
|
||||||
homepage = http://www.hipchat.com;
|
homepage = http://www.hipchat.com;
|
||||||
license = licenses.unfree;
|
license = licenses.unfree;
|
||||||
platforms = [ "i686-linux" "x86_64-linux" ];
|
platforms = [ "x86_64-linux" ];
|
||||||
maintainers = with maintainers; [ jgeerds ];
|
maintainers = with maintainers; [ jgeerds puffnfresh ];
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
Loading…
x
Reference in New Issue
Block a user