]> git.sesse.net Git - vlc/blob - Makefile.am
Dionoea: here is "make core", your portable "make vlc" replacement
[vlc] / Makefile.am
1 ###############################################################################
2 # Automake targets and declarations
3 ###############################################################################
4
5 NULL =
6
7 # SUBDIRS stores the directories where a "make" is required when building
8 # something. DIST_SUBDIRS stores the directories where nothing is built but
9 # which have makefiles with distribution information.
10 #  - intl should come before modules and . because all the code uses gettext
11 #  - modules should come before . because vlc needs the builtins
12 #  - . should come before mozilla/bindings because the plugin needs libvlc_pic.a
13 #  - po should come before . because VLC.app needs the pofiles
14 #  - loader should come before modules because some plugins need it
15 SUBDIRS = intl loader src modules po . mozilla bindings activex share m4 doc
16 DIST_SUBDIRS = $(SUBDIRS) debian ipkg
17
18 EXTRA_DIST = \
19         HACKING \
20         INSTALL.win32 \
21         INSTALL.wince \
22         vlc.exe.manifest \
23         MAINTAINERS \
24         README.MacOSX.rtf \
25         bootstrap \
26         toolbox \
27         vlc-api.pl \
28         vlc-config.in.in \
29         vlc.spec \
30         vlc.spec.mdk \
31         vlc.win32.nsi \
32         $(NULL)
33
34 BUILT_SOURCES_distclean = vlc-config compile
35 BUILT_SOURCES_clean = macosx-sdk
36
37 BUILT_SOURCES = $(BUILT_SOURCES_distclean) $(BUILT_SOURCES_clean)
38
39 SUFFIXES = 
40
41 DISTCHECK_CONFIGURE_FLAGS = --disable-dvd --disable-mad --disable-libmpeg2 \
42         --disable-ffmpeg --disable-faad --disable-skins2
43
44 # Tell aclocal to use -I m4. Wonder if it really works.
45 ACLOCAL_AMFLAGS = -I m4
46
47 # XXX: these flags could be set in configure.ac, but we set them here
48 # because old versions of automake don't support them in configure.ac.
49 AUTOMAKE_OPTIONS = dist-bzip2 subdir-objects
50
51 ###############################################################################
52 # MacOS X project
53 ###############################################################################
54
55 EXTRA_DIST += \
56         extras/MacOSX/Resources/English.lproj/MainMenu.nib/classes.nib \
57         extras/MacOSX/Resources/English.lproj/MainMenu.nib/info.nib \
58         extras/MacOSX/Resources/English.lproj/MainMenu.nib/keyedobjects.nib \
59         extras/MacOSX/Resources/English.lproj/About.nib/classes.nib \
60         extras/MacOSX/Resources/English.lproj/About.nib/info.nib \
61         extras/MacOSX/Resources/English.lproj/About.nib/keyedobjects.nib \
62         extras/MacOSX/Resources/English.lproj/Open.nib/classes.nib \
63         extras/MacOSX/Resources/English.lproj/Open.nib/info.nib \
64         extras/MacOSX/Resources/English.lproj/Open.nib/keyedobjects.nib \
65         extras/MacOSX/Resources/English.lproj/Preferences.nib/classes.nib \
66         extras/MacOSX/Resources/English.lproj/Preferences.nib/info.nib \
67         extras/MacOSX/Resources/English.lproj/Preferences.nib/keyedobjects.nib \
68         extras/MacOSX/Resources/English.lproj/Wizard.nib/classes.nib \
69         extras/MacOSX/Resources/English.lproj/Wizard.nib/info.nib \
70         extras/MacOSX/Resources/English.lproj/Wizard.nib/keyedobjects.nib \
71         extras/MacOSX/Resources/English.lproj/Bookmarks.nib/classes.nib \
72         extras/MacOSX/Resources/English.lproj/Bookmarks.nib/info.nib \
73         extras/MacOSX/Resources/English.lproj/Bookmarks.nib/keyedobjects.nib \
74         extras/MacOSX/Resources/English.lproj/Extended.nib/classes.nib \
75         extras/MacOSX/Resources/English.lproj/Extended.nib/info.nib \
76         extras/MacOSX/Resources/English.lproj/Extended.nib/keyedobjects.nib \
77         extras/MacOSX/Resources/English.lproj/SFilters.nib/classes.nib \
78         extras/MacOSX/Resources/English.lproj/SFilters.nib/info.nib \
79         extras/MacOSX/Resources/English.lproj/SFilters.nib/keyedobjects.nib \
80         extras/MacOSX/Resources/English.lproj/Update.nib/classes.nib \
81         extras/MacOSX/Resources/English.lproj/Update.nib/info.nib \
82         extras/MacOSX/Resources/English.lproj/Update.nib/keyedobjects.nib \
83         extras/MacOSX/Resources/English.lproj/InfoPlist.strings \
84         extras/MacOSX/Resources/a52.icns \
85         extras/MacOSX/Resources/aac.icns \
86         extras/MacOSX/Resources/asf.icns \
87         extras/MacOSX/Resources/asx.icns \
88         extras/MacOSX/Resources/avi.icns \
89         extras/MacOSX/Resources/bin.icns \
90         extras/MacOSX/Resources/cue.icns \
91         extras/MacOSX/Resources/dat.icns \
92         extras/MacOSX/Resources/divx.icns \
93         extras/MacOSX/Resources/dv.icns \
94         extras/MacOSX/Resources/generic.icns \
95         extras/MacOSX/Resources/m3u.icns \
96         extras/MacOSX/Resources/mov.icns \
97         extras/MacOSX/Resources/mp3.icns \
98         extras/MacOSX/Resources/mp4.icns \
99         extras/MacOSX/Resources/mpeg.icns \
100         extras/MacOSX/Resources/mpeg1.icns \
101         extras/MacOSX/Resources/mpeg2.icns \
102         extras/MacOSX/Resources/mpeg4.icns \
103         extras/MacOSX/Resources/mpg.icns \
104         extras/MacOSX/Resources/ogg.icns \
105         extras/MacOSX/Resources/ogm.icns \
106         extras/MacOSX/Resources/pls.icns \
107         extras/MacOSX/Resources/srt.icns \
108         extras/MacOSX/Resources/sub.icns \
109         extras/MacOSX/Resources/vlc.icns \
110         extras/MacOSX/Resources/vob.icns \
111         extras/MacOSX/Resources/wma.icns \
112         extras/MacOSX/Resources/wmv.icns \
113         extras/MacOSX/Resources/pause.png \
114         extras/MacOSX/Resources/pause_blue.png \
115         extras/MacOSX/Resources/play.png \
116         extras/MacOSX/Resources/play_blue.png \
117         extras/MacOSX/Resources/stop.png \
118         extras/MacOSX/Resources/stop_blue.png \
119         extras/MacOSX/Resources/display.png \
120         extras/MacOSX/Resources/display_slider.png \
121         extras/MacOSX/Resources/display_track.png \
122         extras/MacOSX/Resources/equalizerdrawer_active.png \
123         extras/MacOSX/Resources/equalizerdrawer_blue.png \
124         extras/MacOSX/Resources/fullscreen_active.png \
125         extras/MacOSX/Resources/fullscreen_blue.png \
126         extras/MacOSX/Resources/next_active.png \
127         extras/MacOSX/Resources/next_blue.png \
128         extras/MacOSX/Resources/playlistdrawer_active.png \
129         extras/MacOSX/Resources/playlistdrawer_blue.png \
130         extras/MacOSX/Resources/previous_active.png \
131         extras/MacOSX/Resources/previous_blue.png \
132         extras/MacOSX/Resources/skip_forward_active.png \
133         extras/MacOSX/Resources/skip_forward_blue.png \
134         extras/MacOSX/Resources/skip_previous_active.png \
135         extras/MacOSX/Resources/skip_previous_blue.png \
136         extras/MacOSX/Resources/volume_high.png \
137         extras/MacOSX/Resources/volume_low.png \
138         extras/MacOSX/Resources/volumeslider_blue.png \
139         extras/MacOSX/Resources/volumeslider_normal.png \
140         extras/MacOSX/Resources/volumetrack.png \
141         extras/MacOSX/Resources/about_bg.png \
142         extras/MacOSX/Resources/vlc.scriptSuite \
143         extras/MacOSX/Resources/vlc.scriptTerminology \
144         extras/MacOSX/Resources/README \
145         extras/MacOSX/vlc.pbproj/project.pbxproj \
146         extras/MacOSX/Delete_Preferences.app/Contents/Info.plist \
147         extras/MacOSX/Delete_Preferences.app/Contents/PkgInfo \
148         extras/MacOSX/Delete_Preferences.app/Contents/MacOS/applet \
149         extras/MacOSX/Delete_Preferences.app/Contents/Resources/description.rtfd/TXT.rtf \
150         extras/MacOSX/Delete_Preferences.app/Contents/Resources/applet.icns \
151         extras/MacOSX/Delete_Preferences.app/Contents/Resources/applet.rsrc \
152         extras/MacOSX/Delete_Preferences.app/Contents/Resources/Scripts/main.scpt \
153         extras/Makefile \
154         extras/zsh.cpp \
155         $(NULL)
156
157 ###############################################################################
158 # MS Visual Studio and eMbedded Visual Studio projects
159 ###############################################################################
160
161 EXTRA_DIST += \
162         msvc/vlc.dsw \
163         msvc/libvlc.dsp.in \
164         msvc/plugins.dsp.in \
165         msvc/vlc.dsp.in \
166         msvc/config.h.in \
167         msvc/modules_builtin_msvc.h \
168         evc/vlc.vcw \
169         evc/libvlc.vcp.in \
170         evc/vlc.vcp.in \
171         evc/plugins.vcp.in \
172         evc/errno.h \
173         evc/config.h.in \
174         evc/modules_builtin_evc.h \
175         $(NULL)
176
177 dist-hook:
178         cd $(distdir) && srcdir=. $(SHELL) ./toolbox --update-vc
179         distdir=$(distdir) srcdir=$(srcdir) $(SHELL) $(srcdir)/toolbox --dist-contrib
180
181 ###############################################################################
182 # Building libvlc
183 ###############################################################################
184
185 bin_SCRIPTS = vlc-config
186 vlc-config: $(top_builddir)/config.status $(top_builddir)/vlc-config.in
187         $(SHELL) ./config.status --file=$@
188         chmod 0755 $@
189
190 vlc-config.in: vlc-config.in.in
191         ./config.status --recheck
192
193 CLEANFILES = $(BUILT_SOURCES_clean) stamp-builtin
194 DISTCLEANFILES = $(BUILT_SOURCES_distclean) vlc-config.in compile
195
196 ###############################################################################
197 # Building vlc
198 ###############################################################################
199
200 .PHONY: libvlc
201
202 # Shortcut for developpers to rebuild the core (libvlc + vlc)
203 # Don't use it if you don't know what it is about.
204 # Don't complain if it doesn't work. -- Courmisch
205 core: libvlc vlc$(EXEEXT)
206
207 libvlc:
208         cd src && $(MAKE) all
209
210 bin_PROGRAMS = vlc
211
212 vlc_SOURCES = src/vlc.c
213 # Ugly kludge so that automake defines $(CXXLINK)
214 EXTRA_vlc_SOURCES = extras/zsh.cpp
215
216 # Work around a bug in the arm-wince-pe linker
217 if HAVE_WINCE
218 vlc_WORKAROUNDLDFLAGS = $(LIB_libvlc)
219 endif
220
221 if BUILD_SHARED
222 LIB_libvlc = src/libvlc$(LIBEXT)
223 #-Wl,-rpath $(libdir)
224 else
225 LIB_libvlc = src/libvlc.a
226 endif
227
228 vlc_LDFLAGS = `$(VLC_CONFIG) --libs vlc builtin` $(vlc_WORKAROUNDLDFLAGS)
229 vlc_LDADD = $(LIB_libvlc) $(DATA_win32_rc) $(INCLUDED_LIBINTL)
230 vlc_CFLAGS = `$(VLC_CONFIG) --cflags vlc`
231
232 # We use DEPENDENCIES_vlc instead of vlc_DEPENDENCIES because of an
233 # old automake-1.5 bug (automake/279).
234 DEPENDENCIES_vlc = $(LIB_libvlc) $(DATA_win32_rc)
235
236 vlc$(EXEEXT): $(vlc_OBJECTS) $(DEPENDENCIES_vlc) stamp-builtin
237         @rm -f vlc$(EXEEXT)
238         @case `$(VLC_CONFIG) --linkage vlc builtin` in \
239           c++) cmd="$(CXXLINK)" ;; \
240           objc) cmd="$(OBJCLINK)" ;; \
241           c|*) cmd="$(LINK)" ;; \
242         esac ; \
243         cmd="$$cmd $(vlc_OBJECTS) $(vlc_LDADD) $(vlc_LDFLAGS) $(LIBS)" ; \
244         echo $$cmd ; \
245         eval $$cmd
246
247 if HAVE_BEOS
248 DATA_noinst_beos = vlc-bundle
249 vlc-bundle: vlc
250         rm -Rf $(top_builddir)/vlc-bundle ; mkdir -p $(top_builddir)/vlc-bundle
251         cp $(top_builddir)/vlc $(top_builddir)/vlc-bundle/
252         xres -o $(top_builddir)/vlc-bundle/vlc $(srcdir)/share/vlc_beos.rsrc
253         for i in "" `$(VLC_CONFIG) --target plugin` ; do \
254           if test -n "$$i" ; then \
255             mkdir -p $(top_builddir)/vlc-bundle/plugins ; \
256             cp "$$i$(LIBEXT)" $(top_builddir)/vlc-bundle/plugins/ ; \
257           fi ; \
258         done
259         if test -d $(top_builddir)/extras/contrib/vlc-lib ; then \
260           mkdir -p $(top_builddir)/vlc-bundle/lib ; \
261           for i in $(top_builddir)/extras/contrib/vlc-lib/*.so ; do \
262             cp $$i $(top_builddir)/vlc-bundle/lib/ ; \
263           done ; \
264         fi
265         for i in $(ALL_LINGUAS); do \
266           mkdir -p "$(top_builddir)/vlc-bundle/locale/$$i/LC_MESSAGES" ; \
267           cp "$(top_builddir)/po/$$i.gmo" \
268             "$(top_builddir)/vlc-bundle/locale/$$i/LC_MESSAGES/vlc.mo" || true ; \
269         done
270         find $(top_builddir)/vlc-bundle -type f -exec mimeset -f "{}" \;
271 endif
272
273 # Install the symlinks and shared libvlc
274 install-exec-local:
275         for i in "" $(ALIASES) ; do if test -n "$$i" ; then \
276           rm -f "$(DESTDIR)$(bindir)/$$i" && \
277           ln -sf vlc "$(DESTDIR)$(bindir)/$$i" ; \
278         fi ; done
279
280 # the opposite of install-{data,exec}-local
281 uninstall-local:
282         for i in "" $(ALIASES) ; do if test -n "$$i" ; then \
283           rm -f "$(DESTDIR)$(bindir)/$$i" ; \
284         fi ; done
285
286 if HAVE_DARWIN
287 # Create the MacOS X app
288 vlc_app_DATA = VLC.app
289 vlc_appdir = $(bindir)
290 # VLC-release.app is the old VLC.app target
291 VLC-release.app: vlc
292         @if test -e "$(top_builddir)/tmp"; then \
293           echo "Error: please remove $(top_builddir)/tmp, it is in the way"; \
294           false; \
295         else \
296           echo "OK."; mkdir -p "$(top_builddir)/tmp/extras"; \
297         fi
298         rm -Rf $(top_builddir)/VLC-release.app
299         cp -R $(srcdir)/extras/MacOSX $(top_builddir)/tmp/extras
300         for i in AUTHORS COPYING README.MacOSX.rtf THANKS; do \
301           cp "$(srcdir)/$$i" $(top_builddir)/tmp; \
302         done
303         mkdir -p $(top_builddir)/tmp/modules/audio_output
304         mkdir -p $(top_builddir)/tmp/modules/gui/macosx
305         for i in \
306             about.h \
307             about.m \
308             applescript.h \
309             applescript.m \
310             controls.h \
311             controls.m \
312             equalizer.h \
313             equalizer.m \
314             intf.h \
315             intf.m \
316             macosx.m \
317             misc.h \
318             misc.m \
319             open.h \
320             open.m \
321             output.h \
322             output.m \
323             playlist.h \
324             playlist.m \
325             playlistinfo.h \
326             playlistinfo.m \
327             prefs_widgets.h \
328             prefs_widgets.m \
329             prefs.h \
330             prefs.m \
331             vout.h \
332             voutqt.m \
333             voutgl.m \
334             wizard.h \
335             wizard.m \
336             extended.h \
337             extended.m \
338             bookmarks.h \
339             bookmarks.m \
340             sfilters.h \
341             sfilters.m \
342             vout.m; do \
343           cp "$(srcdir)/modules/gui/macosx/$$i" \
344              $(top_builddir)/tmp/modules/gui/macosx; \
345         done
346         case $(target_triplet) in \
347           *darwin6*) cd $(top_builddir)/tmp/extras/MacOSX && pbxbuild -target vlc | grep -v '^\([ \t]\|$$\)'; \
348             cd ../../../; \
349             cp -R $(top_builddir)/tmp/extras/MacOSX/build/VLC.bundle \
350                   $(top_builddir)/VLC-release.app;; \
351           *darwin7*) cd $(top_builddir)/tmp/extras/MacOSX && xcodebuild -target vlc | grep -v '^\([ \t]\|$$\)'; \
352             cd ../../../; \
353             cp -R $(top_builddir)/tmp/extras/MacOSX/build/VLC.bundle \
354                   $(top_builddir)/VLC-release.app;; \
355           *darwin8*) cd $(top_builddir)/tmp/extras/MacOSX && xcodebuild -target vlc | grep -v '^\([ \t]\|$$\)'; \
356             cd ../../../; \
357             cp -R $(top_builddir)/tmp/extras/MacOSX/build/Default/VLC.bundle \
358                   $(top_builddir)/VLC-release.app;; \
359         esac
360         rm -Rf $(top_builddir)/tmp
361         $(INSTALL) -d $(top_builddir)/VLC-release.app/Contents/MacOS
362         $(INSTALL) $(top_builddir)/vlc \
363                    $(top_builddir)/VLC-release.app/Contents/MacOS/VLC
364         ln -sf ./VLC $(top_builddir)/VLC-release.app/Contents/MacOS/clivlc
365         $(INSTALL) -d $(top_builddir)/VLC-release.app/Contents/MacOS/modules
366         for i in "" `$(VLC_CONFIG) --target plugin` ; do \
367           if test -n "$$i" ; \
368             then $(INSTALL) "$$i$(LIBEXT)" \
369                            "$(top_builddir)/VLC-release.app/Contents/MacOS/modules" ; \
370           fi ; done
371         if test -d $(srcdir)/extras/contrib/vlc-lib; then \
372           mkdir -p $(top_builddir)/VLC-release.app/Contents/MacOS/lib ; \
373           for i in $(srcdir)/extras/contrib/vlc-lib/*.dylib ; do \
374             $(INSTALL) -m 644 $${i} $(top_builddir)/VLC-release.app/Contents/MacOS/lib/vlc_`basename $${i}` ; \
375           done ; \
376         fi
377         $(INSTALL) -d $(top_builddir)/VLC-release.app/Contents/MacOS/share
378         $(INSTALL) -d $(top_builddir)/VLC-release.app/Contents/MacOS/share/http
379         for i in $(srcdir)/share/http/* ; do \
380           $(INSTALL) -m 644 $${i} $(top_builddir)/VLC-release.app/Contents/MacOS/share/http/`basename $${i}` ; \
381         done ; \
382         $(INSTALL) -d $(top_builddir)/VLC-release.app/Contents/MacOS/locale
383         for i in $(ALL_LINGUAS); do \
384           mkdir -p $(top_builddir)/VLC-release.app/Contents/MacOS/locale/$${i}/LC_MESSAGES ; \
385           cp $(srcdir)/po/$${i}.gmo $(top_builddir)/VLC-release.app/Contents/MacOS/locale/$${i}/LC_MESSAGES/vlc.mo || true ; \
386           mkdir -p $(top_builddir)/VLC-release.app/Contents/Resources/$${i}.lproj ; \
387           ln -sf ../English.lproj/InfoPlist.strings \
388               $(top_builddir)/VLC-release.app/Contents/Resources/$${i}.lproj ; \
389           ln -sf ../English.lproj/MainMenu.nib \
390               $(top_builddir)/VLC-release.app/Contents/Resources/$${i}.lproj ; \
391           ln -sf ../English.lproj/vlc.scriptTerminology \
392               $(top_builddir)/VLC-release.app/Contents/Resources/$${i}.lproj ; \
393         done
394         printf "APPLVLC#" >| $(top_builddir)/VLC-release.app/Contents/PkgInfo
395
396 VLC.app: vlc
397         @if test -e "$(top_builddir)/tmp"; then \
398           echo "Error: please remove $(top_builddir)/tmp, it is in the way"; \
399           false; \
400         else \
401           echo "OK."; mkdir -p "$(top_builddir)/tmp/extras"; \
402         fi
403         rm -Rf $(top_builddir)/VLC.app
404         cp -R $(srcdir)/extras/MacOSX $(top_builddir)/tmp/extras
405         for i in AUTHORS COPYING README.MacOSX.rtf THANKS; do \
406           cp "$(srcdir)/$$i" $(top_builddir)/tmp; \
407         done
408         mkdir -p $(top_builddir)/tmp/modules/audio_output
409         mkdir -p $(top_builddir)/tmp/modules/gui/macosx
410         for i in \
411             about.h \
412             about.m \
413             applescript.h \
414             applescript.m \
415             controls.h \
416             controls.m \
417             equalizer.h \
418             equalizer.m \
419             intf.h \
420             intf.m \
421             macosx.m \
422             misc.h \
423             misc.m \
424             open.h \
425             open.m \
426             output.h \
427             output.m \
428             playlist.h \
429             playlist.m \
430             playlistinfo.h \
431             playlistinfo.m \
432             prefs_widgets.h \
433             prefs_widgets.m \
434             prefs.h \
435             prefs.m \
436             vout.h \
437             voutqt.m \
438             voutgl.m \
439             wizard.h \
440             wizard.m \
441             extended.h \
442             extended.m \
443             bookmarks.h \
444             bookmarks.m \
445             sfilters.h \
446             sfilters.m \
447             vout.m; do \
448           cp "$(srcdir)/modules/gui/macosx/$$i" \
449              $(top_builddir)/tmp/modules/gui/macosx; \
450         done
451         case $(target_triplet) in \
452           *darwin6*) cd $(top_builddir)/tmp/extras/MacOSX && pbxbuild -target vlc | grep -v '^\([ \t]\|$$\)'; \
453             cd ../../../; \
454             cp -R $(top_builddir)/tmp/extras/MacOSX/build/VLC.bundle \
455                   $(top_builddir)/VLC.app;; \
456           *darwin7*) cd $(top_builddir)/tmp/extras/MacOSX && xcodebuild -target vlc | grep -v '^\([ \t]\|$$\)'; \
457             cd ../../../; \
458             cp -R $(top_builddir)/tmp/extras/MacOSX/build/VLC.bundle \
459                   $(top_builddir)/VLC.app;; \
460           *darwin8*) cd $(top_builddir)/tmp/extras/MacOSX && xcodebuild -target vlc | grep -v '^\([ \t]\|$$\)'; \
461             cd ../../../; \
462             cp -R $(top_builddir)/tmp/extras/MacOSX/build/Default/VLC.bundle \
463                   $(top_builddir)/VLC.app;; \
464         esac
465         rm -Rf $(top_builddir)/tmp
466         $(INSTALL) -d $(top_builddir)/VLC.app/Contents/MacOS
467         $(INSTALL) $(top_builddir)/vlc \
468                    $(top_builddir)/VLC.app/Contents/MacOS/VLC
469         ln -sf ./VLC $(top_builddir)/VLC.app/Contents/MacOS/clivlc
470         $(INSTALL) -d $(top_builddir)/VLC.app/Contents/MacOS/modules
471         for i in "" `$(VLC_CONFIG) --target plugin` ; do \
472           if test -n "$$i" ; \
473             then ln -sfn "`pwd`/$$i$(LIBEXT)" \
474                            "$(top_builddir)/VLC.app/Contents/MacOS/modules" ; \
475           fi ; done
476         if test -d $(srcdir)/extras/contrib/vlc-lib; then \
477           mkdir -p $(top_builddir)/VLC.app/Contents/MacOS/lib ; \
478           for i in $(srcdir)/extras/contrib/vlc-lib/*.dylib ; do \
479             ln -sfn `pwd`/$${i} $(top_builddir)/VLC.app/Contents/MacOS/lib/vlc_`basename $${i}` ; \
480           done ; \
481         fi
482         ln -sfn `pwd`/share $(top_builddir)/VLC.app/Contents/MacOS/
483         $(INSTALL) -d $(top_builddir)/VLC.app/Contents/MacOS/locale
484         for i in $(ALL_LINGUAS); do \
485           mkdir -p $(top_builddir)/VLC.app/Contents/MacOS/locale/$${i}/LC_MESSAGES ; \
486           ln -sfn `pwd`/po/$${i}.gmo $(top_builddir)/VLC.app/Contents/MacOS/locale/$${i}/LC_MESSAGES/vlc.mo || true ; \
487           mkdir -p $(top_builddir)/VLC.app/Contents/Resources/$${i}.lproj ; \
488           ln -sf ../English.lproj/InfoPlist.strings \
489               $(top_builddir)/VLC.app/Contents/Resources/$${i}.lproj ; \
490           ln -sf ../English.lproj/MainMenu.nib \
491               $(top_builddir)/VLC.app/Contents/Resources/$${i}.lproj ; \
492         done
493         printf "APPLVLC#" >| $(top_builddir)/VLC.app/Contents/PkgInfo
494 endif
495
496 if HAVE_WIN32
497 DATA_win32_rc = $(noinst_share_vlc_win32_rc_DATA)
498 noinst_share_vlc_win32_rc_DATA = share/vlc_win32_rc.$(OBJEXT)
499 noinst_share_vlc_win32_rcdir = $(libdir)
500 share/vlc_win32_rc.$(OBJEXT): share/vlc_win32_rc.rc
501         $(WINDRES) -DVERSION=$(VERSION) -DVERSION_NUMBER=`echo $(VERSION).0.0.0 | sed 's/\([0-9]*\)[^.]*\.*\([0-9]*\)[^.]*\.*\([0-9]*\)[^.]*\.*\([0-9]*\).*/\1,\2,\3,\4/'` --include-dir $(srcdir)/share -i $< -o $@
502 endif
503
504
505 ###############################################################################
506 # Building specific source packages
507 ###############################################################################
508
509 dist-woody: distdir
510         $(remove_distdir_woody)
511         mv $(distdir) $(PACKAGE)-woody-$(VERSION)
512         $(srcdir)/toolbox --make-woody $(PACKAGE)-woody-$(VERSION)
513         $(AMTAR) chof - $(PACKAGE)-woody-$(VERSION) \
514           | GZIP=$(GZIP_ENV) gzip -c >$(PACKAGE)-woody-$(VERSION).tar.gz
515         $(remove_distdir_woody)
516
517 remove_distdir_woody = \
518   { test ! -d $(PACKAGE)-woody-$(VERSION) \
519     || { find $(PACKAGE)-woody-$(VERSION) -type d ! -perm -200 \
520            -exec chmod u+w {} ';' \
521          && rm -fr $(PACKAGE)-woody-$(VERSION); }; }
522
523 ###############################################################################
524 # Building architecture-specific binary packages
525 ###############################################################################
526
527 # XXX: this rule is probably only useful to you if you have exactly
528 # the same setup as me. Contact sam@zoy.org if you need to use it.
529 #
530 package-win32-base-debug:
531 # Check that tmp isn't in the way
532         @if test -e "$(top_builddir)/vlc-${VERSION}"; then \
533           echo "Error: please remove $(top_builddir)/vlc-${VERSION}, it is in the way"; \
534           false; \
535         else \
536           echo "OK."; mkdir -p "$(top_builddir)/vlc-${VERSION}"; \
537         fi
538
539 # Copy relevant files
540         cp "$(srcdir)/vlc.win32.nsi" "$(top_builddir)/vlc-${VERSION}/"
541         cp "$(top_builddir)/vlc$(EXEEXT)" "$(top_builddir)/vlc-${VERSION}/"
542         cp "$(top_srcdir)/vlc.exe.manifest" "$(top_builddir)/vlc-${VERSION}/"
543         $(STRIP) "$(top_builddir)/vlc-${VERSION}/vlc$(EXEEXT)"
544
545         for file in AUTHORS MAINTAINERS THANKS NEWS COPYING README ; \
546           do sed 's/@/_AT_/' < "$(srcdir)/$$file" > "$(top_builddir)/vlc-${VERSION}/$${file}.txt" ; \
547           unix2dos "$(top_builddir)/vlc-${VERSION}/$${file}.txt" ; done
548
549         mkdir -p "$(top_builddir)/vlc-${VERSION}/plugins"
550         for i in "" `$(VLC_CONFIG) --target plugin` ; do \
551           if test -n "$$i" ; then \
552             $(INSTALL) "$(top_builddir)/$$i$(LIBEXT)" \
553             "$(top_builddir)/vlc-${VERSION}/plugins/" ; \
554           fi ; done
555
556         mkdir $(top_builddir)/vlc-${VERSION}/locale
557         for i in $(ALL_LINGUAS); do \
558           mkdir -p "$(top_builddir)/vlc-${VERSION}/locale/$${i}/LC_MESSAGES" ; \
559           cp "$(srcdir)/po/$${i}.gmo" \
560             "$(top_builddir)/vlc-${VERSION}/locale/$${i}/LC_MESSAGES/vlc.mo" \
561             || true ; \
562         done
563
564         mkdir -p $(top_builddir)/vlc-${VERSION}/skins/fonts
565         for i in $(srcdir)/share/skins2/fonts/*.*; do \
566           cp $$i $(top_builddir)/vlc-${VERSION}/skins/fonts/ || true ; \
567         done
568         for i in $(srcdir)/share/skins2/*.*; do \
569           cp $$i $(top_builddir)/vlc-${VERSION}/skins/ || true ; \
570         done
571
572         mkdir -p "$(top_builddir)/vlc-${VERSION}/osdmenu"
573         cp $(srcdir)/share/osdmenu/*.* "$(top_builddir)/vlc-${VERSION}/osdmenu"
574         for dir in dvd dvd/selected dvd/unselect dvd/selection dvd/volume default default/selected default/selection default/volume;do \
575                 mkdir -p "$(top_builddir)/vlc-${VERSION}/osdmenu/$$dir"; \
576                 for file in $(srcdir)/share/osdmenu/$${dir}/*.*;do \
577                          cp $$file "$(top_builddir)/vlc-${VERSION}/osdmenu/$$dir" || true; \
578                 done; \
579         done
580         unix2dos $(top_builddir)/vlc-${VERSION}/osdmenu/*.cfg;
581         sed -i 's%share/osdmenu%osdmenu%g' $(top_builddir)/vlc-${VERSION}/osdmenu/*.cfg
582         sed -i 's%/%\\%g' $(top_builddir)/vlc-${VERSION}/osdmenu/*.cfg 
583
584         mkdir -p "$(top_builddir)/vlc-${VERSION}/http/images"
585         mkdir -p "$(top_builddir)/vlc-${VERSION}/http/requests"
586         mkdir -p "$(top_builddir)/vlc-${VERSION}/http/js"
587         mkdir -p "$(top_builddir)/vlc-${VERSION}/http/dialogs"
588         mkdir -p "$(top_builddir)/vlc-${VERSION}/http/old"
589         mkdir -p "$(top_builddir)/vlc-${VERSION}/http/old/vlm"
590         mkdir -p "$(top_builddir)/vlc-${VERSION}/http/old/admin"
591         cp $(srcdir)/share/http/*.html $(top_builddir)/vlc-${VERSION}/http/ ;
592         unix2dos $(top_builddir)/vlc-${VERSION}/http/*.html ;
593         cp $(srcdir)/share/http/*.css $(top_builddir)/vlc-${VERSION}/http/ ;
594         unix2dos $(top_builddir)/vlc-${VERSION}/http/*.css ;
595         cp $(srcdir)/share/http/js/*.js $(top_builddir)/vlc-${VERSION}/http/js/ ;
596         unix2dos $(top_builddir)/vlc-${VERSION}/http/js/*.js ;
597         cp $(srcdir)/share/http/dialogs/* $(top_builddir)/vlc-${VERSION}/http/dialogs/ ;
598         unix2dos $(top_builddir)/vlc-${VERSION}/http/dialogs/* ;
599         cp $(srcdir)/share/http/*.ico $(top_builddir)/vlc-${VERSION}/http/ ;
600         cp $(srcdir)/share/http/images/*.png $(top_builddir)/vlc-${VERSION}/http/images/
601         cp $(srcdir)/share/http/requests/*.xml $(top_builddir)/vlc-${VERSION}/http/requests/ ;
602         unix2dos $(top_builddir)/vlc-${VERSION}/http/requests/*.xml ;
603
604         cp $(srcdir)/share/http/old/*.html $(top_builddir)/vlc-${VERSION}/http/old/ ;
605         unix2dos $(top_builddir)/vlc-${VERSION}/http/old/*.html ;
606         cp $(srcdir)/share/http/old/*.ico $(top_builddir)/vlc-${VERSION}/http/old/ ;
607         cp $(srcdir)/share/http/old/*.css $(top_builddir)/vlc-${VERSION}/http/old/ ;
608         cp $(srcdir)/share/http/old/*.png $(top_builddir)/vlc-${VERSION}/http/old/ ;
609         cp $(srcdir)/share/http/old/vlm/*.html $(top_builddir)/vlc-${VERSION}/http/old/vlm/ ;
610         unix2dos $(top_builddir)/vlc-${VERSION}/http/old/vlm/*.html ;
611         cp $(srcdir)/share/http/old/admin/*.html $(top_builddir)/vlc-${VERSION}/http/old/admin/ ;
612         unix2dos $(top_builddir)/vlc-${VERSION}/http/old/admin/*.html ;
613
614         cp $(srcdir)/share/vlc48x48.ico $(top_builddir)/vlc-${VERSION}/ ;
615
616         mkdir -p "$(top_builddir)/vlc-${VERSION}/mozilla"
617 if BUILD_MOZILLA
618         cp $(top_builddir)/mozilla/*$(LIBEXT) $(top_builddir)/vlc-${VERSION}/mozilla/ ;
619         $(STRIP) $(top_builddir)/vlc-${VERSION}/mozilla/*$(LIBEXT);
620         cp $(top_builddir)/mozilla/vlcintf.xpt  $(top_builddir)/vlc-${VERSION}/mozilla/ ;
621 endif
622
623         mkdir -p "$(top_builddir)/vlc-${VERSION}/activex"
624 if BUILD_ACTIVEX
625         cp $(srcdir)/activex/README.TXT  $(top_builddir)/vlc-${VERSION}/activex/ ;
626         cp $(srcdir)/activex/test.html  $(top_builddir)/vlc-${VERSION}/activex/ ;
627         unix2dos $(top_builddir)/vlc-${VERSION}/activex/* ;
628
629         cp $(top_builddir)/activex/*$(LIBEXT) $(top_builddir)/vlc-${VERSION}/activex/ ;
630         $(STRIP) $(top_builddir)/vlc-${VERSION}/activex/*$(LIBEXT);
631 endif
632 # Rebase all those DLLs to speed up loading (need cygwin rebase)
633         if rebase -b 0x42 /dev/null >/dev/null 2>&1; then \
634                 find $(top_builddir)/vlc-${VERSION} -type f -name '*.dll' -print | rebase -b 0x70000000 -T -; \
635         fi
636
637 package-win32-base: package-win32-base-debug
638         for i in "" $(top_builddir)/vlc-${VERSION}/plugins/*$(LIBEXT) ; \
639           do if test -n "$$i" ; then $(STRIP) "$$i" ; fi ; done
640
641
642 package-win32-base-exe:
643 # Create package
644         if makensis -VERSION >/dev/null 2>&1; then \
645             MAKENSIS="makensis -DVERSION=${VERSION}"; \
646         elif [ -x "/cygdrive/c/Program Files/NSIS/makensis" ]; then \
647             MAKENSIS="/cygdrive/c/Program\ Files/NSIS/makensis /DVERSION=${VERSION}"; \
648         elif wine --version >dev/null 2>&1; then \
649             MAKENSIS="wine C:/Program\ Files/NSIS/makensis.exe /DVERSION=${VERSION}"; \
650         else \
651             echo 'Error: cannot locate makensis tool'; exit 1; \
652         fi; \
653         eval "$$MAKENSIS $(top_builddir)/vlc-${VERSION}/vlc.win32.nsi"
654
655 package-win32-base-exe-cygwin: package-win32-base-exe
656 # Create package
657
658 package-win32-base-exe-linux:
659 # Create package
660         makensis -DVERSION=${VERSION} $(top_builddir)/vlc-${VERSION}/vlc.win32.nsi
661
662 package-win32-base-zip:
663 # Create package 
664         zip -r vlc-${VERSION}-win32.zip vlc-${VERSION}
665
666 package-win32-exe: package-win32-base package-win32-base-exe
667 # Clean up
668         rm -Rf $(top_builddir)/vlc-${VERSION}
669
670 package-win32-exe-linux: package-win32-base package-win32-base-exe-linux
671 # Clean up
672         rm -Rf $(top_builddir)/vlc-${VERSION}
673
674 package-win32-zip: package-win32-base package-win32-base-zip
675 # Clean up
676         rm -Rf $(top_builddir)/vlc-${VERSION}
677
678 package-win32: package-win32-base package-win32-base-exe package-win32-base-zip
679 # Clean up
680         rm -Rf $(top_builddir)/vlc-${VERSION}
681
682 package-wince-base:
683 # Check that tmp isn't in the way
684         @if test -e "$(top_builddir)/vlc-${VERSION}"; then \
685           echo "Error: please remove $(top_builddir)/vlc-${VERSION}, it is in the way"; \
686           false; \
687         else \
688           echo "OK."; mkdir -p "$(top_builddir)/vlc-${VERSION}"; \
689         fi
690
691 # Copy relevant files
692         cp "$(top_builddir)/vlc$(EXEEXT)" "$(top_builddir)/vlc-${VERSION}/"
693         cp "$(top_srcdir)/vlc.exe.manifest" "$(top_builddir)/vlc-${VERSION}/"
694         $(STRIP) "$(top_builddir)/vlc-${VERSION}/vlc$(EXEEXT)"
695
696         for file in AUTHORS MAINTAINERS THANKS NEWS COPYING README ; \
697           do sed 's/@/_AT_/' < "$(srcdir)/$$file" > "$(top_builddir)/vlc-${VERSION}/$${file}.txt" ; \
698           unix2dos "$(top_builddir)/vlc-${VERSION}/$${file}.txt" ; done
699
700         mkdir $(top_builddir)/vlc-${VERSION}/locale
701         for i in $(ALL_LINGUAS); do \
702           mkdir -p "$(top_builddir)/vlc-${VERSION}/locale/$${i}/LC_MESSAGES" ; \
703           cp "$(srcdir)/po/$${i}.gmo" \
704             "$(top_builddir)/vlc-${VERSION}/locale/$${i}/LC_MESSAGES/vlc.mo" \
705             || true ; \
706         done
707
708
709         mkdir -p "$(top_builddir)/vlc-${VERSION}/http/images"
710         mkdir -p "$(top_builddir)/vlc-${VERSION}/http/requests"
711         mkdir -p "$(top_builddir)/vlc-${VERSION}/http/js"
712         mkdir -p "$(top_builddir)/vlc-${VERSION}/http/dialogs"
713         mkdir -p "$(top_builddir)/vlc-${VERSION}/http/old"
714         mkdir -p "$(top_builddir)/vlc-${VERSION}/http/old/vlm"
715         mkdir -p "$(top_builddir)/vlc-${VERSION}/http/old/admin"
716         cp $(srcdir)/share/http/*.html $(top_builddir)/vlc-${VERSION}/http/ ;
717         unix2dos $(top_builddir)/vlc-${VERSION}/http/*.html ;
718         cp $(srcdir)/share/http/*.css $(top_builddir)/vlc-${VERSION}/http/ ;
719         unix2dos $(top_builddir)/vlc-${VERSION}/http/*.css ;
720         cp $(srcdir)/share/http/js/*.js $(top_builddir)/vlc-${VERSION}/http/js/ ;
721         unix2dos $(top_builddir)/vlc-${VERSION}/http/js/*.js ;
722         cp $(srcdir)/share/http/dialogs/* $(top_builddir)/vlc-${VERSION}/http/dialogs/ ;
723         unix2dos $(top_builddir)/vlc-${VERSION}/http/dialogs/* ;
724         cp $(srcdir)/share/http/*.ico $(top_builddir)/vlc-${VERSION}/http/ ;
725         cp $(srcdir)/share/http/images/*.png $(top_builddir)/vlc-${VERSION}/http/images/
726         cp $(srcdir)/share/http/requests/*.xml $(top_builddir)/vlc-${VERSION}/http/requests/ ;
727         unix2dos $(top_builddir)/vlc-${VERSION}/http/requests/*.xml ;
728
729         cp $(srcdir)/share/http/old/*.html $(top_builddir)/vlc-${VERSION}/http/old/ ;
730         unix2dos $(top_builddir)/vlc-${VERSION}/http/old/*.html ;
731         cp $(srcdir)/share/http/old/*.ico $(top_builddir)/vlc-${VERSION}/http/old/ ;
732         cp $(srcdir)/share/http/old/*.css $(top_builddir)/vlc-${VERSION}/http/old/ ;
733         cp $(srcdir)/share/http/old/*.png $(top_builddir)/vlc-${VERSION}/http/old/ ;
734         cp $(srcdir)/share/http/old/vlm/*.html $(top_builddir)/vlc-${VERSION}/http/old/vlm/ ;
735         unix2dos $(top_builddir)/vlc-${VERSION}/http/old/vlm/*.html ;
736         cp $(srcdir)/share/http/old/admin/*.html $(top_builddir)/vlc-${VERSION}/http/old/admin/ ;
737         unix2dos $(top_builddir)/vlc-${VERSION}/http/old/admin/*.html ;
738
739         cp $(srcdir)/share/vlc48x48.ico $(top_builddir)/vlc-${VERSION}/ ;
740
741 if BUILD_MOZILLA
742         mkdir -p "$(top_builddir)/vlc-${VERSION}/mozilla"
743         cp $(top_builddir)/mozilla/*$(LIBEXT) $(top_builddir)/vlc-${VERSION}/mozilla/ ;
744         $(STRIP) $(top_builddir)/vlc-${VERSION}/mozilla/*$(LIBEXT);
745         cp $(top_builddir)/mozilla/vlcintf.xpt  $(top_builddir)/vlc-${VERSION}/mozilla/ ;
746 endif
747
748 if BUILD_ACTIVEX
749         mkdir -p "$(top_builddir)/vlc-${VERSION}/activex"
750         cp $(srcdir)/activex/README.TXT  $(top_builddir)/vlc-${VERSION}/activex/ ;
751         cp $(srcdir)/activex/test.html  $(top_builddir)/vlc-${VERSION}/activex/ ;
752         unix2dos $(top_builddir)/vlc-${VERSION}/activex/* ;
753
754         cp $(top_builddir)/activex/*$(LIBEXT) $(top_builddir)/vlc-${VERSION}/activex/ ;
755         $(STRIP) $(top_builddir)/vlc-${VERSION}/activex/*$(LIBEXT);
756 endif
757 # Rebase all those DLLs to speed up loading (need cygwin rebase)
758         if rebase -b 0x42 /dev/null >/dev/null 2>&1; then \
759                 find $(top_builddir)/vlc-${VERSION} -type f -name '*.dll' -print | rebase -b 0x70000000 -T -; \
760         fi
761
762 package-wince-base-zip:
763 # Create package 
764         zip -r vlc-${VERSION}-wince.zip vlc-${VERSION}
765
766 package-wince: package-wince-base  package-wince-base-zip
767 # Clean up
768         rm -Rf $(top_builddir)/vlc-${VERSION}
769
770
771 package-beos:
772 # Check that tmp isn't in the way
773         @if test -e $(srcdir)/tmp; then \
774           echo "Error: please remove $(srcdir)/tmp, it is in the way"; \
775           false ; \
776         else \
777           echo "OK." ; mkdir $(srcdir)/tmp ; \
778         fi
779
780 # Copy relevant files
781         mkdir -p $(srcdir)/tmp/vlc ;
782         cd $(srcdir) && cp -R vlc-bundle/* AUTHORS COPYING ChangeLog README \
783           THANKS NEWS tmp/vlc/ ;
784
785 # Create debug package
786         xres -o $(srcdir)/tmp/vlc/vlc $(srcdir)/share/vlc_beos.rsrc ;
787         find $(srcdir)/tmp/vlc -exec mimeset -f {} \; ;
788         mv $(srcdir)/tmp/vlc $(srcdir)/tmp/vlc-${VERSION} ;
789         (cd $(srcdir)/tmp ; zip -9 -r vlc-${VERSION}-BeOS-debug.zip vlc-${VERSION} )
790         mv $(srcdir)/tmp/vlc-${VERSION}-BeOS-debug.zip $(srcdir)/ ;
791         mv $(srcdir)/tmp/vlc-${VERSION} $(srcdir)/tmp/vlc ;
792
793 # Create normal package
794         $(STRIP) --strip-debug --strip-unneeded $(srcdir)/tmp/vlc/vlc ;
795         find $(srcdir)/tmp/vlc -name 'lib*.so' -exec $(STRIP) \
796           --strip-debug --strip-unneeded "{}" \; ;
797         xres -o $(srcdir)/tmp/vlc/vlc $(srcdir)/share/vlc_beos.rsrc ;
798         find $(srcdir)/tmp/vlc -exec mimeset -f {} \; ;
799         mv $(srcdir)/tmp/vlc $(srcdir)/tmp/vlc-${VERSION} ;
800         (cd $(srcdir)/tmp ; zip -9 -r vlc-${VERSION}-BeOS.zip vlc-${VERSION} )
801         mv $(srcdir)/tmp/vlc-${VERSION}-BeOS.zip $(srcdir)/ ;
802
803 # Clean up
804         rm -Rf $(srcdir)/tmp ;
805
806 package-macosx:
807 # Check that the temporary location isn't in the way
808         @if test -e "$(top_builddir)/vlc-${VERSION}/"; then \
809           rm -Rf "$(top_builddir)/vlc-${VERSION}/" ; \
810         fi
811
812         echo "Create package directory: vlc-${VERSION}/";
813         mkdir -p "$(top_builddir)/vlc-${VERSION}/";
814
815 # Copy relevant files 
816         cp -R "$(top_builddir)/VLC-release.app" "$(top_builddir)/vlc-${VERSION}/VLC.app"
817         cd "$(srcdir)" && cp AUTHORS COPYING ChangeLog README README.MacOSX.rtf THANKS NEWS $(top_builddir)/vlc-${VERSION}/ && cp -R extras/MacOSX/Delete_Preferences.app $(top_builddir)/vlc-${VERSION}/
818
819 # Create disk image 
820         echo "Creating disk image" ;
821         rm -f "$(top_builddir)/vlc-${VERSION}.dmg" ;
822         hdiutil create -srcfolder "$(top_builddir)/vlc-${VERSION}" \
823           "$(top_builddir)/vlc-${VERSION}.dmg" -format UDZO -quiet ;
824         echo; echo "Disk image creation completed:" ;
825         ls -la "$(top_builddir)/vlc-${VERSION}.dmg" ; echo ;
826
827 # Clean up
828         rm -Rf "$(top_builddir)/vlc-${VERSION}" ;
829
830 package-translations:
831         @if test -e "$(srcdir)/vlc-translations-${VERSION}"; then \
832           echo "Error: please remove $(srcdir)/vlc-translations-${VERSION}, it is in the way"; \
833           false; \
834         else \
835           echo "OK."; mkdir -p "$(srcdir)/vlc-translations-${VERSION}"; \
836         fi
837 # Copy translations
838         for i in $(ALL_LINGUAS); do \
839           cp "$(srcdir)/po/$${i}.po" \
840             "$(srcdir)/vlc-translations-${VERSION}/$${i}.po" \
841             || true ; \
842         done
843         cp "$(srcdir)/doc/translations.txt" \
844           "$(srcdir)/vlc-translations-${VERSION}/README.txt"
845
846         echo "#!/bin/sh" >>"$(srcdir)/vlc-translations-$(VERSION)/convert.po.sh"
847         echo "" >>"$(srcdir)/vlc-translations-$(VERSION)/convert.po.sh"
848         echo 'if test $$# != 1; then' >>"$(srcdir)/vlc-translations-$(VERSION)/convert.po.sh"
849         echo "  echo \"Usage: convert-po.sh <.po file>\"" >>"$(srcdir)/vlc-translations-$(VERSION)/convert.po.sh"
850         echo "  exit 1" >>"$(srcdir)/vlc-translations-$(VERSION)/convert.po.sh"
851         echo "fi" >>"$(srcdir)/vlc-translations-$(VERSION)/convert.po.sh"
852         echo "" >>"$(srcdir)/vlc-translations-$(VERSION)/convert.po.sh"
853         echo 'msgfmt --statistics -o vlc.mo $$1' >>"$(srcdir)/vlc-translations-$(VERSION)/convert.po.sh"
854
855         $(AMTAR) chof - $(srcdir)/vlc-translations-$(VERSION) \
856           | GZIP=$(GZIP_ENV) gzip -c >$(srcdir)/vlc-translations-$(VERSION).tar.gz
857
858 ###############################################################################
859 # PO translation files update
860 ###############################################################################
861 .PHONY: update-po
862
863 update-po:
864         rm -f $(top_srcdir)/po/POTFILES.in
865         { \
866           cd $(top_srcdir) ; \
867           echo "# automatically created by make update-po" ; \
868           echo "" ; \
869           echo "# main sources" ; \
870           find include src -name '*.[chm]' -o -name '*.[ch]pp' \
871             | grep -v '\(vlc_symbols\|misc/modules_\|src/misc/version.c\)' \
872             | sort ; \
873           echo "" ; \
874           echo "# modules" ; \
875           find modules -name '*.[chm]' -o -name '*.[ch]pp' \
876             | grep -v '\(\.moc\.\|gui/gtk2/\)' \
877             | sort ; \
878         } > $(top_srcdir)/po/POTFILES.in
879         rm -f $(top_srcdir)/po/vlc.pot
880         cd po && $(MAKE) POTFILES vlc.pot update-po
881
882 #cd po && $(MAKE) update-po
883
884 ###############################################################################
885 # Stamp rules
886 ###############################################################################
887 stamp-builtin: FORCE
888         @for dep in "" `$(VLC_CONFIG) --target builtin`; do \
889           if test "$${dep}" -nt "$(top_builddir)/vlc$(EXEEXT)"; then \
890             rm -f $@; \
891             break; \
892           fi; \
893         done
894         @if test ! -f $@; then printf "" > $@; fi
895
896 ###############################################################################
897 # Enforce Mac OS X deployment target environment variable
898 ###############################################################################
899 macosx-sdk: Makefile.in $(HEADERS_include) vlc-config vlc-api.pl
900         export MACOSX_DEPLOYMENT_TARGET=$(MACOSX_DEPLOYMENT_TARGET)
901
902 ###############################################################################
903 # Force rule
904 ###############################################################################
905 FORCE: