* Window ๊ธฐ์ค์ผ๋ก ๊ธ์ ์์ฑํ์์ต๋๋ค.
๐Flutter SDK ์ค์น
Start building Flutter Android apps on Windows
Configure your system to develop Flutter mobile apps on Windows.
docs.flutter.dev
Flutter ์ฌ์ดํธ์ ์ ์ ํ ๊ฐ๋ฐํ๊ฒฝ์ ๋ง๋ ํ๋ซํผ์ ํด๋ฆญํด์ ์ ์ํ๋ค. (์ ๋งํฌ๋ Windows)
์ฌ์ดํธ์ ๋ฌด์์ ์ด๋ป๊ฒ ์ค์นํด์ผํ๋์ง ์ค๋ช ๋์ด์๋ค.
์คํฌ๋กค์ ๋ด๋ ค์ ์ต์ SDK๋ฅผ ๋ค์ด๋ฐ๋๋ค.
Flutter SDK archive
All current Flutter SDK releases: stable, beta, and main.
docs.flutter.dev
๋ค๋ฅธ ๋ฒ์ ์ ์ค์นํ๊ณ ์ถ๋ค๋ฉด SDK archive์ ์ ์ํด์ ์ํ๋ ๋ฒ์ ์ ๋ค์ด๋ฐ์ ์ ์๋ค.
๋ค์ด๋ฐ์ SDK ํ์ผ์ ์ฐ๋ํ๋ ์์น์ ์์ถํด์ ํ๋ค.
๋๋ C๋๋ผ์ด๋ธ ์๋์ flutter ํด๋๋ฅผ ์์ฑ ํ ์์ถ ํด์ ํ๋ค.
๐Windows Path Variable ์ค์
C:\flutter\bin\flutter.bat
์ด ํ์ผ์ ์๋์ฐ ์ ์ญ์์ ์ฌ์ฉํ๊ธฐ ์ํด ์์คํ ํ๊ฒฝ๋ณ์ ์ค์ ์ ํด์ค์ผํ๋ค.
์ด ์ญ์๋ ์ ์ผ ์์ ๊ฑธ์ด๋ Flutter ๋งํฌ์ ๋ค์ด๊ฐ๋ฉด ๋ฐฉ๋ฒ์ด ๋์์๋ค.
ํ๋์ฉ ํด๋ณด์.
1๋ฒ, 2๋ฒ์ฒ๋ผ ๋ค์ด๊ฐ๊ฑฐ๋, ์์์ฐฝ์ '์์คํ ํ๊ฒฝ ๋ณ์ ํธ์ง'์ ๊ฒ์ํด์ '์์คํ ์์ฑ' ์ฐฝ์ ๋์ด๋ค
ํ๊ฒฝ๋ณ์ → Path → ํธ์ง → ์๋ก๋ง๋ค๊ธฐ → 'C:\flutter\bin' ์ถ๊ฐ
Window+R ํค๋ฅผ ๋๋ฅธ ํ, 'cmd'๋ฅผ ์ ๋ ฅํด์ ์ปค๋งจ๋์ฐฝ์ ์ฐ๋ค.
flutter --version
๋ช ๋ น์ด๋ฅผ ์ ๋ ฅํ๋ค.
๋ด๊ฐ ๋ค์ด๋ฐ์ ๋ฒ์ ์ผ๋ก ์ค์น๋ ๊ฒ์ ํ์ธํ ์ ์๋ค.
flutter doctor๋ Flutter ๊ฐ๋ฐ ํ๊ฒฝ์ ๋ชจ๋ ๊ตฌ์ฑ ์์๊ฐ ์ฌ๋ฐ๋ฅธ์ง ํ์ธํ๋ ๋ช ๋ น์ด๋ค.
์๋๋ก์ด๋ ํด์ฒด์ธ์ด ์์ผ๋ ์ค์นํด์ผํ๋ค.
๐Android Studio
โญ์๋๋ก์ด๋ ์คํ๋์ค ์ค์น
Android ์คํ๋์ค ๋ฐ ์ฑ ๋๊ตฌ ๋ค์ด๋ก๋ - Android ๊ฐ๋ฐ์ | Android Studio | Android Developers
Android Studio provides app builders with an integrated development environment (IDE) optimized for Android apps. Download Android Studio today.
developer.android.com
์๋๋ก์ด๋ ์คํ๋์ค ์ฌ์ดํธ์ ๋ค์ด๊ฐ์ ๋ค์ด๋ฐ๋๋ค.
์ค์นํ ๋ ์ต์ ์ ๋ฐ๋ก ๊ฑด๋๋ฆฌ์ง ์์๋ค.
โญAndroid toolchain ์ค์น
More Action → SDK Manager → SDK Tools → Android SDK Command-line Tools ์ฒดํฌ → Apply → ์ค์น ํ OK ๋ฒํผ ํด๋ฆญ
flutter doctor ๋ช ๋ น์ด๋ฅผ ๋ค์ ์ ๋ ฅํด๋ณด๋ฉด, Some Android licenses not accepted ๋ฌธ๊ตฌ๊ฐ ๋ฌ๋ค.
๋ค์ ํด๊ฒฐ๋ฒ๊น์ง ์ ํ์๋ค.
flutter doctor --android-licenses
๋ช ๋ น์ด๋ฅผ ์ ๋ ฅํ๊ณ , ๋ค์ ๋์ค๋ ๋ชจ๋ ๋ฌผ์์ y๋ฅผ ์ ๋ ฅํด์ค๋ค.
๊ทธ๋ฌ๋ฉด All SDK package licenses accepted ๋ฌธ๊ตฌ๊ฐ ๋ฌ๋ค.
๋ค์ flutter doctor ๋ช ๋ น์ด๋ฅผ ์ ๋ ฅํ๋ฉด, android toolchain ์ค์น๊ฐ ์๋ฃ๋ ๊ฒ์ ํ์ธํ ์ ์๋ค.
์ด์ Visual Studio ์ค์น๋ฅผ ํ๋ฉด ๋๋ค.
๐ Visual Studio
๋ฌด๋ฃ ๊ฐ๋ฐ์ ์ํํธ์จ์ด ๋ฐ ์๋น์ค - Visual Studio
๋ฌด๋ฃ ์ ๊ณต: Visual Studio Community, Visual Studio Code, VSTS ๋ฐ Dev Essentials.
visualstudio.microsoft.com
์ฌ์ดํธ ์ ์ ํ Visual Studio Community๋ฅผ ๋ค์ด๋ฐ๋๋ค.
์ด๋ฏธ ์ค์น๊ฐ ๋์ด์๋ค๋ฉด Visual Studio Installer ํ์ผ์ ์คํ์ํค๊ณ ,
์ค์น๋์ด์๋ ๋ฒ์ ์ฐ์ธก์ ์๋ ์์ ๋ฒํผ์ ๋๋ฅธ๋ค.
C++๋ฅผ ์ฌ์ฉํ ๋ฐ์คํฌํฑ ๊ฐ๋ฐ ํด๋ฆญ ํ ์์ ๋ฒํผ์ ๋๋ฌ ์ค์นํ๋ค.
๋๋ ์ด๋ฏธ ์ค์น๊ฐ ๋์ด์์ด์ ์ธ์ฒดํฌ ํ ๋ค์ ์ฒดํฌํด์ ์ค์นํด์ฃผ์๋ค.
์ค์น ํ ๋ค์ ํ์ธํด๋ณด๋ฉด ๋ชจ๋ ์ฒดํฌํ์๊ฐ ๋ฌ ๊ฒ์ ๋ณผ ์ ์๋ค.
๐Flutter ํ๋ก์ ํธ ์์ฑ
Android Studio ์คํ → Plugins → Flutter, Dart ์ค์น
Project ํญ์ผ๋ก ๋ค์ด๊ฐ๋๋ ์ฌ์์ ํ์ ์ฐฝ์ด ๋ ์, ์ฌ์์๋ ํด์คฌ๋ค.
Projects → New Flutter Project
Flutter → ... ๋ฒํผ ํด๋ฆญ ํ SDK ๊ฒฝ๋ก ์ค์ (๋๋ C:\flutter ๊ฒฝ๋ก๋ฅผ ์ ๋ ฅํ๋ค.)
Next ๋ฒํผ ํด๋ฆญ
ํ๋ก์ ํธ ์ด๋ฆ ์ ์ด์ค ํ Create ๋ฒํผ ํด๋ฆญ
์ข์ธก์ lib ํด๋ ์์ main.dart ํ์ผ์ ์ฝ๋๋ฅผ ์์ฑํด์ฃผ๋ฉด ๋๋ค.
์๋จ์์ ์ฌ์๋ฒํผ์ ๋๋ฅด๋ฉด ์คํํด๋ณผ ์ ์๋ค.
๐VS Code ์ฌ์ฉํ๋ ๋ฐฉ๋ฒ
๊ฐ์ธ์ ์ผ๋ก vs code๋ฅผ ์ข์ํด์, ์๋๋ก์ด๋์คํ๋์ค ๋์ vscode๋ฅผ ์ฌ์ฉํ ์ ์๋ ๋ฐฉ๋ฒ์ ๋ํด ์์๋ดค๋ค.
vscode๋ก ์์์ ์์ฑํ ํ๋ก์ ํธ๋ฅผ ์ฐ๋ค.
main.dart ํ์ผ์ ์ฐํด๋ฆญํ ํ Run Without Debugging ์ ํด๋ฆญํ๋ฉด ์คํํด๋ณผ ์ ์๋ค.
F5 ํค๋ฅผ ๋๋ฌ ๋๋ฒ๊น ์ ์คํํ ์๋ ์๋ค.
โญextension
ํ์ ํ์ฅํ๋ก๊ทธ๋จ : Flutter
์ ์ฉํ ํ์ฅํ๋ก๊ทธ๋จ : (์ฌ์ฉํด๋ณด๋ฉด์ ์ถ๊ฐํ ์์ )
'๐ฑFlutter' ์นดํ ๊ณ ๋ฆฌ์ ๋ค๋ฅธ ๊ธ
[Flutter] ์ ๋ฌธ : ๋ก๋๋งต (2) | 2025.08.27 |
---|