Skip to content

Commit

Permalink
[release] Always create bundle.zip. (#16355)
Browse files Browse the repository at this point in the history
We need to create a bundle.zip file even if we don't build for iOS (if for
instance we build for tvOS only).
  • Loading branch information
rolfbjarne authored Oct 17, 2022
1 parent 746cefd commit 3f0c896
Showing 1 changed file with 10 additions and 4 deletions.
14 changes: 10 additions & 4 deletions release/Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -43,8 +43,8 @@ ifdef INCLUDE_MAC
endif
ifdef INCLUDE_IOS
$(Q) cp $(IOS_PACKAGE_DESTDIR)/$(IOS_FRAMEWORK_DIR)/Versions/Current/updateinfo ios-updateinfo
$(MAKE) bundle.zip msbuild.zip
endif
$(MAKE) bundle.zip msbuild.zip

# this are just a useful targets to run locally if you're not interested in the XI/XM package
# it should be almost identical to the normal 'package' target (only difference should be that the XM/XI
Expand Down Expand Up @@ -156,7 +156,9 @@ msbuild.zip:
mkdir -p msbuild/maccore/src
mkdir -p msbuild/maccore/tools/mtouch
mkdir -p msbuild/maccore/msbuild/Xamarin.ObjcBinding.Tasks
ifdef INCLUDE_IOS
cp -aL $(TOP)/src/Constants.iOS.cs.in msbuild/maccore/src/Constants.cs
endif
$(SYSTEM_MSBUILD) $(TOP)/msbuild/Xamarin.iOS.Tasks/Xamarin.iOS.Tasks.csproj -r /p:Configuration=Release /p:"IncludeMSBuildAssets=all"
cp -R $(TOP)/msbuild/Xamarin.iOS.Tasks/bin/Release/netstandard2.0/ msbuild/iOS
$(SYSTEM_MSBUILD) $(TOP)/msbuild/Xamarin.iOS.Tasks.Windows/Xamarin.iOS.Tasks.Windows.csproj -r /p:Configuration=Release
Expand All @@ -173,9 +175,13 @@ endif

bundle.zip: Version Version.rev
rm -f $@
cd $(MAC_DESTDIR)/Library/Frameworks/Xamarin.Mac.framework/Versions/Current/lib/mono && zip -9 -r $(CURDIR)/bundle.zip .
cd $(IOS_DESTDIR)/Library/Frameworks/Xamarin.iOS.framework/Versions/Current/lib/mono && zip -9 -r $(CURDIR)/bundle.zip .
cd $(DOTNET_DESTDIR) && zip -9 -r $(CURDIR)/bundle.zip $(foreach platform,$(DOTNET_PLATFORMS),./Microsoft.$(platform).Ref/ref/)
ifdef INCLUDE_XAMARIN_LEGACY
if test -d $(MAC_DESTDIR)/Library/Frameworks/Xamarin.Mac.framework/Versions/Current/lib/mono; then cd $(MAC_DESTDIR)/Library/Frameworks/Xamarin.Mac.framework/Versions/Current/lib/mono && zip -9 -r $(CURDIR)/bundle.zip .; fi
if test -d $(IOS_DESTDIR)/Library/Frameworks/Xamarin.iOS.framework/Versions/Current/lib/mono; then cd $(IOS_DESTDIR)/Library/Frameworks/Xamarin.iOS.framework/Versions/Current/lib/mono && zip -9 -r $(CURDIR)/bundle.zip .; fi
endif
ifdef ENABLE_DOTNET
cd $(DOTNET_DESTDIR) && zip -9 -r $(CURDIR)/bundle.zip $(foreach platform,$(DOTNET_PLATFORMS),./Microsoft.$(platform).Ref/ref/)
endif
zip -9 $@ Version Version.rev

Version:
Expand Down

4 comments on commit 3f0c896

@vs-mobiletools-engineering-service2

This comment was marked as outdated.

@vs-mobiletools-engineering-service2

This comment was marked as outdated.

@vs-mobiletools-engineering-service2

This comment was marked as outdated.

@vs-mobiletools-engineering-service2

This comment was marked as outdated.

Please sign in to comment.