Skip to content

Commit bdd9fd7

Browse files
authored
Update min Unity version and remove dotnet 3 support (#485)
* Remove dotnet 3 support * Update testapp readmes * Add missing newline
1 parent c3b46b4 commit bdd9fd7

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

48 files changed

+31
-1592
lines changed

analytics/CMakeLists.txt

-2
Original file line numberDiff line numberDiff line change
@@ -43,8 +43,6 @@ mono_add_library(firebase_analytics_cs
4343
${firebase_analytics_src}
4444
${firebase_analytics_swig_gen_src}
4545
REFERENCES
46-
unity_compat_cs
47-
unity_tasks_cs
4846
${FIREBASE_PLATFORM_REF}
4947
DEPENDS
5048
firebase_analytics_swig

analytics/testapp/readme.md

+2-14
Original file line numberDiff line numberDiff line change
@@ -51,13 +51,7 @@ with the
5151
- Import the `Firebase Analytics` plugin.
5252
- Select the **Assets > Import Package > Custom Package** menu item.
5353
- From the [Firebase Unity SDK](https://firebase.google.com/download/unity)
54-
downloaded previously, import `FirebaseAnalytics.unitypackage` from the
55-
directory that matches the version of Unity you use:
56-
- Unity 5.x and earlier use the .NET 3.x framework, so you need to
57-
import the `dotnet3/FirebaseAnalytics.unitypackage` package .
58-
- Unity 2017.x and newer allow the use of the .NET 4.x framework. If
59-
your project is configured to use .NET 4.x, import the
60-
`dotnet4/FirebaseAnalytics.unitypackage` package.
54+
downloaded previously, import `FirebaseAnalytics.unitypackage`.
6155
- When the **Import Unity Package** window appears, click the **Import**
6256
button.
6357
- Add the `GoogleService-Info.plist` file to the project.
@@ -143,13 +137,7 @@ with the
143137
- Import the `Firebase Analytics` plugin.
144138
- Select the **Assets > Import Package > Custom Package** menu item.
145139
- From the [Firebase Unity SDK](https://firebase.google.com/download/unity)
146-
downloaded previously, import `FirebaseAnalytics.unitypackage` from the
147-
directory that matches the version of Unity you use:
148-
- Unity 5.x and earlier use the .NET 3.x framework, so you need to
149-
import the `dotnet3/FirebaseAnalytics.unitypackage` package .
150-
- Unity 2017.x and newer allow the use of the .NET 4.x framework. If
151-
your project is configured to use .NET 4.x, import the
152-
`dotnet4/FirebaseAnalytics.unitypackage` package.
140+
downloaded previously, import `FirebaseAnalytics.unitypackage`.
153141
- When the **Import Unity Package** window appears, click the **Import**
154142
button.
155143
- Add the `google-services.json` file to the project.

app/CMakeLists.txt

-2
Original file line numberDiff line numberDiff line change
@@ -95,8 +95,6 @@ mono_add_library(firebase_app_cs
9595
${firebase_app_swig_gen_src}
9696
${version_info_file}
9797
REFERENCES
98-
unity_compat_cs
99-
unity_tasks_cs
10098
${firebase_platform_task_lib}
10199
firebase_platform_cs
102100
firebase_taskextension_cs

app/platform/CMakeLists.txt

-2
Original file line numberDiff line numberDiff line change
@@ -64,8 +64,6 @@ mono_add_library(firebase_platform_cs
6464
${firebase_platform_src}
6565
REFERENCES
6666
google_minijson_cs
67-
unity_compat_cs
68-
unity_tasks_cs
6967
${firebase_platform_task_lib}
7068
)
7169

app/task_extension/CMakeLists.txt

-2
Original file line numberDiff line numberDiff line change
@@ -24,8 +24,6 @@ mono_add_library(firebase_taskextension_cs
2424
SOURCES
2525
${firebase_taskextension_src}
2626
REFERENCES
27-
unity_compat_cs
28-
unity_tasks_cs
2927
${firebase_platform_task_lib}
3028
firebase_platform_cs
3129
XBUILD_EXE

auth/CMakeLists.txt

-2
Original file line numberDiff line numberDiff line change
@@ -57,8 +57,6 @@ mono_add_library(firebase_auth_cs
5757
${firebase_auth_src}
5858
${firebase_auth_swig_gen_src}
5959
REFERENCES
60-
unity_compat_cs
61-
unity_tasks_cs
6260
${FIREBASE_PLATFORM_REF}
6361
DEPENDS
6462
firebase_auth_swig

auth/testapp/readme.md

+2-14
Original file line numberDiff line numberDiff line change
@@ -57,13 +57,7 @@ with the
5757
- Import the `Firebase Auth` plugin.
5858
- Select the **Assets > Import Package > Custom Package** menu item.
5959
- From the [Firebase Unity SDK](https://firebase.google.com/download/unity)
60-
downloaded previously, import `FirebaseAuth.unitypackage` from the
61-
directory that matches the version of Unity you use:
62-
- Unity 5.x and earlier use the .NET 3.x framework, so you need to
63-
import the `dotnet3/FirebaseAuth.unitypackage` package .
64-
- Unity 2017.x and newer allow the use of the .NET 4.x framework. If
65-
your project is configured to use .NET 4.x, import the
66-
`dotnet4/FirebaseAuth.unitypackage` package.
60+
downloaded previously, import `FirebaseAuth.unitypackage`.
6761
- When the **Import Unity Package** window appears, click the **Import**
6862
button.
6963
- Add the `GoogleService-Info.plist` file to the project.
@@ -157,13 +151,7 @@ with the
157151
- Import the `Firebase Auth` plugin.
158152
- Select the **Assets > Import Package > Custom Package** menu item.
159153
- From the [Firebase Unity SDK](https://firebase.google.com/download/unity)
160-
downloaded previously, import `FirebaseAuth.unitypackage` from the
161-
directory that matches the version of Unity you use:
162-
- Unity 5.x and earlier use the .NET 3.x framework, so you need to
163-
import the `dotnet3/FirebaseAuth.unitypackage` package .
164-
- Unity 2017.x and newer allow the use of the .NET 4.x framework. If
165-
your project is configured to use .NET 4.x, import the
166-
`dotnet4/FirebaseAuth.unitypackage` package.
154+
downloaded previously, import `FirebaseAuth.unitypackage`.
167155
- When the **Import Unity Package** window appears, click the **Import**
168156
button.
169157
- Add the `google-services.json` file to the project.

cmake/external/CMakeLists.txt

-1
Original file line numberDiff line numberDiff line change
@@ -25,4 +25,3 @@ list(APPEND CMAKE_MODULE_PATH ${CMAKE_CURRENT_LIST_DIR})
2525
include(firebase_cpp_sdk)
2626
include(google_unity_jar_resolver)
2727
include(minijson)
28-
include(parse)

cmake/external/parse.cmake

-34
This file was deleted.

cmake/unity_mono.cmake

+2-2
Original file line numberDiff line numberDiff line change
@@ -199,7 +199,7 @@ endmacro()
199199
# sys_references: System CSharp libraries this depends on
200200
# dep_targets: Targets this target depends on and need to be linked/built first
201201
# guid: MSBuild project guid (for use with solution files)
202-
# framework_version: .net framework version, defaults to 3.5
202+
# framework_version: .net framework version, defaults to 4.5
203203
# defines: Extra defines to add to the project file
204204
# assembly_name: Name of the output assembly. Defaults to module
205205
# xbuild: Path to xbuild executable. Defaults to XBUILD_EXE global var
@@ -250,7 +250,7 @@ macro(mono_add_internal name output_type)
250250
endif()
251251

252252
if ("${UNITY_MONO_FRAMEWORK_VERSION}" STREQUAL "")
253-
set(UNITY_MONO_FRAMEWORK_VERSION "3.5")
253+
set(UNITY_MONO_FRAMEWORK_VERSION "4.5")
254254
endif()
255255

256256
if ("${UNITY_MONO_ASSEMBLY_NAME}" STREQUAL "")

crashlytics/CMakeLists.txt

-2
Original file line numberDiff line numberDiff line change
@@ -87,8 +87,6 @@ mono_add_library(firebase_crashlytics_cs
8787
${firebase_crashlytics_src}
8888
${firebase_crashlytics_swig_gen_src}
8989
REFERENCES
90-
unity_compat_cs
91-
unity_tasks_cs
9290
${FIREBASE_PLATFORM_REF}
9391
DEPENDS
9492
firebase_crashlytics_swig

crashlytics/testapp/readme.md

+1-6
Original file line numberDiff line numberDiff line change
@@ -32,12 +32,7 @@ inside the Unity Editor.
3232
- Import the `Firebase Crashlytics` plugin.
3333
- Select the **Assets > Import Package > Custom Package** menu item.
3434
- From the [Firebase Unity SDK](https://firebase.google.com/download/unity)
35-
downloaded previously, import `FirebaseCrashlytics.unitypackage` from the
36-
directory that matches the version of Unity you use:
37-
- If your project is configured to use .NET 3.x, import the
38-
`dotnet3/FirebaseCrashlytics.unitypackage` package.
39-
- If your project is configured to use .NET 4.x, import the
40-
`dotnet4/FirebaseCrashlytics.unitypackage` package.
35+
downloaded previously, import `FirebaseCrashlytics.unitypackage`.
4136
- When the **Import Unity Package** window appears, click the **Import**
4237
button.
4338

database/CMakeLists.txt

-2
Original file line numberDiff line numberDiff line change
@@ -61,8 +61,6 @@ mono_add_library(firebase_database_cs
6161
${firebase_database_swig_gen_src}
6262
REFERENCES
6363
google_minijson_cs
64-
unity_compat_cs
65-
unity_tasks_cs
6664
${FIREBASE_PLATFORM_REF}
6765
DEPENDS
6866
firebase_database_swig

database/testapp/readme.md

+1-7
Original file line numberDiff line numberDiff line change
@@ -33,13 +33,7 @@ inside the Unity Editor.
3333
- Import the `Firebase Database` plugin.
3434
- Select the **Assets > Import Package > Custom Package** menu item.
3535
- From the [Firebase Unity SDK](https://firebase.google.com/download/unity)
36-
downloaded previously, import `FirebaseDatabase.unitypackage` from the
37-
directory that matches the version of Unity you use:
38-
- Unity 5.x and earlier use the .NET 3.x framework, so you need to
39-
import the `dotnet3/FirebaseDatabase.unitypackage` package .
40-
- Unity 2017.x and newer allow the use of the .NET 4.x framework. If
41-
your project is configured to use .NET 4.x, import the
42-
`dotnet4/FirebaseDatabase.unitypackage` package.
36+
downloaded previously, import `FirebaseDatabase.unitypackage`.
4337
- When the **Import Unity Package** window appears, click the **Import**
4438
button.
4539
- Turn off secure access. [Configure your rules for public access.](https://firebase.google.com/docs/database/security/quickstart#sample-rules)

docs/readme.md

+3-89
Original file line numberDiff line numberDiff line change
@@ -18,14 +18,7 @@ features on *iOS* and *Android*:
1818
| Firebase Remote Config | FirebaseRemoteConfig.unitypackage |
1919
| Firebase Storage | FirebaseStorage.unitypackage |
2020

21-
The SDK provides .NET 3.x and .NET 4.x compatible packages in the `dotnet3` and
22-
`dotnet4` directories of the SDK:
23-
24-
* Unity 5.x and earlier use the .NET 3.x framework, so you need to import
25-
packages from the `dotnet3` directory.
26-
* Unity 2017.x and newer allow the use of the .NET 4.x framework. If your
27-
project is configured to use .NET 4.x, import packages from the
28-
`dotnet4` directory.
21+
The SDK provides .NET 4.x compatible packages
2922

3023
## Desktop Workflow Implementations
3124

@@ -58,87 +51,6 @@ need to conditionally compile code when also targeting the desktop.
5851
The AdMob Unity plugin is distributed separately and is available from the
5952
[AdMob Get Started](https://firebase.google.com/docs/admob/unity/start) guide.
6053

61-
## Known Issues
62-
63-
### .NET 4.x compatibility when using Unity 2017.x and newer.
64-
65-
.NET 4.x support is available as a build option in Unity 2017 and newer.
66-
Firebase plugins use components of the
67-
[Parse SDK](https://github.com/parse-community/Parse-SDK-dotNET) to provide some
68-
.NET 4.x classes in earlier versions of .NET. Therefore, versions `5.4.0` and
69-
newer of the {{unity_sdk}} provide plugins that are compatible with either
70-
.NET 3.x or .NET 4.x in `dotnet3` and `dotnet4` directories of the
71-
{{unity_sdk_link}}.
72-
73-
If you import a Firebase plugin that is incompatible with the .NET version
74-
enabled in your project, you'll see compile errors from some types in the
75-
.NET framework that are implemented by the Parse SDK.
76-
77-
To resolve the compilation error, if you're using .NET 3.x:
78-
79-
1. Remove or disable the following DLLs for all platforms:
80-
- `Parse/Plugins/dotNet45/Unity.Compat.dll`
81-
- `Parse/Plugins/dotNet45/Unity.Tasks.dll`
82-
1. Enable the following DLLs for all platforms:
83-
- `Parse/Plugins/Unity.Compat.dll`
84-
- `Parse/Plugins/Unity.Tasks.dll`
85-
86-
To resolve the compilation error, if you're using .NET 4.x:
87-
88-
1. Remove or disable the following DLLs for all platforms:
89-
- `Parse/Plugins/Unity.Compat.dll`
90-
- `Parse/Plugins/Unity.Tasks.dll`
91-
1. Enable the following DLLs for all platforms:
92-
- `Parse/Plugins/dotNet45/Unity.Compat.dll`
93-
- `Parse/Plugins/dotNet45/Unity.Tasks.dll`
94-
95-
If you import another Firebase plugin:
96-
97-
- Select the menu item
98-
`Assets > Play Services Resolver > Version Handler > Update`
99-
to enable the correct DLLs for your project.
100-
101-
102-
### Unity 4 workarounds
103-
104-
Firebase plugins are not officially supported in Unity 4. However, we do
105-
make an effort to ensure the plugins can work with some manual setup.
106-
107-
A couple of components do not work in Unity 4:
108-
109-
- [Version Handler](https://github.com/googlesamples/unity-jar-resolver#unity-plugin-version-management)
110-
does not work due to no PluginImporter and no clean way to prevent managed
111-
DLLs from being loaded by Unity 4.
112-
- This means it's not possible for plugins to automatically enable the most
113-
recent version of shared components (e.g Firebase, AdMob, Facebook etc.
114-
may share a common component).
115-
- DLLs that target a specific .NET version (e.g .NET 4.x) are not disabled.
116-
- Managed (C#) DLLs cannot be targeted to a specific platform which breaks
117-
our plugin where we have platform specific C# DLLs for some components.
118-
119-
To use in Unity 4 you will need to:
120-
121-
- Resolve any dependencies that are shared between multiple plugins.
122-
For example, Firebase and AdMob use the
123-
[Play Services Resolver](https://github.com/googlesamples/unity-jar-resolver)
124-
which contains DLLs that encode the version in their filename under the
125-
folder `PlayServicesResolver/Editor`. For each versioned DLL under the
126-
folder `PlayServicesResolver/Editor` delete the oldest version of each DLL.
127-
- Remove .NET 4.x DLLs from `Parse/Plugins/dotNet45`.
128-
- Remove / rename platform specific DLLs.
129-
Firebase plugins contain iOS specific DLLs under the folder
130-
`Firebase/Plugins/iOS`.
131-
- When *not* building for iOS:
132-
- Change the extension of files under the `Firebase/Plugins/iOS` folder
133-
from `.dll` to `.dlldisabled`
134-
- When building for iOS:
135-
- Change the extension of files under the `Firebase/Plugins/iOS` folder
136-
from `.dlldisabled` to `.dll`
137-
- For each file in `Firebase/Plugins/iOS` change the file extension of
138-
the same name under `Firebase/Plugins` from `.dll` to `.dlldisabled`.
139-
For example, `Firebase/Plugins/iOS/Firebase.App.dll` and
140-
`Firebase/Plugins/Firebase.App.dlldisabled`.
141-
14254
Setup
14355
-----
14456

@@ -157,6 +69,8 @@ Release Notes
15769
-------------
15870
### Upcoming
15971
- Changes
72+
- General: Minimum supported editor version is now Unity 2019.
73+
- General: Removed dependency on Parse Tasks.
16074
- Auth (Android/iOS): Deprecate `PhoneAuthProvider.MaxTimeoutMs`. The actual
16175
range is determined by the underlying SDK, ex. [PhoneAuthOptions.Builder in Android SDK](https://firebase.google.com/docs/reference/android/com/google/firebase/auth/PhoneAuthOptions.Builder).
16276
- Remote Config: Improve performance when setting default parameters

dynamic_links/CMakeLists.txt

-2
Original file line numberDiff line numberDiff line change
@@ -55,8 +55,6 @@ mono_add_library(firebase_dynamic_links_cs
5555
${firebase_dynamic_links_src}
5656
${firebase_dynamic_links_swig_gen_src}
5757
REFERENCES
58-
unity_compat_cs
59-
unity_tasks_cs
6058
${FIREBASE_PLATFORM_REF}
6159
DEPENDS
6260
firebase_dynamic_links_swig

dynamic_links/testapp/readme.md

+2-14
Original file line numberDiff line numberDiff line change
@@ -52,13 +52,7 @@ using the
5252
- Import the `Firebase Dynamic Links` plugin.
5353
- Select the **Assets > Import Package > Custom Package** menu item.
5454
- From the [Firebase Unity SDK](https://firebase.google.com/download/unity)
55-
downloaded previously, import `FirebaseDynamicLinks.unitypackage` from the
56-
directory that matches the version of Unity you use:
57-
- Unity 5.x and earlier use the .NET 3.x framework, so you need to
58-
import the `dotnet3/FirebaseDynamicLinks.unitypackage` package .
59-
- Unity 2017.x and newer allow the use of the .NET 4.x framework. If
60-
your project is configured to use .NET 4.x, import the
61-
`dotnet4/FirebaseDynamicLinks.unitypackage` package.
55+
downloaded previously, import `FirebaseDynamicLinks.unitypackage`.
6256
- When the **Import Unity Package** window appears, click the **Import**
6357
button.
6458
- Add the `GoogleService-Info.plist` file to the project.
@@ -162,13 +156,7 @@ using the
162156
- Import the `Firebase Dynamic Links` plugin.
163157
- Select the **Assets > Import Package > Custom Package** menu item.
164158
- From the [Firebase Unity SDK](https://firebase.google.com/download/unity)
165-
downloaded previously, import `FirebaseDynamicLinks.unitypackage` from the
166-
directory that matches the version of Unity you use:
167-
- Unity 5.x and earlier use the .NET 3.x framework, so you need to
168-
import the `dotnet3/FirebaseDynamicLinks.unitypackage` package .
169-
- Unity 2017.x and newer allow the use of the .NET 4.x framework. If
170-
your project is configured to use .NET 4.x, import the
171-
`dotnet4/FirebaseDynamicLinks.unitypackage` package.
159+
downloaded previously, import `FirebaseDynamicLinks.unitypackage`.
172160
- When the **Import Unity Package** window appears, click the **Import**
173161
button.
174162
- Add the `google-services.json` file to the project.

0 commit comments

Comments
 (0)