OSDN Git Service

Makefile fixes. Official stable releases are now built with the "make official" targe...
[handbrake-jp/handbrake-jp-git.git] / Makefile
index b2849f2..10a1a76 100644 (file)
--- a/Makefile
+++ b/Makefile
@@ -9,7 +9,11 @@ SYSTEM = $(shell uname -s)
 #
 ifeq ($(SYSTEM),Darwin)
 
-snapshot:   clean snapshot-app
+snapshot:   clean unstable-libhb/hbversion.h snapshot-app
+official:   clean force-hbversion app
+
+force-hbversion:
+       rm -f libhb/hbversion.h
 
 all:    clean app
 
@@ -19,13 +23,16 @@ test:       clean cli
 
 dev:   clean internal
 
-app:    libhb/hbversion.h
+ub-app:    libhb/hbversion.h
        (./DownloadMacOsXContribBinaries.sh ; cd macosx ; xcodebuild -target libhb -target HandBrake -target HandBrakeCLI -configuration UB HB_BUILD="$(HB_BUILD)" HB_VERSION="$(HB_VERSION)" APPCAST_URL="http://handbrake.fr/appcast.xml" build | sed '/^$$/d'  )
 
+app: contrib/.contrib libhb/hbversion.h
+               ( cd macosx ; xcodebuild -target libhb -target HandBrake -target HandBrakeCLI -configuration Deployment HB_BUILD="$(HB_BUILD)" HB_VERSION="$(HB_VERSION)" CURRENT_PROJECT_VERSION="$(HB_VERSION)" APPCAST_URL="http://handbrake.fr/appcast.xml" build | sed '/^$$/d' )
+
 contrib/.contrib:
        @$(MAKE) --no-print-directory -C contrib all
 
-snapshot-app: contrib/.contrib unstable-libhb/hbversion.h
+snapshot-app: contrib/.contrib libhb/hbversion.h
        ( cd macosx ; xcodebuild -target libhb -target HandBrake -target HandBrakeCLI -configuration Deployment HB_BUILD="$(SNAP_HB_BUILD)" HB_VERSION="$(SNAP_HB_VERSION)" CURRENT_PROJECT_VERSION="$(SNAP_HB_VERSION)" APPCAST_URL="http://handbrake.fr/appcast_unstable.xml" build | sed '/^$$/d' )
 
 app-chunky: libhb/hbversion.h
@@ -35,7 +42,7 @@ cli:    libhb/hbversion.h
        (./DownloadMacOsXContribBinaries.sh ; cd macosx ; xcodebuild -target libhb -target HandBrakeCLI -configuration UB HB_BUILD="$(HB_BUILD)" HB_VERSION="$(HB_VERSION)" build | sed '/^$$/d' )
 
 clean:
-       (cd macosx ; xcodebuild -alltargets -configuration UB clean | sed '/^$$/d' ; rm -f libhb/hbversion.h )
+       (cd macosx ; xcodebuild -alltargets -configuration UB clean | sed '/^$$/d' ; rm -f libhb/hbversion.h ; rm -f contrib/config.cache )
 
 mrproper:
        (rm -rf libhb/hbversion.h contrib/*tar.gz contrib/include contrib/lib contrib/DarwinContribVersion.txt ; cd macosx ; xcodebuild -alltargets -configuration UB clean | sed '/^$$/d' )
@@ -62,22 +69,30 @@ endif
 #
 ifeq ($(SYSTEM),Linux)
 
-all:   contrib/.contrib libhb/libhb.a HandBrakeCLI
-       (rm -rf HandBrake HandBrake*.tar.gz ; mkdir -p HandBrake/api HandBrake/doc; cp test/BUILDSHARED AUTHORS BUILD COPYING CREDITS NEWS THANKS TRANSLATIONS HandBrake/doc ;  cp -rp libhb/libhb.so HandBrake/api ; cp -rp libhb/hb.h libhb/common.h libhb/ports.h HandBrake/api ; cp -rp HandBrakeCLI HandBrake ; tar zcvf HandBrake-$(HB_VERSION)_i386.tar.gz HandBrake ; rm -rf HandBrake )
+snapshot: unstable-libhb/hbversion.h all
+
+official: force-hbversion all
+
+force-hbversion:
+       rm -f libhb/hbversion.h
+
+all:   contrib/.contrib libhb/hbversion.h HandBrakeCLI
+       (rm -rf HandBrake HandBrake*.tar.gz ; mkdir -p HandBrake/api HandBrake/doc; cp test/BUILDSHARED AUTHORS BUILD COPYING CREDITS NEWS THANKS TRANSLATIONS HandBrake/doc ;  cp -rp libhb/hb.h libhb/common.h libhb/ports.h HandBrake/api ; cp -rp HandBrakeCLI HandBrake ; tar zcvf HandBrake-$(HB_VERSION)_i386.tar.gz HandBrake ; rm -rf HandBrake )
 
 contrib/.contrib:
        @$(MAKE) --no-print-directory -C contrib all
 
-libhb/libhb.a: unstable-libhb/hbversion.h
+libhb/libhb.a: libhb/hbversion.h
        @$(MAKE) --no-print-directory -C libhb all
 
-HandBrakeCLI:
+HandBrakeCLI: libhb/libhb.a
        @$(MAKE) --no-print-directory -C test all
 
 clean:
        @$(MAKE) --no-print-directory -C libhb clean
        @$(MAKE) --no-print-directory -C test clean
        @rm libhb/hbversion.h
+       @rm -f contrib/config.cache
 
 mrproper: clean
        @$(MAKE) --no-print-directory -C contrib mrproper
@@ -89,20 +104,15 @@ endif
 #
 ifeq ($(findstring CYGWIN_NT,$(SYSTEM)),CYGWIN_NT)
 
-all:    contrib/.contrib libhb/libhb.a HandBrakeCLI
+all:    contrib/.contrib HandBrakeCLI
 
-app:   contribPack libhb/libhb.a HandBrakeCLI
-
-contribPack:
-       (./DownloadCygWinContribBinaries.sh)
-       
 contrib/.contrib:
        @$(MAKE) --no-print-directory -C contrib all
 
 libhb/libhb.a: unstable-libhb/hbversion.h
        @$(MAKE) --no-print-directory -C libhb all
 
-HandBrakeCLI: 
+HandBrakeCLI: libhb/libhb.a
        @$(MAKE) --no-print-directory -C test all
        
 clean: