1 ## Process this file with automake to produce Makefile.in
3 ACLOCAL_AMFLAGS = -I m4
5 SUBDIRS = . lib src doc tests
7 # We never want to implicitly recurse into the vim subdirectory, but we still
8 # want to distribute the files there.
9 DIST_SUBDIRS = $(SUBDIRS) vim
11 EXTRA_DIST = TODO OLDNEWS\
12 desc.txt desc-aven.txt survex.spec\
15 extra_bin = lib/*.msg\
18 extra_files = $(extra_bin) $(extra_txt)
20 # FIXME: need to keep in step with bin_PROGRAMS in src/Makefile.am
21 mingw_progs = cavern diffpos dump3d extend sorterr survexport aven
23 AUTHORS: doc/AUTHORS.htm
24 w3m -dump doc/AUTHORS.htm > AUTHORS
26 HACKING: doc/HACKING.htm
27 w3m -dump doc/HACKING.htm > HACKING
30 w3m -dump doc/TODO.htm > TODO
32 # Create Aven.app for macOS - run as e.g.:
33 # make create-aven-app APP_PATH=Aven.app
35 mkdir -p '$(APP_PATH)/Contents/MacOS' '$(APP_PATH)/Contents/Resources'
36 cp lib/Info.plist '$(APP_PATH)/Contents'
37 printf APPLAVEN > '$(APP_PATH)/Contents/PkgInfo'
38 for zip in lib/icons/*.iconset.zip ; do \
40 unzip -d '$(APP_PATH)/Contents/Resources' "$$zip"; \
41 i=`echo "$$zip"|sed 's!.*/\(.*\)\.zip$$!\1!'`; \
42 iconutil --convert icns '$(APP_PATH)/Contents/Resources/'"$$i"; \
43 rm -rf '$(APP_PATH)/Contents/Resources/'"$i"; \
48 mingw_iss : survex.iss
51 cp $(extra_txt) survex.iss iss_tmp
52 : # so the installer can display the license
53 cp COPYING iss_tmp/COPYING.txt
54 cd doc && cp @HTMLFILES@ ../iss_tmp
55 : # convert LF to CR+LF
56 perl -p -i -e 's/\n/\r\n/' iss_tmp/*
57 for f in $(mingw_progs) ; do cp src/$$f.exe iss_tmp ; done
58 cp lib/icons/*.ico lib/images/*.png iss_tmp
59 : # not needed if we build wx without threads: gzip -dc /usr/share/doc/mingw32-runtime/mingwm10.dll.gz > iss_tmp/mingwm10.dll
61 cp doc/manual/*.htm iss_tmp/manual
62 : # convert LF to CR+LF
63 perl -p -i -e 's/\n/\r\n/' iss_tmp/manual/*
64 cp doc/manual/*.png iss_tmp/manual
65 cp $(extra_bin) iss_tmp
66 for f in "`$(WX_CONFIG) --prefix`"/share/locale/*/LC_MESSAGES/wxstd.mo ; do \
67 a=`echo "$$f"|sed 's!^.*/\([^/]*\)/LC_MESSAGES/wxstd\.mo$!\1!'`; \
69 cp "$$f" iss_tmp/$$a; \
70 echo 'Source: "'"$$a"'\wxstd.mo"; DestDir: "{app}\'"$$a"'"' ; \
71 done > iss_tmp/i18nfiles.iss
74 cp -p /usr/${host}/share/proj/epsg /usr/${host}/share/proj/esri iss_tmp/proj
75 : # Also need to reduce colour depth it appears:
76 : # src/png2bmp lib/icons/aven_about.png iss_tmp/logo.bmp
77 DISPLAY= wine "c:/Program Files/Inno Setup 5/ISCC.exe" iss_tmp/survex.iss
78 mv iss_tmp/Output/*.exe .
81 .PHONY: mingw mingw_iss