I am wanting to ship an app which involves a Perl Code Generation Server that I call from Objective C and visa versa using Distributed Objects. The bridge comes with recent versions of MacOSX, and works fine - but so far I can't get it to work if I just do a 'make all', (I need to do a 'make install' as well).
note: All this just to use XSUB
The gotcha is that in order to do the 'make install' I have to have Admin rights, but I don't want my users to have to login as an admin to install this app. Below is a description of my experience (using 'Project Builder IDE') I got around some path problems by using getcwd to add an element to @INC, but there is another path/location problem to address...
I tried this:
.. after reboot, compiled AddSystemDO.app
.. ran it, and it crashed as expected in addServer.pm on the line "use AddSystem;"
.. I did the "make install" as root
.. and with the app still running, tried launching the server - it worked;
.. as root, undid the install by removing the files written during install;
.. and with the app still running, tried launching the server, and it crashed as before.
Note that app is smart enough to know whether the server launched or not.
When it launches successfully, the "Launch" button becomes "Terminate".
No need to reboot.
Just need to remove all the installed files.
Quod erat demonstrandum:
root# make install
Installing /Library/Perl/darwin/auto/AddSystem/AddSystem.bs
Installing /Library/Perl/darwin/auto/AddSystem/AddSystem.bundle
Files found in blib/arch: installing files in blib/lib into architecture dependent library tree
Installing /Library/Perl/darwin/addClient.pm
Installing /Library/Perl/darwin/addServer.pm
Installing /Library/Perl/darwin/AddSystem.pm
Writing /Library/Perl/darwin/auto/AddSystem/.packlist
Appending installation info to /System/Library/Perl/darwin/perllocal.pod
And the server launches sucessfully.
root# make uninstall
unlink /Library/Perl/darwin/AddSystem.pm
unlink /Library/Perl/darwin/addClient.pm
unlink /Library/Perl/darwin/addServer.pm
unlink /Library/Perl/darwin/auto/AddSystem/AddSystem.bs
unlink /Library/Perl/darwin/auto/AddSystem/AddSystem.bundle
unlink /Library/Perl/darwin/auto/AddSystem/.packlist
Uninstall is deprecated. Please check the packlist above carefully.
There may be errors. Remove the appropriate files manually.
Sorry for the inconveniences.
And the server STILL launches sucessfully.
root# rm /Library/Perl/darwin/AddSystem.pm
root# rm /Library/Perl/darwin/addClient.pm
root# rm /Library/Perl/darwin/addServer.pm
root# rm -rf /Library/Perl/darwin/auto/AddSystem
root#
Ha! Now it fails as expected.