Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Help needed: hdiutil udifrez is deprecated by Apple but is needed by dmg-license #11

Open
argv-minus-one opened this issue Nov 26, 2021 · 10 comments

Comments

@argv-minus-one
Copy link
Owner

argv-minus-one commented Nov 26, 2021

As of macOS 12, the hdiutil udifrez command, used by dmg-license, is deprecated.

Deprecation by Apple is not an empty threat. They will most likely remove this command in the future even though it's still being used. They already did that with the older hdiutil flatten command.

I'm not aware of any other way to attach resources, such as a license agreement, to a UDIF image. A Google search on the subject yields nothing helpful.

If anyone knows of some other, non-deprecated way to attach resources to a UDIF image, please add a comment to this issue and let me know. Otherwise, when Apple removes hdiutil udifrez, dmg-license will no longer work.

See also a discussion about this issue at the CMake project.

@Bug-Reaper
Copy link

Yikes, got linked here from an NPM install. Thanks for the heads up and sorry to hear about this -- will report back if I find anything helpful.

@AbdeenM
Copy link

AbdeenM commented Mar 17, 2022

+1

@gavinwyf
Copy link

+1

1 similar comment
@TymekV
Copy link

TymekV commented Apr 25, 2022

+1

@lutzroeder
Copy link

@argv-minus-one is this error specific to writePlistToDmg? Trying to understand why electron-builder shows this deprecation warning during npm install when the build pipeline isn't invoking this command.

@aleelock
Copy link

dmg-license has bean removed: https://www.npmjs.com/package/dmg-license, which is in the dependencies list of dmg-builder.

@argv-minus-one
Copy link
Owner Author

@lutzroeder Technically yes, but dmg-license wouldn't work without it. writePlistToDmg is what actually attaches a prepared license agreement (in Apple property list format) to a disk image.

You're getting a deprecation warning because electron-builder depends on dmg-license, and dmg-license is likely to stop working on a future version of macOS. If your electron-builder configuration doesn't actually attach a license agreement to a disk image, then you can safely ignore the warning.

@aleelock It hasn't been removed, just deprecated. I'm not planning to remove it. Deprecation is meant to warn people that dmg-license is going to stop working in the future, and anyone who's still using it should implement another solution as soon as possible.

@argv-minus-one
Copy link
Owner Author

Because of electron-userland/electron-builder#6671, I've decided to un-deprecate dmg-license.

I don't like it, as people really need to stop using it ASAP and that was the best way I could think of to make that happen, but if it drives people to inline this whole package just to get rid of the warning, then that's not good either.

I plan to add a run-time deprecation warning instead, but I fear it won't be seen by nearly as many people, who'll then get the rug pulled out from under their feet when Apple removes disk image license support entirely. If anyone has a better idea, please let me know.

@lutzroeder
Copy link

lutzroeder commented Jul 4, 2022

@argv-minus-one what about adding an error (instead of a warning) that requires specific action (like setting an environment variable) to turn into a warning? Would that raise awareness with folks who depend on this?

@argv-minus-one
Copy link
Owner Author

@lutzroeder I don't think that would be wise. People got really upset over a harmless deprecation message, so I can only imagine how upset they'd get if I broke their builds like you suggest.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

7 participants