You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
This repository was archived by the owner on Apr 17, 2022. It is now read-only.
Repository navigation
This repository was archived by the owner on Apr 17, 2022. It is now read-only.
keyword_popt_argumentsresolution_fixedtype_patch (an actual patch, not a request for one) | by Per
The popt library is a unnecessary dependency. This patch removes it in favour of a very small and very quickly hacked together arguments parser that acts as a drop in replacement for our use of popt.
Issue migrated from trac:1659 at 2022-04-15 21:11:33 -0700
The idea is great, but I can't figure how to pass --mod="C:\Program files\WZ2100" because this results in two tokens...
Plus if there are no short form then argument is compared with "-", which could possibly lead to unwanted results.
Function poptGetNextOpt() was fixed a bit (internal buffer issue and missing spaces, return actual enums instead of count ;) ) so it would parse smth like:
#CommitTicketReference repository="" revision="240bb9189125a5560535956d253c755ec0890d04"
Remove our dependency on popt by writing a custom popt-like parser. Patch by me and i-NoD. Closes #1659
git-svn-id: https://warzone2100.svn.sourceforge.net/svnroot/warzone2100/trunk@10186 4a71c877-e1ca-e34f-864e-861f7616d084
#CommitTicketReference repository="" revision="2aca760ab52865660c3c30bdb84eab4d2850e6ae"
Remove our dependency on popt by writing a custom popt-like parser. Patch by me and i-NoD. Closes #1659
git-svn-id: https://warzone2100.svn.sourceforge.net/svnroot/warzone2100/trunk@10186 4a71c877-e1ca-e34f-864e-861f7616d084
(cherry picked from commit 240bb9189125a5560535956d253c755ec0890d04)
Conflicts:
configure.ac
src/Makefile.am
Activity
wzdev-ci commentedon Mar 3, 2010
Per uploaded file
popt-b-gone.diff(5.6 KiB)wzdev-ci commentedon Mar 3, 2010
Zarel commented
I am in support of this action.
wzdev-ci commentedon Mar 3, 2010
i-NoD commented
The idea is great, but I can't figure how to pass --mod="C:\Program files\WZ2100" because this results in two tokens...
Plus if there are no short form then argument is compared with "-", which could possibly lead to unwanted results.
wzdev-ci commentedon Mar 4, 2010
Per uploaded file
popt-b-gone2.diff(6.2 KiB)Thanks for the response. Both issues fixed in new patch.
wzdev-ci commentedon Mar 4, 2010
i-NoD commented
Function poptGetNextOpt() was fixed a bit (internal buffer issue and missing spaces, return actual enums instead of count ;) ) so it would parse smth like:
Warzone2100.exe --cheat --debug=all --mod=TCMask --configdir="c:\Users\123\Documents\WZ 2100 Trnk"
Btw, if its fine for Unix, will it work for Mac too?
wzdev-ci commentedon Mar 4, 2010
Per commented
Nice fixups.
It should work fine on Mac. I see I forgot to remove a debug printf in there, and should probably remove the usage option before committing.
wzdev-ci commentedon Mar 5, 2010
i-NoD uploaded file
popt.patch(5.0 KiB)We should remove final qoutes from one-word params too.
wzdev-ci commentedon Mar 6, 2010
i-NoD commented
Per, could you please commit this feature? I'm keeping 10 shortcuts (new and old style) around and like to purge some :-/
As a note: i've made a non-critical mistake in the last patch and there should be
check like in your original code.
wzdev-ci commentedon Mar 6, 2010
Buginator commented
Nice.
die popt die! :D
It will also kill off
libiconv-2.dll
popt1.dll
libintl-2.dll
wzdev-ci commentedon Mar 6, 2010
i-NoD commented
Somehow I knew you would say it! :)
I think libiconv-2.dll and libintl-2.dll are still required for internalization, althought it's not strictly necessary for MSVC builds.
At least with popt death it will be possible to compile both into static libs.
wzdev-ci commentedon Mar 7, 2010
Per changed status from
newtoclosedwzdev-ci commentedon Mar 7, 2010
Per set resolution to
fixedwzdev-ci commentedon Mar 7, 2010
Per commented
(In [10186]) Remove our dependency on popt by writing a custom popt-like parser. Patch by me and i-NoD. Closes #1659
wzdev-ci commentedon Mar 7, 2010
Git SVN Gateway <gateway@...> commented
(In Warzone2100/warzone2100@240bb91) Remove our dependency on popt by writing a custom popt-like parser. Patch by me and i-NoD. Closes #1659
git-svn-id: https://warzone2100.svn.sourceforge.net/svnroot/warzone2100/trunk@10186 4a71c877-e1ca-e34f-864e-861f7616d084
wzdev-ci commentedon Oct 14, 2010
Git SVN Gateway <gateway@...> commented
In Warzone2100/warzone2100@240bb91:
wzdev-ci commentedon Oct 23, 2010
buginator <buginator@...> commented
(In Warzone2100/warzone2100@2aca760) Remove our dependency on popt by writing a custom popt-like parser. Patch by me and i-NoD. Closes #1659
git-svn-id: https://warzone2100.svn.sourceforge.net/svnroot/warzone2100/trunk@10186 4a71c877-e1ca-e34f-864e-861f7616d084
(cherry picked from commit 240bb9189125a5560535956d253c755ec0890d04)
Conflicts:
wzdev-ci commentedon Oct 23, 2010
buginator <buginator@...> commented
In Warzone2100/warzone2100@2aca760:
wzdev-ci commentedon Jan 3, 2012
cybersphinx changed milestone from
3.0tounspecifiedwzdev-ci commentedon Jan 3, 2012
cybersphinx commented
Milestone 3.0 deleted