File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -120,7 +120,17 @@ build_installer_image() {
120120
121121 # Build installer image
122122
123- create-dmg \
123+ # When this script is run on Github's CI with CodeQL enabled, CodeQL adds dynamic library
124+ # shims via environment variables, so that it can monitor the compilation of code.
125+ # In order for these settings to propagate to compilation called via shell/bash scripts,
126+ # the CodeQL libs seem automatically to create the same environment variables in sub-shells,
127+ # even when called via 'env'. This was determined by experimentation.
128+ # Unfortunately, the CodeQL libraries are not compatible with the hdiutil program called
129+ # by create-dmg. In order to prevent the automatic propagation of the environment, we use
130+ # sudo to the same user in order to invoke create-dmg with a guaranteed clean environment.
131+ #
132+ # /System/Library/PrivateFrameworks/DiskImages.framework/Resources/diskimages-helper.
133+ sudo -u " $USER " create-dmg \
124134 --volname " ${client_target_name} Installer" \
125135 --background " ${resources_path} /installerbackground.png" \
126136 --window-pos 200 400 \
You can’t perform that action at this time.
0 commit comments