tangled
alpha
login
or
join now
pyrox.dev
/
nixpkgs
0
fork
atom
lol
0
fork
atom
overview
issues
pulls
pipelines
qt56: remove fixQtModuleCMakeConfig
Thomas Tuegel
10 years ago
d22df66c
dd34c610
+25
-82
17 changed files
expand all
collapse all
unified
split
pkgs
development
libraries
qt-5
5.6
default.nix
fix-qt-module-cmake-config.sh
qmake-hook.sh
qtbase
default.nix
qtconnectivity.nix
qtdeclarative
default.nix
qtenginio.nix
qtlocation.nix
qtmultimedia.nix
qtscript
default.nix
qtsensors.nix
qtserialport
default.nix
qtsvg.nix
qttools.nix
qtwebsockets.nix
qtx11extras.nix
qtxmlpatterns.nix
+1
-2
pkgs/development/libraries/qt-5/5.6/default.nix
···
45
45
propagatedBuildInputs = args.qtInputs ++ (args.propagatedBuildInputs or []);
46
46
nativeBuildInputs =
47
47
(args.nativeBuildInputs or [])
48
48
-
++ [ pkgs.perl self.fixQtModuleCMakeConfig self.qmakeHook ];
48
48
+
++ [ pkgs.perl self.qmakeHook ];
49
49
50
50
NIX_QT_SUBMODULE = args.NIX_QT_SUBMODULE or true;
51
51
···
111
111
];
112
112
113
113
makeQtWrapper = makeSetupHook { deps = [ makeWrapper ]; } ./make-qt-wrapper.sh;
114
114
-
fixQtModuleCMakeConfig = makeSetupHook { } ./fix-qt-module-cmake-config.sh;
115
114
qmakeHook = makeSetupHook { substitutions = { qt_dev = qtbase.dev; lndir = pkgs.xorg.lndir; }; } ./qmake-hook.sh;
116
115
117
116
};
-5
pkgs/development/libraries/qt-5/5.6/fix-qt-module-cmake-config.sh
···
1
1
-
fixQtModuleCMakeConfig() {
2
2
-
local module="$1"
3
3
-
sed -e "/set(imported_location/ s@\\\${_qt5${module}_install_prefix}@${!outputLib}@" \
4
4
-
-i "${!outputDev}/lib/cmake/Qt5${module}/Qt5${module}Config.cmake"
5
5
-
}
+9
-2
pkgs/development/libraries/qt-5/5.6/qmake-hook.sh
···
44
44
export PATH="$qtOut/bin${PATH:+:}$PATH"
45
45
}
46
46
47
47
-
_qtMultioutModuleDevs() {
47
47
+
_qtModuleMultioutDevsPre() {
48
48
# We cannot simply set these paths in configureFlags because libQtCore retains
49
49
# references to the paths it was built with.
50
50
moveToOutput "bin" "${!outputDev}"
···
53
53
# The destination directory must exist or moveToOutput will do nothing
54
54
mkdir -p "${!outputDev}/share"
55
55
moveToOutput "share/doc" "${!outputDev}"
56
56
+
}
56
57
58
58
+
_qtModuleMultioutDevsPost() {
57
59
# Move libtool archives and qmake project files to $dev/lib
58
60
if [ "z${!outputLib}" != "z${!outputDev}" ]; then
59
61
pushd "${!outputLib}"
···
63
65
mkdir -p "${!outputDev}/$(dirname "$file")"
64
66
mv "${!outputLib}/$file" "${!outputDev}/$file"
65
67
done
68
68
+
69
69
+
# Ensure that CMake can find the shared libraries
70
70
+
mkdir -p "${!outputDev}/lib"
71
71
+
@lndir@/bin/lndir -silent "${!outputLib}/lib" "${!outputDev}/lib"
66
72
fi
67
73
popd
68
74
fi
···
108
114
109
115
if [ -n "$NIX_QT_SUBMODULE" ]; then
110
116
postInstallHooks+=(_qtRmQmake _qtRmModules)
111
111
-
preFixupHooks+=(_qtMultioutModuleDevs)
117
117
+
preFixupHooks+=(_qtModuleMultioutDevsPre)
118
118
+
postFixupHooks+=(_qtModuleMultioutDevsPost)
112
119
fi
113
120
114
121
fi
+15
-25
pkgs/development/libraries/qt-5/5.6/qtbase/default.nix
···
1
1
-
{ stdenv, lib, fetchgit, copyPathsToStore, fixQtModuleCMakeConfig
1
1
+
{ stdenv, lib, fetchgit, copyPathsToStore
2
2
, srcs
3
3
4
4
, xlibs, libX11, libxcb, libXcursor, libXext, libXrender, libXi
···
206
206
++ lib.optional (postgresql != null) postgresql
207
207
++ lib.optionals gtkStyle [gnome_vfs.out libgnomeui.out gtk GConf];
208
208
209
209
-
nativeBuildInputs = [ fixQtModuleCMakeConfig lndir patchelf perl pkgconfig python ];
209
209
+
nativeBuildInputs = [ lndir patchelf perl pkgconfig python ];
210
210
211
211
# freetype-2.5.4 changed signedness of some struct fields
212
212
NIX_CFLAGS_COMPILE = "-Wno-error=sign-compare";
···
222
222
mkdir -p "$dev/share"
223
223
moveToOutput "share/doc" "$dev"
224
224
225
225
-
# Move libtool archives and qmake projects
226
226
-
if [ "z''${!outputLib}" != "z''${!outputDev}" ]; then
227
227
-
pushd "''${!outputLib}"
228
228
-
find lib -name '*.a' -o -name '*.la' -o -name '*.prl' | \
229
229
-
while read -r file; do
230
230
-
mkdir -p "''${!outputDev}/$(dirname "$file")"
231
231
-
mv "''${!outputLib}/$file" "''${!outputDev}/$file"
232
232
-
done
233
233
-
popd
234
234
-
fi
235
235
-
236
225
# Move the QGtkStyle plugin to the gtk output
237
226
mkdir -p "$gtk/lib/qt5/plugins/platformthemes"
238
227
mv "$out/lib/qt5/plugins/platformthemes/libqgtk2.so" "$gtk/lib/qt5/plugins/platformthemes"
···
255
244
# Don't retain build-time dependencies like gdb and ruby.
256
245
sed '/QMAKE_DEFAULT_.*DIRS/ d' -i $dev/mkspecs/qconfig.pri
257
246
258
258
-
fixQtModuleCMakeConfig "Concurrent"
259
259
-
fixQtModuleCMakeConfig "Core"
260
260
-
fixQtModuleCMakeConfig "DBus"
261
261
-
fixQtModuleCMakeConfig "Gui"
262
262
-
fixQtModuleCMakeConfig "Network"
263
263
-
fixQtModuleCMakeConfig "OpenGL"
264
264
-
fixQtModuleCMakeConfig "OpenGLExtensions"
265
265
-
fixQtModuleCMakeConfig "PrintSupport"
266
266
-
fixQtModuleCMakeConfig "Sql"
267
267
-
fixQtModuleCMakeConfig "Test"
268
268
-
fixQtModuleCMakeConfig "Widgets"
269
269
-
fixQtModuleCMakeConfig "Xml"
247
247
+
# Move libtool archives and qmake projects
248
248
+
if [ "z''${!outputLib}" != "z''${!outputDev}" ]; then
249
249
+
pushd "''${!outputLib}"
250
250
+
find lib -name '*.a' -o -name '*.la' -o -name '*.prl' | \
251
251
+
while read -r file; do
252
252
+
mkdir -p "''${!outputDev}/$(dirname "$file")"
253
253
+
mv "''${!outputLib}/$file" "''${!outputDev}/$file"
254
254
+
done
255
255
+
popd
256
256
+
257
257
+
# Ensure that CMake can find the shared libraries
258
258
+
lndir -silent "''${!outputLib}/lib" "''${!outputDev}/lib"
259
259
+
fi
270
260
'';
271
261
272
262
setupHook = ./setup-hook.sh;
-4
pkgs/development/libraries/qt-5/5.6/qtconnectivity.nix
···
3
3
qtSubmodule {
4
4
name = "qtconnectivity";
5
5
qtInputs = [ qtbase qtdeclarative ];
6
6
-
postFixup = ''
7
7
-
fixQtModuleCMakeConfig "Bluetooth"
8
8
-
fixQtModuleCMakeConfig "Nfc"
9
9
-
'';
10
6
}
-6
pkgs/development/libraries/qt-5/5.6/qtdeclarative/default.nix
···
5
5
patches = copyPathsToStore (lib.readPathsFromFile ./. ./series);
6
6
qtInputs = [ qtbase qtsvg qtxmlpatterns ];
7
7
nativeBuildInputs = [ python ];
8
8
-
postFixup = ''
9
9
-
fixQtModuleCMakeConfig "Qml"
10
10
-
fixQtModuleCMakeConfig "Quick"
11
11
-
fixQtModuleCMakeConfig "QuickTest"
12
12
-
fixQtModuleCMakeConfig "QuickWidgets"
13
13
-
'';
14
8
}
-3
pkgs/development/libraries/qt-5/5.6/qtenginio.nix
···
3
3
qtSubmodule {
4
4
name = "qtenginio";
5
5
qtInputs = [ qtdeclarative ];
6
6
-
postFixup = ''
7
7
-
fixQtModuleCMakeConfig "Enginio"
8
8
-
'';
9
6
}
-4
pkgs/development/libraries/qt-5/5.6/qtlocation.nix
···
3
3
qtSubmodule {
4
4
name = "qtlocation";
5
5
qtInputs = [ qtbase qtmultimedia ];
6
6
-
postFixup = ''
7
7
-
fixQtModuleCMakeConfig "Location"
8
8
-
fixQtModuleCMakeConfig "Positioning"
9
9
-
'';
10
6
}
-4
pkgs/development/libraries/qt-5/5.6/qtmultimedia.nix
···
9
9
pkgconfig alsaLib gstreamer gst-plugins-base libpulseaudio
10
10
];
11
11
qmakeFlags = [ "GST_VERSION=1.0" ];
12
12
-
postFixup = ''
13
13
-
fixQtModuleCMakeConfig "Multimedia"
14
14
-
fixQtModuleCMakeConfig "MultimediaWidgets"
15
15
-
'';
16
12
}
-3
pkgs/development/libraries/qt-5/5.6/qtscript/default.nix
···
4
4
name = "qtscript";
5
5
qtInputs = [ qtbase qttools ];
6
6
patches = [ ./0001-glib-2.32.patch ];
7
7
-
postFixup = ''
8
8
-
fixQtModuleCMakeConfig "Script"
9
9
-
'';
10
7
}
-3
pkgs/development/libraries/qt-5/5.6/qtsensors.nix
···
3
3
qtSubmodule {
4
4
name = "qtsensors";
5
5
qtInputs = [ qtbase qtdeclarative ];
6
6
-
postFixup = ''
7
7
-
fixQtModuleCMakeConfig "Sensors"
8
8
-
'';
9
6
}
-3
pkgs/development/libraries/qt-5/5.6/qtserialport/default.nix
···
9
9
libudev = libudev.out;
10
10
})
11
11
];
12
12
-
postFixup = ''
13
13
-
fixQtModuleCMakeConfig "SerialPort"
14
14
-
'';
15
12
}
-3
pkgs/development/libraries/qt-5/5.6/qtsvg.nix
···
3
3
qtSubmodule {
4
4
name = "qtsvg";
5
5
qtInputs = [ qtbase ];
6
6
-
postFixup = ''
7
7
-
fixQtModuleCMakeConfig "Svg"
8
8
-
'';
9
6
}
-6
pkgs/development/libraries/qt-5/5.6/qttools.nix
···
6
6
postFixup = ''
7
7
moveToOutput "bin/qdbus" "$out"
8
8
moveToOutput "bin/qtpaths" "$out"
9
9
-
10
10
-
fixQtModuleCMakeConfig "Designer"
11
11
-
fixQtModuleCMakeConfig "Help"
12
12
-
fixQtModuleCMakeConfig "LinguistTools"
13
13
-
fixQtModuleCMakeConfig "UiPlugin"
14
14
-
fixQtModuleCMakeConfig "UiTools"
15
9
'';
16
10
}
-3
pkgs/development/libraries/qt-5/5.6/qtwebsockets.nix
···
3
3
qtSubmodule {
4
4
name = "qtwebsockets";
5
5
qtInputs = [ qtbase qtdeclarative ];
6
6
-
postFixup = ''
7
7
-
fixQtModuleCMakeConfig "WebSockets"
8
8
-
'';
9
6
}
-3
pkgs/development/libraries/qt-5/5.6/qtx11extras.nix
···
3
3
qtSubmodule {
4
4
name = "qtx11extras";
5
5
qtInputs = [ qtbase ];
6
6
-
postFixup = ''
7
7
-
fixQtModuleCMakeConfig "X11Extras"
8
8
-
'';
9
6
}
-3
pkgs/development/libraries/qt-5/5.6/qtxmlpatterns.nix
···
3
3
qtSubmodule {
4
4
name = "qtxmlpatterns";
5
5
qtInputs = [ qtbase ];
6
6
-
postFixup = ''
7
7
-
fixQtModuleCMakeConfig "XmlPatterns"
8
8
-
'';
9
6
}