Don't hardcode paths for Windows-specific targets
authorSam Thursfield <sam.thursfield@codethink.co.uk>
Mon, 28 Nov 2011 14:57:38 +0000 (14:57 +0000)
committerSam Thursfield <sam.thursfield@codethink.co.uk>
Mon, 28 Nov 2011 14:57:38 +0000 (14:57 +0000)
Icons etc. are now expected to be located inside the install prefix,
instead of the hardcoded path c:/build

Makefile.am
README.windows

index f06fe4b..ead78f4 100644 (file)
@@ -176,15 +176,15 @@ if OS_WIN32
 ## A couple of Windows-specific targets:
 
 ## 1. Icons. You must have gnome-icon-theme and gnome-icon-theme-symbolic installed
-##    in c:/build prefix; and ImageMagick installed in c:/tools/ImageMagick. This
+##    in the install prefix; and ImageMagick installed in c:/tools/ImageMagick. This
 ##    pulls in the icons required by moonshot and converts svg's to png's (we have
 ##    no svg support built in to Windows Gtk+ right now).
 
 icons:
        mkdir -p share/icons
-       cp c:/build/share/icons/gnome/48x48/status/avatar-default.png share/icons
-       "${IMAGEMAGICK_CONVERT}" -background none c:/build/share/icons/gnome/scalable/actions/edit-clear-symbolic.svg -size 13x13 share/icons/edit-clear-symbolic.png
-       "${IMAGEMAGICK_CONVERT}" -background none c:/build/share/icons/gnome/scalable/actions/edit-find-symbolic.svg -size 13x13 share/icons/edit-find-symbolic.png
+       cp ${prefix}/share/icons/gnome/48x48/status/avatar-default.png share/icons
+       "${IMAGEMAGICK_CONVERT}" -background none ${prefix}/share/icons/gnome/scalable/actions/edit-clear-symbolic.svg -size 13x13 share/icons/edit-clear-symbolic.png
+       "${IMAGEMAGICK_CONVERT}" -background none ${prefix}/share/icons/gnome/scalable/actions/edit-find-symbolic.svg -size 13x13 share/icons/edit-find-symbolic.png
 
 
 ## 2. Installer. You must have the Windows Installer XML toolkit version 3.5
@@ -197,6 +197,6 @@ installer: moonshot.msi
 
 moonshot.msi: windows/app.wxs windows/config.wxi $(bin_PROGRAMS)
        "${WIX_CANDLE}" $<
-       "${WIX_LIGHT}" -b c:/build -b c:/tools/mingw -o moonshot.msi app.wixobj
+       "${WIX_LIGHT}" -b ${prefix} -b ${prefix}/mingw -o moonshot.msi app.wixobj
 
 endif
index be07d63..86cd636 100644 (file)
@@ -59,7 +59,7 @@ MIDL.EXE and the RPC API to make it usable from gcc.
 You can then configure moonshot from the MSYS shell:
 
   ACLOCAL="aclocal -I/c/build/share/aclocal" PKG_CONFIG_PATH=/c/build/lib/pkgconfig \
-    ./autogen.sh --disable-maintainer-mode
+    ./autogen.sh --disable-maintainer-mode --prefix=/c/build
 
 The configure script looks for various tools that it may not be able to locate
 automatically. In these cases you will get an error message, and you can set the
@@ -76,6 +76,9 @@ If this succeeds, you're ready to build!
   make icons
   make installer
 
+The icons and installer targets make a few assumptions based on the install
+prefix. You may have to edit Makefile.am to edit the paths if you haven't
+followed the instructions exactly.
 
 Weird things that might go wrong
 --------------------------------