unixorn / luggage Goto Github PK
View Code? Open in Web Editor NEWProject to automate OS X package creation without using the packagemaker GUI
Home Page: https://github.com/unixorn/luggage/wiki
Project to automate OS X package creation without using the packagemaker GUI
Home Page: https://github.com/unixorn/luggage/wiki
The Luggage is a project to create a wrapper to make Apple PKG format packages. It does not use the PackageMaker GUI, but it does require that the developer tools be installed so it can call the command line version. Advantages: You can get peer review of a package by examining the diffs between versions of your Makefile. No more wading through a zillion annoying GUI panes. Full documentation can be found at https://github.com/unixorn/luggage/wiki Example packages can be found at https://github.com/unixorn/luggage-examples Note : This version adds a command line option to remove the application prior to installation (app2luggage.rb).
i'm probably missing something here, but i'm getting incorrect group ownership on /private/var/db for an example here. the pkg builds and installs fine, but the os is picky about ownership here. i don't see any lines in luggage.make that set ownership to root:admin for this path, yet they are at build time. example:
this makefile drops admin account and group plists under dslocal: https://gist.github.com/1676696
ownership looks fine to me in the makefile. it matches what's on disk.
building results in this:
Warning: Group ID 80 does not match 0 of root volume for "/private". Make sure to have disk permissions repaired with Disk Utility.
Warning: Group ID 80 does not match 0 of root volume for "/private/var". Make sure to have disk permissions repaired with Disk Utility.
Warning: Group ID 80 does not match 0 of root volume for "/private/var/db". Make sure to have disk permissions repaired with Disk Utility.
ownership under pkgroot confirms this. i don't see where this ownership gets set. i'm using the latest luggage pulled straight from the repo.
any ideas?
it's an issue because it causes stalls or just plain failure to boot without fixing the ownership on a newly imaged box.
Right now it is impossible to add a description to your package.
i have a simple makefile that installs an app bundle and packs a postflight script. what i'm seeing when run on my build machine is stuff like this:
Sep 5 20:57:46 derwin installer[2238]: Applications/TSP_Managed_Mac.app relocated to tmp/the_luggage/TSP_Managed_Mac.app-1.0.7/root/Applications/TSP_Managed_Mac.app
Sep 5 20:57:46 derwin installer[2238]: PackageKit: Shoving /var/folders/zz/zzzivhrRnAmviuee+++++++++++/Cleanup At Startup/PKInstallSandbox-tmp/Root (2 items) to /
any idea why the installer would dump the app back to the tmp root location? i also had a previous build dump the app in /Applications/Utilities/Waterroof.app, even though that's not specified anywhere.
the relevant lines from the makefile look like this: http://pastie.textmate.org/private/aucexsivlobbf5p8ms6ywa
the payload is a tar.bz2 archive.
thanks for all your work.
When trying to create a package on 10.9.5 for Prizmo 2 with the command line
sudo app2luggage.rb --application "/Applications/Prizmo.app" --package-id "Prizmo 2" --reverse-domain com.creaceed.prizmo2
I get
/System/Library/Frameworks/Ruby.framework/Versions/2.0/usr/lib/ruby/2.0.0/rubygems/core_ext/kernel_require.rb:55:in `require': cannot load such file -- ftools (LoadError)
from /System/Library/Frameworks/Ruby.framework/Versions/2.0/usr/lib/ruby/2.0.0/rubygems/core_ext/kernel_require.rb:55:in `require'
from /usr/local/bin/app2luggage.rb:30:in `<main>'
Thanks!
It's been several XCode releases since packagemaker was replaced by pkgbuild, and having to set USE_PKGBUILD before anything works is an unnecessary hurdle for new users.
When I run “make bootstrap_files” as directed by the Luggage wiki, I get the following warnings. I haven’t looked into the makefile but I don’t believe the man pages are being processed. However, I do believe that luggage.make and prototype.plist are handled as per the description on the wiki.
$ make bootstrap_files
Makefile:25: warning: overriding commands for target `help'
luggage.make:120: warning: ignoring old commands for target `help'
Since my new machine didn't have a /usr/local/bin directory,
make bootstrap_files
failed on the app2luggage.rb line. I'll throw a pull request together shortly. Thanks!
Now, in addition to going to Xcode's Preferences/Downloads tab to get make and other command line tools, you need to go to https://developer.apple.com/downloads/ and get auxiliary_tools_for_xcode(this link only works while logged in to a Dev account) for packagemaker. Then you'll still want to edit your packagemaker variable in luggage.make to point to the one in the standalone PackageMaker.app bundle. I put it in Utilities, and changed line 52 to
PACKAGEMAKER=/Applications/Utilities/PackageMaker.app/Contents/MacOS/PackageMaker
An app2luggage-generated Makefile creates a target, install-app2luggage-Application_Name.app, that calls the shell command /usr/bin/tar instead of referencing ${TAR}.
This should probably be changed to use ${TAR} instead, as it is one of the commands set up in luggage.make. This would make app2luggage Makefiles consistent with examples and existing practices.
I tried quoting and backslashes, but nothing lets me build an unbz2-applications-Foo Bar.app with spaces in the app name.
We install our added on software in /local rather than /usr/local. Some sites might prefer /opt. It would be nice if luggage defined its home in a (Makefile or environment) variable rather than forcing it to be /usr/local/share/luggage.
I was getting errors trying to push man pages in man5 and man8 when re-wrapping puppet,
install: l_usr_man_man5: No such file or directory
make[2]: *** [pack-man5-puppet.conf.5.gz] Error 71
Tweaks I made may have uncovered things that were overlooked, but I can't be sure as I don't fully understand all of the inner workings.
These are the three things I changed which cleared my errors:
I've posted a pastie(for now) which incorporates certain changes from glarizza's huronschools fork: http://pastie.org/private/5yfoburcof0a5r5comjwa
I have an application that is a directory with many directories and the app inside of the parent directory
ex.
/Applications/MacVector/Templates
/Applications/MacVector/MacVector.app
/Applications/MacVector/Tutorials
I need to pack /Applications/MacVector. I have the MacVector directory in the same directory as my make file. When I make the package, I get "chmod: /tmp/the_luggage/MacVector-20150510/root/Applications/MacVector: No such file or directory". I got the same issue when I tar the package as well and use unbz2-applications-MacVector to install it.
For some reason /tmp/the_luggage/MacVector-20150510/root/Applications is being overwritten with the MacVector folder instead of the MacVector folder going inside of it.
Here's my makefile. I made my own rule instead of using unbz2-applications-... because I am trying to learn. I get the same error with both methods anyways.
TITLE=MacVector
REVERSE_DOMAIN=com.osuccc
PAYLOAD=pack-MacVector
pack-MacVector:
@sudo ${CP} -r ./MacVector/ ${WORK_D}/Applications/
@sudo chmod 755 ${WORK_D}/Applications/MacVector
@sudo chown root:admin ${WORK_D}/Applications/MacVector
I've been asked to ensure that my current Mac related projects are fully documented, so I figured rather than writing "start to finish" documentation on our internal wiki, I would update the wiki here on github.
I was hoping you guys could take a look at https://github.com/n8felton/luggage/wiki/Gettings-Started and let me know what you think about what I have so far. I would like to eventually see the wiki I build to be pull down to the main repo if approved.
I am wondering about the best practice for installing applications to /Applications when those apps have spaces in their names. I know from experience last spring that Make is somewhere between finicky and hostile about spaces. Unfortunately, a number of items I’m packaging have them.
The standard unbz2-applications-% recipe doesn’t work with spaces in the name of the .app -- “Firstword Secondword.app.” Tried “Firstword Secondword.app” and “Firstword\ Secondword.app” in the recipe, results are either:
make[2]: *** No rule to make target `unbz2-applications-Firstword'. Stop.
make[1]: *** [payload] Error 2
or
make[2]: *** No rule to make target `unbz2-applications-Firstword Secondword.app'. Stop.
make[1]: *** [payload] Error 2
I have also had difficulty with removing the space from the tar archive name (when the actual contents, consisting of “Firstword Secondword.app” have not changed but the Makefile was adjusted):
chown: /tmp/the_luggage/Firstword Secondword/root/Applications/FirstwordSecondwordapp.app: No such file or directory
make[2]: *** [unbz2-applications-FirstwordSecondword.app] Error 1
I notice that app2luggage dodges around this by not using unbz2-applications-% and instead constructing install-app2luggage-Firstword_Secondword.app.
I’d rather not have to come up with my own target for every affected application. Relying on unbz2-applications-% is preferable because it’s built-in, debugged, used by everyone, and less likely I’ll generate new errors of my own. But, if that’s the best way, I will.
After looking through the wiki documentation page, it looks like this doesn't support Installer plugins. Does it, and I just missed it? If not, do you have any plans to include support for them?
The current documentation link in readme is invalid: http://wiki.github.com/unixorn/luggage/
The actual link to the wiki is: https://github.com/unixorn/luggage/wiki
Tiny, but in case you had not noticed.
A declarative, efficient, and flexible JavaScript library for building user interfaces.
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google ❤️ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.