Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

MacOS M1 (Venture) build warning fixes #987

Open
wants to merge 1 commit into
base: master
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions CMakeLists.txt
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
cmake_minimum_required (VERSION 2.8)
cmake_minimum_required (VERSION 3.0)

project (CubicSDR)

Expand Down Expand Up @@ -142,7 +142,7 @@ endmacro(configure_files_recurse)
if( CMAKE_SIZEOF_VOID_P EQUAL 8 )
MESSAGE( "64 bit compiler detected" )
SET( EX_PLATFORM 64 )
SET( EX_PLATFORM_NAME "x64" )
SET( EX_PLATFORM_NAME "${CMAKE_SYSTEM_PROCESSOR}" )
else( CMAKE_SIZEOF_VOID_P EQUAL 8 )
MESSAGE( "32 bit compiler detected" )
SET( EX_PLATFORM 32 )
Expand Down
2 changes: 1 addition & 1 deletion cmake/Modules/FindLiquid.cmake
Original file line number Diff line number Diff line change
Expand Up @@ -17,6 +17,6 @@ find_library (LIQUID_LIBRARIES NAMES liquid)
# handle the QUIETLY and REQUIRED arguments and set LIQUID_FOUND to TRUE if
# all listed variables are TRUE
include (FindPackageHandleStandardArgs)
find_package_handle_standard_args (LIQUID DEFAULT_MSG LIQUID_LIBRARIES LIQUID_INCLUDES)
find_package_handle_standard_args (Liquid DEFAULT_MSG LIQUID_LIBRARIES LIQUID_INCLUDES)

#mark_as_advanced (LIQUID_LIBRARIES LIQUID_INCLUDES)
2 changes: 0 additions & 2 deletions external/rtaudio/RtAudio.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -990,9 +990,7 @@ bool RtApiCore :: probeDeviceOpen( unsigned int device, StreamMode mode, unsigne
AudioDeviceID id = deviceList[ device ];

// Setup for stream mode.
bool isInput = false;
if ( mode == INPUT ) {
isInput = true;
property.mScope = kAudioDevicePropertyScopeInput;
}
else
Expand Down
4 changes: 2 additions & 2 deletions src/AppFrame.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -1631,7 +1631,6 @@ bool AppFrame::actionOnMenuAudioSampleRate(wxCommandEvent& event) {

auto outputDevices = wxGetApp().getDemodMgr().getOutputDevices();

int i = 0;
for (auto & outputDevice : outputDevices) {
int menu_id = wxID_AUDIO_BANDWIDTH_BASE + wxID_AUDIO_DEVICE_MULTIPLIER * outputDevice.first;

Expand All @@ -1649,7 +1648,6 @@ bool AppFrame::actionOnMenuAudioSampleRate(wxCommandEvent& event) {

j++;
}
i++;
}
}

Expand Down Expand Up @@ -1980,6 +1978,8 @@ bool AppFrame::actionOnMenuRig(wxCommandEvent &event) {
wxGetApp().stopRig();
wxGetApp().initRig(rigModel, rigPort, rigSerialRate);
}
#else
(void)event; // Suppres build warning
#endif

return bManaged;
Expand Down
2 changes: 1 addition & 1 deletion src/audio/AudioSinkThread.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@ void AudioSinkThread::run() {
#ifdef __APPLE__
pthread_t tID = pthread_self(); // ID of this thread
int priority = sched_get_priority_max(SCHED_RR) - 1;
sched_param prio = { priority }; // scheduling priority of thread
sched_param prio = { priority, {0}}; // scheduling priority of thread
pthread_setschedparam(tID, SCHED_RR, &prio);
#endif

Expand Down
2 changes: 1 addition & 1 deletion src/audio/AudioThread.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -472,7 +472,7 @@ void AudioThread::run() {
#ifdef __APPLE__
pthread_t tID = pthread_self(); // ID of this thread
int priority = sched_get_priority_max(SCHED_RR) - 1;
sched_param prio = { priority }; // scheduling priority of thread
sched_param prio = { priority, {0}}; // scheduling priority of thread
pthread_setschedparam(tID, SCHED_RR, &prio);
#endif

Expand Down
2 changes: 1 addition & 1 deletion src/demod/DemodulatorPreThread.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -55,7 +55,7 @@ void DemodulatorPreThread::run() {
#ifdef __APPLE__
pthread_t tID = pthread_self(); // ID of this thread
int priority = sched_get_priority_max( SCHED_FIFO) - 1;
sched_param prio = {priority}; // scheduling priority of thread
sched_param prio = {priority, {0}}; // scheduling priority of thread
pthread_setschedparam(tID, SCHED_FIFO, &prio);
#endif

Expand Down
2 changes: 1 addition & 1 deletion src/demod/DemodulatorThread.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -70,7 +70,7 @@ void DemodulatorThread::run() {
#ifdef __APPLE__
pthread_t tID = pthread_self(); // ID of this thread
int priority = sched_get_priority_max( SCHED_FIFO )-1;
sched_param prio = {priority}; // scheduling priority of thread
sched_param prio = {priority, {0}}; // scheduling priority of thread
pthread_setschedparam(tID, SCHED_FIFO, &prio);
#endif

Expand Down
2 changes: 1 addition & 1 deletion src/sdr/SDRPostThread.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -153,7 +153,7 @@ void SDRPostThread::run() {
#ifdef __APPLE__
pthread_t tID = pthread_self(); // ID of this thread
int priority = sched_get_priority_max( SCHED_FIFO);
sched_param prio = {priority}; // scheduling priority of thread
sched_param prio = {priority, {0}}; // scheduling priority of thread
pthread_setschedparam(tID, SCHED_FIFO, &prio);
#endif

Expand Down
2 changes: 1 addition & 1 deletion src/visual/SpectrumCanvas.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -180,7 +180,7 @@ bool SpectrumCanvas::getUseDBOfs() {
return spectrumPanel.getUseDBOffset();
}

void SpectrumCanvas::setView(long long center_freq_in, int bandwidth_in) {
void SpectrumCanvas::setView(long long center_freq_in, long long bandwidth_in) {
bwChange += bandwidth_in-bandwidth;
#define BW_RESET_TH 400000
if (bwChange > BW_RESET_TH || bwChange < -BW_RESET_TH) {
Expand Down
2 changes: 1 addition & 1 deletion src/visual/SpectrumCanvas.h
Original file line number Diff line number Diff line change
Expand Up @@ -39,7 +39,7 @@ class SpectrumCanvas: public InteractiveCanvas {
void setUseDBOfs(bool showDb);
bool getUseDBOfs();

void setView(long long center_freq_in, int bandwidth_in);
void setView(long long center_freq_in, long long bandwidth_in) override;
void disableView() override;

void setScaleFactorEnabled(bool en);
Expand Down