Fixing a few bugs
Change-Id: Ibc65ad1d41fca4a6244b246cd30428965f707227
diff --git a/make-deps.sh b/make-deps.sh
index d47e7a0..6a353e7 100755
--- a/make-deps.sh
+++ b/make-deps.sh
@@ -26,28 +26,22 @@
patch -p1 <<EOF
diff --git a/src/transport/unix-transport.cpp b/src/transport/unix-transport.cpp
-index 59c00ae..aa67b24 100644
+index 6b86a34..e72170e 100644
--- a/src/transport/unix-transport.cpp
+++ b/src/transport/unix-transport.cpp
-@@ -74,7 +74,7 @@ UnixTransport::getDefaultSocketName(const ConfigFile& config)
+@@ -72,7 +72,7 @@ UnixTransport::getDefaultSocketName(const ConfigFile& config)
}
-
+
// Assume the default nfd.sock location.
- return "/var/run/nfd.sock";
+ return "/tmp/nfd.sock";
}
-
+
shared_ptr<UnixTransport>
-@@ -135,4 +135,4 @@ UnixTransport::resume()
-
- }
-
--#endif // _WIN32
-\ No newline at end of file
-+#endif // _WIN32
EOF
-./waf configure --prefix="${path}/build/deps"
+./waf configure --prefix="${path}/build/deps" \
+ --sysconfdir="/Applications/NDN.app/Contents/etc"
./waf build
./waf install
popd
@@ -60,7 +54,8 @@
git checkout ${NFD_COMMIT}
git submodule update --init
PKG_CONFIG_PATH="${path}/build/deps/lib/pkgconfig:${PKG_CONFIG_PATH}" \
- ./waf configure --prefix="${path}/build/deps"
+ ./waf configure --prefix="${path}/build/deps" \
+ --sysconfdir="/Applications/NDN.app/Contents/etc"
./waf build
./waf install
popd
diff --git a/make-osx-bundle.py b/make-osx-bundle.py
index 3ce189d..91a578b 100755
--- a/make-osx-bundle.py
+++ b/make-osx-bundle.py
@@ -226,9 +226,9 @@
Copy needed config files into our bundle.
'''
print ' * Copying needed config files'
- rsrcpath = os.path.join(self.bundle, 'Contents', 'etc')
+ rsrcpath = os.path.join(self.bundle, 'Contents', 'etc', 'ndn')
if not os.path.exists(rsrcpath):
- os.mkdir(rsrcpath)
+ os.makedirs(rsrcpath)
# Copy resources already in the bundle
for rsrc in rsrcs:
diff --git a/res/ndn b/res/ndn
index ec05781..3cdef2e 100755
--- a/res/ndn
+++ b/res/ndn
@@ -4,7 +4,7 @@
echo ERROR: No command specified
echo
echo Available commands:
- for command in $(ls /Applications/NDN.app/Contents/Resources/platform/bin/ 2>/dev/null); do
+ for command in $(ls /Applications/NDN.app/Contents/Platform/ 2>/dev/null); do
echo " $command"
done
exit 1
diff --git a/src/Info.plist b/src/Info.plist
index e0f91da..40eda16 100644
--- a/src/Info.plist
+++ b/src/Info.plist
@@ -19,11 +19,11 @@
<key>CFBundleSignature</key>
<string>????</string>
<key>CFBundleShortVersionString</key>
- <string>0.1.0</string>
+ <string>0.1.1</string>
<key>LSMinimumSystemVersion</key>
<string>10.6</string>
<key>CFBundleVersion</key>
- <string>0.1.0</string>
+ <string>0.1.1</string>
<key>NSMainNibFile</key>
<string>MainMenu</string>
<key>NSPrincipalClass</key>
diff --git a/src/tray-menu.cpp b/src/tray-menu.cpp
index 01c1f60..9cc38d7 100644
--- a/src/tray-menu.cpp
+++ b/src/tray-menu.cpp
@@ -137,7 +137,7 @@
proc->startDetached((QCoreApplication::applicationDirPath().toStdString() + "/../Platform/nfd").c_str(),
QStringList()
<< "--config"
- << (QCoreApplication::applicationDirPath().toStdString() + "/../etc/nfd.conf").c_str());
+ << (QCoreApplication::applicationDirPath().toStdString() + "/../etc/ndn/nfd.conf").c_str());
// #endif
// QProcess * proc = new QProcess();
// connect(proc, SIGNAL(finished(int)), proc, SLOT(deleteLater()));
@@ -234,7 +234,7 @@
mkdir,
kAuthorizationFlagDefaults, (char**)mkdir_arg, nullptr);
- std::vector<std::string> arguments = { "-f",
+ std::vector<std::string> arguments = { "-f", "-s",
QCoreApplication::applicationDirPath().toStdString() + "/../Resources/ndn",
"/usr/local/bin/ndn" };
std::vector<const char*> args;