summaryrefslogtreecommitdiff
path: root/pkg/osx
diff options
context:
space:
mode:
authorkali <kali@leap.se>2013-01-11 09:16:49 +0900
committerkali <kali@leap.se>2013-01-11 09:17:54 +0900
commitade0eded09176fd687d1ee30724468c048d15065 (patch)
treea6a3c196dd8a41c6360d47f38af3820c4820a68b /pkg/osx
parentf2660941cf01a25a36058ab25cae45cea2c062d3 (diff)
fix for missing cacert bundle
frozen app cannot find requests cacert bundle. added to Resources to get us going.
Diffstat (limited to 'pkg/osx')
-rw-r--r--pkg/osx/Makefile33
-rwxr-xr-xpkg/osx/install/install-leapc.sh2
-rw-r--r--pkg/osx/leap-client.spec5
3 files changed, 24 insertions, 16 deletions
diff --git a/pkg/osx/Makefile b/pkg/osx/Makefile
index b302fa31..f2520fcf 100644
--- a/pkg/osx/Makefile
+++ b/pkg/osx/Makefile
@@ -1,6 +1,10 @@
#WARNING: You need to run this with an activated VIRTUALENV.
OSX = dist/LEAP\ Client.app/Contents/MacOS/
+GITC = `git rev-parse --short HEAD`
+DMG = "dist/leap-client-$(GITC).dmg"
+INST = "dist/LEAP Client installer.app"
+INSTR = "dist/LEAP Client installer.app/Contents/Resources"
pkg : dist trim installer dmg
@@ -16,28 +20,27 @@ trim:
installer:
#XXX need to fix some paths there (binary, etc)
- platypus -P install/leap-installer.platypus -y dist/LEAPClient_installer.app
+ platypus -P install/leap-installer.platypus -y $(INST)
#XXX should build tuntap extensions ourselves
- mkdir "dist/LEAPClient_installer.app/Contents/Resources/StartupItems"
- mkdir "dist/LEAPClient_installer.app/Contents/Resources/Extensions/"
- cp -r /opt/local/Library/StartupItems/tun "dist/LEAPClient_installer.app/Contents/Resources/StartupItems/"
- cp -r /opt/local/Library/StartupItems/tap "dist/LEAPClient_installer.app/Contents/Resources/StartupItems/"
- cp -r /opt/local/Library/Extensions/tun.kext "dist/LEAPClient_installer.app/Contents/Resources/Extensions/"
- cp -r /opt/local/Library/Extensions/tap.kext "dist/LEAPClient_installer.app/Contents/Resources/Extensions/"
+ mkdir $(INSTR)/StartupItems
+ mkdir $(INSTR)/Extensions
+ cp -r /opt/local/Library/StartupItems/tun $(INSTR)/StartupItems
+ cp -r /opt/local/Library/StartupItems/tap $(INSTR)/StartupItems
+ cp -r /opt/local/Library/Extensions/tun.kext $(INSTR)/Extensions
+ cp -r /opt/local/Library/Extensions/tap.kext $(INSTR)/Extensions
#copy the binary that we have previously built
#XXX not building it yet...
- cp ../../openvpn/build/openvpn.leap "dist/LEAPClient_installer.app/Contents/Resources/"
+ cp ../../openvpn/build/openvpn.leap $(INSTR)
#copy startup scripts
- cp install/client.up.sh "dist/LEAP Client.app/Contents/Resources"
- cp install/client.down.sh "dist/LEAP Client.app/Contents/Resources"
- cp install/ProcessNetworkChanges.plist.template "dist/LEAP Client.app/Contents/Resources"
+ cp install/client.up.sh $(INSTR)
+ cp install/client.down.sh $(INSTR)
+ cp install/ProcessNetworkChanges.plist.template $(INSTR)
#Finally, copy application bundle...
- cp -r "dist/LEAP Client.app" "dist/LEAPClient_installer.app/Contents/Resources/"
+ cp -r "dist/LEAP Client.app" $(INSTR)
dmg :
- #TODO: remove if already present
- #rm dist/LEAPClient.dmg
- hdiutil create -format UDBZ -srcfolder "dist/LEAPClient_installer.app/" "dist/LEAP Client Installer.dmg"
+ rm -f $(DMG)
+ hdiutil create -format UDBZ -srcfolder $(INST) $(DMG)
clean :
rm -rf dist/ build/
diff --git a/pkg/osx/install/install-leapc.sh b/pkg/osx/install/install-leapc.sh
index d47b8f45..7a0d3a5e 100755
--- a/pkg/osx/install/install-leapc.sh
+++ b/pkg/osx/install/install-leapc.sh
@@ -14,3 +14,5 @@ echo "Loading tun/tap kernel extension"
/Library/StartupItems/tun/tun start
echo "Installation Finished!"
+
+open /Applications/LEAP\ Client.app/
diff --git a/pkg/osx/leap-client.spec b/pkg/osx/leap-client.spec
index 4a34bb7c..04f45253 100644
--- a/pkg/osx/leap-client.spec
+++ b/pkg/osx/leap-client.spec
@@ -15,7 +15,10 @@ exe = EXE(pyz,
upx=True,
console=False)
coll = COLLECT(exe,
- a.binaries,
+ a.binaries +
+ # this will easitly break if we setup the venv
+ # somewhere else. FIXME
+ [('cacert.pem', '../../../../lib/python2.6/site-packages/requests/cacert.pem', 'DATA')],
a.zipfiles,
a.datas,
strip=True,