freeswitch icon indicating copy to clipboard operation
freeswitch copied to clipboard

[windows-build] Add Freeswitch Visual Studio 2022 solution to freeswitch

Open Visytel opened this issue 2 years ago • 11 comments

In order to improve opening Freeswitch inside later versions of Visual Studio this PR simply adds a Visual Studio 2022 solution to the freeswitch project (Freeswitch.2022.sln) and performs various tidy up tasks so Freeswitch can be built under Windows without all the extra tasks. You are welcome to read through what was done below.

What done:

  1. git clone https://github.com/signalwire/freeswitch freeswitch
  2. cd freeswitch
  3. copy Freeswitch.2017.sln Freeswitch.2022.sln
  4. Open Freeswitch.2022.sln inside Visual Studio Professional 2022 - 17.6.5 - Windows SDK: 10.0.22000.0
  5. Press OK to accept migration to a Visual Studio 2022 solution
  6. Accepted prompt for update the target to .NET 4.8 and ticked Remember my choice - Continue pressed
  7. Closed the browser showing results of the migration
  8. Removed projects that were not found or are not compatible:

docs (under Libaries\Docs) FSComm Setup.2017

  1. Unticked project Setup.CA.DownloadOpenH264 from Debug build configuration - since: The WiX Toolset v3.11 (or newer) build tools must be installed to build this project.
  2. Unticked test_switch_core_db and test_switch_ivr_originate from the Debug build configuration - since these can be ticked when testing is required
  3. Retarget all projects to Windows SDK Version: 10.0 (latest installed version)
  4. Tested Rebuild Solution done successfully for Debug x64 (with PR #2188 applied) - ========== Rebuild All: 163 succeeded, 0 failed, 14 skipped ==========
  5. Switched to Release x64
  6. Added in the sounds projects (16khz/16khz music, 32khz/32khz music, 48 khz/48 khz music) to the Release build configuration to match the Debug build configuration
  7. Unticked project Setup.CA.DownloadOpenH264 from the Release build configuration
  8. Unticked test_switch_core_db and test_switch_ivr_originate from the Release build configuration
  9. Rebuild done successfully - ========== Rebuild All: 163 succeeded, 0 failed, 14 skipped ==========
  10. Switched back to Debug x64 - Since I noticed that for some reason the freeswitch\x64\Debug\mod folder lost some files when the Rebuild Release x64 was done:

mod_amr.* mod_g723_1.* mod_g729.* mod_ldap.* mod_managed.*

{This can be looked at perhaps inside a different PR since it is not critical and a simply Build of x64 Debug fixes this}

  1. Ran a simple Debug x64 build only to make sure everything still working fine - ========== Build: 13 succeeded, 0 failed, 150 up-to-date, 14 skipped ==========
  2. Saved the solution and closed Visual Studio

Visytel avatar Aug 07 '23 03:08 Visytel

Unit-tests failed: https://public-artifacts.signalwire.cloud/drone/signalwire/freeswitch/1432/artifacts.html

signalwire-ci[bot] avatar Aug 07 '23 04:08 signalwire-ci[bot]

Interesting that this PR failed a unit-test:

src/mod/endpoints/mod_sofia/test test_run_sipp.sh

Since no actual code was changed inside this PR - just windows build projects and solutions.

  • Any ideas why this would fail?
  • Perhaps this unit test needs updating in some way?

Visytel avatar Aug 07 '23 04:08 Visytel

@Visytel The SIPp unit tests have been broken for some time now. Don't worry about it

yois615 avatar Aug 07 '23 18:08 yois615

how to build FSComm and Setup.2017 under vs2022? thx

echobom avatar Jan 18 '24 02:01 echobom

how to build FSComm and Setup.2017 under vs2022? thx

Sorry I have never used FSComm and have had no requirement to build it.

Visytel avatar Jan 18 '24 03:01 Visytel

how to build FSComm and Setup.2017 under vs2022? thx

Sorry I have never used FSComm and have had no requirement to build it.

then how to build Setup.2017 under vs2022? thx

echobom avatar Jan 18 '24 06:01 echobom

how to build FSComm and Setup.2017 under vs2022? thx

Sorry I have never used FSComm and have had no requirement to build it.

then how to build Setup.2017 under vs2022? thx

You are probably not going to like this response either, since as with FSComm I never have had a requirement to build Setup.2017 and always remove it from the solution like I do with FSComm. Essentially I just take the x64/Release/ (all the .exe and .dll files) and also x64/Release/mod/ (all the .dll files) and use that in production as the new release pack. The other folders conf, db, etc remain unchanged. Sorry I cannot help more on this one.

Visytel avatar Jan 18 '24 22:01 Visytel

how to build FSComm and Setup.2017 under vs2022? thx

Sorry I have never used FSComm and have had no requirement to build it.

then how to build Setup.2017 under vs2022? thx

You are probably not going to like this response either, since as with FSComm I never have had a requirement to build Setup.2017 and always remove it from the solution like I do with FSComm. Essentially I just take the x64/Release/ (all the .exe and .dll files) and also x64/Release/mod/ (all the .dll files) and use that in production as the new release pack. The other folders conf, db, etc remain unchanged. Sorry I cannot help more on this one.

thx also and that is what i want to know too its an alternate solution to release a new modified version of fs

echobom avatar Jan 19 '24 06:01 echobom

What's the status on this? Can this be merged now or are there prerequisites to this?

I volunteer to taking this on if there's any problems. AFAIK the tests have been failing on master for a while now.

ChaseCarlson avatar Jun 21 '24 00:06 ChaseCarlson

What's the status on this? Can this be merged now or are there prerequisites to this?

I volunteer to taking this on if there's any problems. AFAIK the tests have been failing on master for a while now.

I am not sure what is happening with this, since I manually do everything shown inside this PR in order to build a new Windows release of FreeSWITCH each time a new version of FreeSWITCH comes out.

Visytel avatar Jun 21 '24 00:06 Visytel

Is anyone actioning this PR? I am not sure if there has been any progress or not.

Visytel avatar Jul 30 '24 01:07 Visytel