๋ณธ๋ฌธ ๋ฐ”๋กœ๊ฐ€๊ธฐ
ํˆด๋“ค

Visual studio ์›๊ฒฉ ๋””๋ ‰ํ† ๋ฆฌ ๋ณต์‚ฌ (์‹คํŒจ)

by ์ด๋…ธํ‚ค_ 2021. 4. 14.

ํ˜„์žฌ ์‚ฌ์šฉ์ค‘์ธ vs 2017์€ ํฌ๋กœ์Šคํ”Œ๋žซํผ์„ ์ง€์›ํ•ด์ค€๋‹ค.
์œˆ๋„์šฐ์—์„œ vs๋ฅผ ์‚ฌ์šฉ์ค‘์ด๋”๋ผ๋„ ๋ฆฌ๋ˆ…์Šค๋‚˜ ๋งฅ์„ ํƒ€๊ฒŸ PC๋กœ ์„ค์ •ํ•˜์—ฌ ์ปดํŒŒ์ผ ๋ฐ ๋นŒ๋“œ๋ฅผ ํ•ด์ฃผ๊ฒ ๋‹ค๋Š” ๊ฒƒ!
์ž‘๋…„ ํ”„๋กœ์ ํŠธ๋ถ€ํ„ฐ ์˜ฌํ•ด ํ”„๋กœ์ ํŠธ๊นŒ์ง€ ์ž˜ ํ™œ์šฉํ•˜๊ณ  ์žˆ์—ˆ๋‹ค. 
๊ฐœ๋ฐœPC๋Š” ์œˆ๋„์šฐ์ด๊ณ  ์‹ค์ œ ์„œ๋น„์Šคํ•  ์žฅ๋น„๋Š” ์šฐ๋ถ„ํˆฌ.
ํ”„๋กœ๊ทธ๋žจ ์‹คํ–‰์„ ์œ„ํ•ด ์„ค์ • ํŒŒ์ผ ๋ช‡๊ฐ€์ง€๋“ค์€ ์›๊ฒฉ๋ณต์‚ฌ๊ฐ€ ์ž˜ ๋˜์—ˆ๋‹ค. 
ํ•˜์ง€๋งŒ ๋””๋ ‰ํ† ๋ฆฌ ๋ณต์‚ฌ๋ฅผ ์œ„ํ•ด ์—ฌ๋Ÿฌ๊ฐ€์ง€ ์„ค์ •์„ ๊ฑด๋“œ๋ ค๋ดค์ง€๋งŒ ๊ฒฐ๊ตญ ์‹คํŒจํ–ˆ๋‹ค. 
์‚ฌ์‹ค ๊ฐ€๋Šฅํ•œ ๋ฐฉ๋ฒ•์€ ํ•˜๋‚˜ ์žˆ๊ธด ํ•˜๋‹ค.
ํ”„๋กœ์ ํŠธ ํŠธ๋ฆฌ์— ํด๋”๋ฅผ ํ•˜๋‚˜ ์ถ”๊ฐ€ํ•˜์—ฌ ๊ฑฐ๊ธฐ์— ๋ณต์‚ฌํ•˜๊ณ ์žํ•˜๋Š” ๋””๋ ‰ํ† ๋ฆฌ๋ฅผ ์ง‘์–ด๋„ฃ์œผ๋ฉด ๋œ๋‹ค. ๊ทธ๋Ÿผ ๋‹ค ๋ณต์‚ฌ๋œ๋‹ค. 
ํ•˜์ง€๋งŒ... ์ง€๊ธˆ ๊ทธ ๋ฐฉ์‹์œผ๋กœ ํ•˜๊ธฐ์—” ํด๋” ๊ตฌ์กฐ๊ฐ€ ๋„ˆ๋ฌด ๋”๋Ÿฌ์›Œ์ง€๊ฒ ๋‹ค๋ผ๋Š” ํŒ๋‹จํ•˜์— ๊ทธ๋ƒฅ ์œˆ->๋ฆฌ ๋กœ ๋ณต๋ถ™ํ•˜๊ธฐ๋กœ ํ–ˆ๋‹ค.
์‚ฌ์‹ค ์ผ์ฃผ์ผ์— ํ•ด๋‹น ์ผ์ด ์ผ์–ด๋‚ ๊นŒ ๋ง๊นŒํ•˜๊ธฐ ๋•Œ๋ฌธ์— ๋ณต๋ถ™ํ•ด๋„ ๋œ๋‹ค๊ณ  ํŒ๋‹จํ–ˆ๊ณ  ๋” ์ด์ƒ ์‹œ๊ฐ„์„ ์Ÿ๊ณ  ์‹ถ์ง€ ์•Š๋‹ค๋Š” ๋งˆ์Œ์ด ๋” ์ปธ๋‹ค. 

 

์•„๋ž˜๋Š” ์‹œ๋„ํ•ด๋ณธ ์—ฌ๋Ÿฌ๊ฐ€์ง€ ํ…Œ์ŠคํŠธ ๋ฐฉ๋ฒ•.

1. ์†Œ์Šค๋ณต์‚ฌ
- ๋ณต์‚ฌํ•  ์ถ”๊ฐ€์†Œ์Šค : $(SolutionDir)dir:=$(RemoteDebuggerWorkingDirectory)dir -> ๋นŒ๋“œ ์„ฑ๊ณตํ•˜๋‚˜ ํŒŒ์ผ๋ณต์‚ฌ๊ฐ€ ์•ˆ๋จ

 

2. ๋นŒ๋“œ์ด๋ฒคํŠธ
(1) ๋นŒ๋“œ์ „์ด๋ฒคํŠธ
->๋ช…๋ น์ค„ : xcopy $(SolutionDir)dir $(RemoteDebuggerWorkingDirectory)dir /s /e /i 
[์˜ค๋ฅ˜๋ชฉ๋ก]
์‹ฌ๊ฐ๋„ ์ฝ”๋“œ ์„ค๋ช… ํ”„๋กœ์ ํŠธ ํŒŒ์ผ ์ค„ ๋น„ํ‘œ์‹œ ์˜ค๋ฅ˜(Suppression) ์ƒํƒœ
์˜ค๋ฅ˜ MSB3073 "xcopy C:\Users\yllee\source\repos\koreanLinuxJson\dir ~/projects/koreanLinuxJson/bin/x64/Debug/dir /s /e /i
:VCEnd" ๋ช…๋ น์ด ์ข…๋ฃŒ๋˜์—ˆ์Šต๋‹ˆ๋‹ค(์ฝ”๋“œ: 4). koreanLinuxJson C:\Program Files (x86)\Microsoft Visual Studio\2017\Professional\Common7\IDE\VC\VCTargets\Application Type\Linux\1.0\Linux.targets 492
[์ถœ๋ ฅ]
๋นŒ๋“œ ์‹คํŒจ
1>์ž˜๋ชป๋œ ๋งค๊ฐœ ๋ณ€์ˆ˜์˜ ์ˆ˜
1>C:\Program Files (x86)\Microsoft Visual Studio\2017\Professional\Common7\IDE\VC\VCTargets\Application Type\Linux\1.0\Linux.targets(492,5): error MSB3073: "xcopy C:\Users\yllee\source\repos\koreanLinuxJson\dir ~/projects/koreanLinuxJson/bin/x64/Debug/dir /s /e /i
1>C:\Program Files (x86)\Microsoft Visual Studio\2017\Professional\Common7\IDE\VC\VCTargets\Application Type\Linux\1.0\Linux.targets(492,5): error MSB3073: :VCEnd" ๋ช…๋ น์ด ์ข…๋ฃŒ๋˜์—ˆ์Šต๋‹ˆ๋‹ค(์ฝ”๋“œ: 4).
"~"๊ฐ€ ๋ถ™์–ด์„œ ์ž˜๋ชป๋œ๊ฑธ๊นŒ. -> ๋นผ๊ณ  ํ•ด๋„ ์•ˆ๋จ
์‹ฌ๊ฐ๋„ ์ฝ”๋“œ ์„ค๋ช… ํ”„๋กœ์ ํŠธ ํŒŒ์ผ ์ค„ ๋น„ํ‘œ์‹œ ์˜ค๋ฅ˜(Suppression) ์ƒํƒœ
์˜ค๋ฅ˜ MSB3073 "xcopy C:\Users\yllee\source\repos\koreanLinuxJson\dir /home/gcs/projects/koreanLinuxJson/bin/x64/Debug/dir /s /e /i
:VCEnd" ๋ช…๋ น์ด ์ข…๋ฃŒ๋˜์—ˆ์Šต๋‹ˆ๋‹ค(์ฝ”๋“œ: 4). koreanLinuxJson C:\Program Files (x86)\Microsoft Visual Studio\2017\Professional\Common7\IDE\VC\VCTargets\Application Type\Linux\1.0\Linux.targets 492

 

(2) ์›๊ฒฉ ๋นŒ๋“œ ์ „ ์ด๋ฒคํŠธ


1>Invoking 'xcopy C:\Users\yllee\source\repos\koreanLinuxJson\dir /home/gcs/projects/koreanLinuxJson/bin/x64/Debug/dir /s /e /i', working directory: '/home/gcs/projects/koreanLinuxJson'
1>bash: xcopy: ๋ช…๋ น์–ด๋ฅผ ์ฐพ์„ ์ˆ˜ ์—†์Œ
1>C:\Program Files (x86)\Microsoft Visual Studio\2017\Professional\Common7\IDE\VC\VCTargets\Application Type\Linux\1.0\Linux.targets(534,5): error : xcopy C:\Users\yllee\source\repos\koreanLinuxJson\dir /home/gcs/projects/koreanLinuxJson/bin/x64/Debug/dir /s /e /i exited with code 127, please see the Output Window - Build output for more details (NOTE: the build output verbosity might need to be changed in Tools Options to see more information in the Output Window).
1>"koreanLinuxJson.vcxproj" ํ”„๋กœ์ ํŠธ๋ฅผ ๋นŒ๋“œํ–ˆ์Šต๋‹ˆ๋‹ค. - ์‹คํŒจ

๊ฒฐ๋ก 

1. ๋นŒ๋“œ์ด๋ฒคํŠธ์˜ ๋ช…๋ น์ค„ ์ž…๋ ฅ์„ ํ†ตํ•œ copy

(1) ๋นŒ๋“œ ์ „ ์ด๋ฒคํŠธ๋Š” ์œˆ๋„์šฐ ํ”Œ๋žซํผ ๋‚ด๋ถ€์ ์œผ๋กœ ์ˆ˜ํ–‰ํ•  ๋ช…๋ น๋งŒ ๊ฐ€๋Šฅ

(2) ์›๊ฒฉ ๋นŒ๋“œ ์ „ ์ด๋ฒคํŠธ๋Š” ๋ฆฌ๋ˆ…์Šค ํ”Œ๋žซํผ ๋‚ด๋ถ€์ ์œผ๋กœ ์ˆ˜ํ–‰ํ•  ๋ช…๋ น๋งŒ ๊ฐ€๋Šฅ
2. ๋ณต์‚ฌํ• ์ถ”๊ฐ€์†Œ์Šค

ํฌ๋กœ์Šค ํ”Œ๋žซํผ์ผ ๊ฒฝ์šฐ ํŒŒ์ผ์„ ๋ณต์‚ฌํ•ด์ฃผ๋Š” ๊ธฐ๋Šฅ์„ ์ œ๊ณตํ•˜๋Š” ๊ฒƒ์ธ๋ฐ ๊ฐ ํŒŒ์ผ๋“ค์€ ๊ฐ€๋Šฅํ•˜๋‚˜ ๋””๋ ‰ํ† ๋ฆฌ ๋ณต์‚ฌ๋Š” ์•ˆ๋จ. 

๋Œ“๊ธ€