{"action":"created","issue":{"url":"https://api.github.com/repos/szpajder/RTLSDR-Airband/issues/95","repository_url":"https://api.github.com/repos/szpajder/RTLSDR-Airband","labels_url":"https://api.github.com/repos/szpajder/RTLSDR-Airband/issues/95/labels{/name}","comments_url":"https://api.github.com/repos/szpajder/RTLSDR-Airband/issues/95/comments","events_url":"https://api.github.com/repos/szpajder/RTLSDR-Airband/issues/95/events","html_url":"https://github.com/szpajder/RTLSDR-Airband/issues/95","id":345572173,"node_id":"MDU6SXNzdWUzNDU1NzIxNzM=","number":95,"title":"build with Mingw-w64","user":{"login":"hhrhhr","id":966048,"node_id":"MDQ6VXNlcjk2NjA0OA==","avatar_url":"https://avatars3.githubusercontent.com/u/966048?v=4","gravatar_id":"","url":"https://api.github.com/users/hhrhhr","html_url":"https://github.com/hhrhhr","followers_url":"https://api.github.com/users/hhrhhr/followers","following_url":"https://api.github.com/users/hhrhhr/following{/other_user}","gists_url":"https://api.github.com/users/hhrhhr/gists{/gist_id}","starred_url":"https://api.github.com/users/hhrhhr/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/hhrhhr/subscriptions","organizations_url":"https://api.github.com/users/hhrhhr/orgs","repos_url":"https://api.github.com/users/hhrhhr/repos","events_url":"https://api.github.com/users/hhrhhr/events{/privacy}","received_events_url":"https://api.github.com/users/hhrhhr/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"assignees":[],"milestone":null,"comments":2,"created_at":"2018-07-29T23:28:28Z","updated_at":"2018-09-05T21:06:30Z","closed_at":null,"author_association":"NONE","body":"I propose a patch to support the compilation with mingw-w64 ([rtlsdr_airband.patch](https://github.com/hhrhhr/rtl-sdr-windows/blob/master/patch/4-rtlsdr_airband.patch)).\r\n\r\nThe changes are very minor and do not affect other platforms. Checked work with rtlsdr and streaming on Icecast-server. Instructions for preparing and compiling all the necessary libraries I have so far [published here](https://github.com/hhrhhr/rtl-sdr-windows). There is also an archive with a [test build](https://github.com/hhrhhr/rtl-sdr-windows/releases).\r\n\r\nI also checked the work with the Pulseaudio server under Windows and Debian, a little later I will publish the order of actions for compiling at least the client part of Pulseaudio necessary to build RTLSDR-Airband as an audio source.\r\n\r\nthe screenshot shows the launched Icecast server, rtl_airband and demonstration of support for ANSI commands in the Windows 10 console:\r\n\r\n![rtl_airband_windows](https://user-images.githubusercontent.com/966048/43371707-1a72b2de-93a0-11e8-850c-659ead6c1ef1.png)\r\n\r\n\r\nUsed mingw-w64 from Debian 9.\r\n````\r\n> i686-w64-mingw32-gcc -v\r\nUsing built-in specs.\r\nCOLLECT_GCC=i686-w64-mingw32-gcc\r\nCOLLECT_LTO_WRAPPER=/usr/lib/gcc/i686-w64-mingw32/6.3-win32/lto-wrapper\r\nTarget: i686-w64-mingw32\r\nConfigured with: ../../src/configure --build=x86_64-linux-gnu --prefix=/usr --includedir='/usr/include' --mandir='/usr/share/man' --infodir='/usr/share/info' --sysconfdir=/etc --localstatedir=/var --disable-silent-rules --libdir='/usr/lib/x86_64-linux-gnu' --libexecdir='/usr/lib/x86_64-linux-gnu' --disable-maintainer-mode --disable-dependency-tracking --prefix=/usr --enable-shared --enable-static --disable-multilib --with-system-zlib --libexecdir=/usr/lib --without-included-gettext --libdir=/usr/lib --enable-libstdcxx-time=yes --with-tune=generic --enable-version-specific-runtime-libs --enable-fully-dynamic-string --enable-libgomp --enable-languages=c,c++,fortran,objc,obj-c++ --enable-lto --with-plugin-ld --enable-threads=win32 --program-suffix=-win32 --program-prefix=i686-w64-mingw32- --target=i686-w64-mingw32 --with-as=/usr/bin/i686-w64-mingw32-as --with-ld=/usr/bin/i686-w64-mingw32-ld --enable-libatomic\r\nThread model: win32\r\ngcc version 6.3.0 20170516 (GCC)\r\n````"},"comment":{"url":"https://api.github.com/repos/szpajder/RTLSDR-Airband/issues/comments/418881547","html_url":"https://github.com/szpajder/RTLSDR-Airband/issues/95#issuecomment-418881547","issue_url":"https://api.github.com/repos/szpajder/RTLSDR-Airband/issues/95","id":418881547,"node_id":"MDEyOklzc3VlQ29tbWVudDQxODg4MTU0Nw==","user":{"login":"szpajder","id":4560159,"node_id":"MDQ6VXNlcjQ1NjAxNTk=","avatar_url":"https://avatars1.githubusercontent.com/u/4560159?v=4","gravatar_id":"","url":"https://api.github.com/users/szpajder","html_url":"https://github.com/szpajder","followers_url":"https://api.github.com/users/szpajder/followers","following_url":"https://api.github.com/users/szpajder/following{/other_user}","gists_url":"https://api.github.com/users/szpajder/gists{/gist_id}","starred_url":"https://api.github.com/users/szpajder/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/szpajder/subscriptions","organizations_url":"https://api.github.com/users/szpajder/orgs","repos_url":"https://api.github.com/users/szpajder/repos","events_url":"https://api.github.com/users/szpajder/events{/privacy}","received_events_url":"https://api.github.com/users/szpajder/received_events","type":"User","site_admin":false},"created_at":"2018-09-05T21:06:29Z","updated_at":"2018-09-05T21:06:29Z","author_association":"OWNER","body":"I have applied your patch to unstable branch.\r\n\r\nI have built it under Gentoo, following your instructions. A few comments regarding the process:\r\n\r\n- `eval GCC_VER=$($CROSS-gcc -dumpversion | cut -f1,2 -d. | cut -f1 -d-)` - I assume this deals with some kind of Debian-specific version number format, correct? `eval GCC_VER=$($CROSS-gcc -dumpversion)` works for me and returns \"8.2.0\".\r\n\r\n- where does libwinpthread-1.dll come from? I don't have it. I linked rtl_airband and rtl-sdr with `-lpthreadGC2` taken from ftp://sourceware.org/pub/pthreads-win32/dll-latest/dll/x86/ . \r\n\r\n- gdbm fails to compile due to missing Unix-specific header files (`arpa/inet.h`, `pwd.h`, etc). Here is a patch which seems to deal with this: https://gist.github.com/SaitoAtsushi/3062655b2d253f21d925e24f46fc2244 but I haven't tried it out yet. For the timebeing, I continued with Pulse support disabled.\r\n\r\n- libsndfile configure fails when autogen is not installed\r\n\r\n- building rtl_airband with `-march=native` makes the binary non-portable. I built the program on Skylake - when launched on on an older CPU it always crashes after a few seconds. `-march=prescott` works OK and it's probably the best bet here, as it's the minimum arch which has SSSE3 support (which is now required by rtl_airband when running on x86, but I think I'll make it optional).\r\n\r\nI tested it on WinXP ;-) under qemu-kvm, as this is all I currently have at hand. It works but hogs the CPU at 100% constantly. Will need to investigate if it's specific to XP or not.\r\n\r\nThanks again for your effort."}}
{"actor":{"display_login":"szpajder"}}