small fix
libcli: inserting a character in the input string misplaced the cursor
100% CPU use
You should set "server.daemon = true" in fgms.conf
fixed fgms.service
Updated
added example config for systemd
Fixed bug 16
Fixed passord input in cli 'enable' command
Fixed bug 10
Fixed bug #16
StrToNum<> fails to recognise overflows
erroneous conversion from signed to unsigned int allows to circumvent MaxRadarRange
Fixed in 0.13.8 (upcoming release)
RadarRange should not be negative, so a client should not be able to transmit a negative value. However, the conversion is false and I fixed it using only unsigned ints. It does not prevent a client from setting the radar range to 65535, though.
erroneous conversion from signed to unsigned int allows to circumvent MaxRadarRange
StrToNum<> fails to recognise overflows
Fixed in 0.13.8 (upcoming release)
erroneous conversion from signed to unsigned int allows to circumvent MaxRadarRange
CMAKE_INSTALL_PREFIX can't be set by user.
fixed in 0.13.7
Interesting, fgms seems to only start at 100% of CPU if I run it from systemd. Below is my systemd fgms service file. [Unit] Description=mpserver87 FlightGear Multiplayer Server [Service] User=reglnx WorkingDirectory=/home/reglnx/fgms ExecStart=/home/reglnx/fgms/fgms -c /home/reglnx/confs/fgms-mpserver87.conf -l /home/reglnx/logs/fgms-mpserver87.log Restart=Always [Install] WantedBy=multi-user.target
100% CPU use
Merge branch '0.13.7'
renamed cli_client.* to connection.*
some minor cosmetics
fix double initialisation of connection
Merge branch '0.13.7'
Fixed the Changelog
fixed CMAKE_INSTALL_PREFIX
next minor version
[ FIX ] fixed bugs 12 + 13
intermediate commit for better analysis
added to ChangeLog
-DCMAKE_INSTALL_PREFIX. still not working in the master branch at least.
obsXXXX callsigns don't work as intended
You are right. I've fixed the comparison in v0.13.6
removed logging of radar range
raised minor version
fixed misleading identation
fixed comparison of 'obsXXXX' callsign
obsXXXX callsigns don't work as intended
A minor MSVC 2019 build fix
Make stuff work on gitlab
Using gitlab CI to compile doxygen, merging this would make it 100% automated from now on http://fgms.freeflightsim.org/
Make stuff work on gitlab
increased version
Fix build on FreeBSD
Fix build on FreeBSD
Sorry for not replying sooner, I'm able to compile the 'fgms' package in OpenWRT's environment with no patches applied, Thank you for all your work everybody! Hopefully this package gets accepted to OpenWRT, then it will be offered to all those who use OpenWRT forks downstream, like Entware-3X etc... An easy way to deploy fgms on your router :)
Sorry for not replying sooner, I'm able to compile the 'fgms' package in the OpenWRT's environment with no patches applied, Thank you for all your work everybody! Hopefully this package gets accepted to OpenWRT, then it will be offered to all those who use OpenWRT forks downstream, like Entware-3X etc... An easy way to deploy fgms on your router :)
Sorry for not replying sooner, I'm able to compile the 'fgms' package in the OpenWRT's environmentn with no patches applied, Thank you for all your work everybody! Hopefully this package gets accepted to OpenWRT, then it will be offered to all those who use OpenWrt forks downstream, like Entware-3X etc... An easy way to deploy fgms on your router :)
This was fixed in 874f10ac50e359f3a7d2868da8cc0571c01cfc51 a straight up -DCMAKE_INSTALL_PREFIX:PATH=/opt, correctly deploys on an Entware /opt partition, makefile:47 : # # Copyright (C) 2017 OpenWrt.org # # This is free software, licensed under the GNU General Public License v2. # See /LICENSE for more information. # include $(TOPDIR)/rules.mk PKG_LICENSE:=GPL-2.0 PKG_MAINTAINER:=Hamza Alloush <hamzaalloush@live.com> PKG_NAME:=fgms PKG_VERSION:=0.13.4 PKG_RELEASE:=1 PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.xz...
- fixed 'set ( EXTRA_FLAGS "-std=c++11" )' for windows build
In 0.13.4, a quick Window compile test found I needed the following patch - diff --git a/CMakeLists.txt b/CMakeLists.txt index 82361cc..751ca2b 100755 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -88,6 +88,7 @@ if(WIN32) configure_file( "${CMAKE_SOURCE_DIR}/config.h.msvc" "${CMAKE_BINARY_DIR}/config.h" COPYONLY) file(WRITE "${CMAKE_BINARY_DIR}/unistd.h" "/* dummy unistd.h for windows */") else(WIN32) + set ( EXTRA_FLAGS "-std=c++11" ) if(ENABLE_DEBUG_SYMBOLS) list(APPEND EXTRA_FLAGS "-g") endif(ENABLE_DEBUG_SYMBOLS)...
- fixed CMAKE_INSTALL_PREFIX in CMakeLists.txt
- updated Changelog
- use ~ instead of fixed string
I don't see version 0.13.4 on git. Neither master, branch or tag is 0.13.4. Where can I find version 0.13.4?
I've included Geoffs patch in 0.13.4 (slightly adapted to avoid unnecessary variables in CMakeLists.txt). Please test...
CMAKE_INSTALL_PREFIX can't be set by user.
This one is curious. I wonder why we have USER_INSTALL_PREFIX in CMakeLists.txt. If USER_INSTALL_PREFIX is not set explicitly set CMAKE_INSTALL_PREFIX to /usr. I removed this completly in 0.13.4... Please test.
"libCLI" CMake target won't cross-compile in OpenWRT build environment
cmake is somewhat funny regarding names. Sometimes it insists on BIGLETTER names, sometimes not. And now it seems it even depends on the cmake version. We'll see...
CMAKE_INSTALL_PREFIX can't be set by user.
- intermediate commit
Build Error with Clang compare pointer to int value
Thanks for the feedback Hamza... Yes, I can see your Makefile uses commit 508376d79, which is indeed master, default branch, 0.13.2, so no problem there... And yes I can see the LibCLI somehow failed, and agree we do not exactly know the problem, since it currently works in most distros, but think my cmake.1 branch is better cmake wording anyway, and clears up a WIN32 only block... I have now tested it in Windows, and 2 Linux, so this seems to work for all... You will note I renamed the local static...
Thank you for the fix Geoff, i fetch 0.13.2 (see the Makefile), OpenWRT guidelines state that we have to pull explicitly and version our Makefiles, regarding the status of fgms, I really only deployed this locally and haven't tested extensively the differences between the branches...
Sorry for the late reply, but i wanted to find the time to setup an amd64 environment, to see if it's something to do with the architecture, cross-compiler or OpenWRT's environment CMake 3.9.3, Initially i want to say the patch does work, but i found out it was unnessesary on some systems, I've tested cross-compiling for both armv7 and amd64 targets on two native x64 systems, with or without the patch, turns out it hasn't to do with the target architecture, but for two different systems with same...
Have pushed that change, plus a small WIN32 only change, to the cmake.1 branch. This branch is based on master... $ cd fgms-src $ git pull $ git checkout cmake.1 Would appreciate you, and others testing and reporting... thanks... OT: A little off topic, but related... When I look at the repo branches... maybe I missed, or have forgotten! which branch is current. In addition to the default master, there is 0.13.2 which is the closest to the current master except for a comment update, and then there...
B #14 - fix to compile in all distros
Sorry to hear you are having OpenWRT compile problems... I have no problem cross-compiling the fgms-src in a raspberrypi machine, armv7l, running Raspbian GNU/Linux 8.0 (jessie)... and of course there are no other unix/linux reports of a compile failure in other distributions... To me there seems a problem in each of the list(APPEND add_LIBS <proj>) lines, in that each of the projects a prefixed with -l<proj>, if NOT WIN32... in all other cmake projects I work with this is not required... I think...
Yes, I just notice my build script, which includes an option -DCMAKE_INSTALL_PREFIX=/path is completely ignored... Have you tried adding an option -DUSER_INSTALL_PREFIX=/some/path? This seems to work for me... But certainly agree it is a bit confusing...
"libCLI" CMake target won't cross-compile in OpenWRT build environment
CMAKE_INSTALL_PREFIX can't be set by user.
Fixed in 0.13.3. Please test. To get the repro use git clone https://ofschroeder@git.code.sf.net/p/fgms/src -b 0.13.3 fgms If no problems arise I will merge this branch with master. Regards, Oliver
Updated Changelog
- ignore SIGPIPE on *nix and do not expect signals on sockets (fixes problems with the tracker)
Merge branch '0.13.3' of ssh://git.code.sf.net/p/fgms/src into 0.13.3
Build Error with Clang compare pointer to int value
- Changed the file interface (see Changelog and example config)
OK, the pthread library is still needed for linking, at least for *nix systems :-)
removed pthread completly and using std::thread instead
!!! configuration file format changed !!!
- small bugfix
- the pager is disabled by default
- authenticate_user () returns privlevel
- disabled pager by default
introduced 'make_prio()' to cast an integer to a fglog::prio
moved from namespace fgms to namespace fgmp
adjust address.assign() calls to default port
fixed header comment
- libcli: commands can have a callback and children at the same time
introduced align_left()-operator for cli_client
fixed tabulators in source
introduced new RESULT::INVALID_COMMAND
virtualised some functions for future extensions
added default for port in assign()