Giter VIP home page Giter VIP logo

Comments (11)

petertorelli avatar petertorelli commented on August 19, 2024

I don't use visual studio, but the _MCS_VER #defines in audiomark.c switch from hardcoded mode to file-read mode. If you remove the _MSC_VER code in the audiomark.c and just include the raw files, can you make it work? It appears to be limited to that file only.

from audiomark.

Kaipingli88 avatar Kaipingli88 commented on August 19, 2024

I tried to build on Linux (i.e. no _MCS_VER defined) and gets a lot of warning messages as shown from screenshot. It seems to me this is not normal so I just stopped the build.
image

from audiomark.

petertorelli avatar petertorelli commented on August 19, 2024

Yes, there are lots of warnings. I don't think the array sizes are matched up yet. I'm skipping the warnings for now and getting all the parts connected. Then going back and sanitizing. You might want to correct this in the process of adding your BF code. I don't yet have a strategy for checking the output (and input) of each stage for correctness. Someone has yet to develop that.

from audiomark.

Kaipingli88 avatar Kaipingli88 commented on August 19, 2024

OK, ignore warnings and let it continue in Linux but I get compile error copied below. Something is not right. Anything special I need do or setup? It will be good if your cmake build supports MS visual studio since it is easier tool to debug.
In file included from /mnt/c/Users/LiKaiping/workspace/audio/audiomark-dev/components/arm/audio_beamformer/src/arm_beamformer_process_f32.c:33: /mnt/c/Users/LiKaiping/workspace/audio/audiomark-dev/platform/cmake/../../libraries/DSP/Include/arm_math_types.h:82:10: fatal error: cmsis_compiler.h: No such file or directory 82 | #include "cmsis_compiler.h" | ^~~~~~~~~~~~~~~~~~ compilation terminated.

from audiomark.

petertorelli avatar petertorelli commented on August 19, 2024

@Kaipingli88 I modified the CMakeLists.txt file to work with MSVC's CMake. It generates audiomark.sln which can be opened and compiled from MSVC2019 (my version). I couldn't start the debugger, but I could run it from a command prompt. Maybe you can help me understand what is wrong with the project setup. I did not include the solution file because all of the path names were hard coded to my directory structure for some reason.

image

from audiomark.

petertorelli avatar petertorelli commented on August 19, 2024

I forgot to mention this is ONLY in the cleanup01 branch which I haven't merged yet because I heavily modified the audiomark.c file and have a lot of Q's for Laurent.

from audiomark.

petertorelli avatar petertorelli commented on August 19, 2024

The reason why I couldn't launch the debugger was due to having "ALL_BUILD" set as the default project. Once I set it to "audiomark" I could debug inside MSVC.

from audiomark.

Kaipingli88 avatar Kaipingli88 commented on August 19, 2024

I pulled your cleanup01 branch and tried your cmake to build for MSVC. I have a build error copied below:
C:\Users\LiKaiping\workspace\audio\audiomark-dev\libraries\NN\Include\arm_nnsupportfunctions.h(1064,58): error C2146: s yntax error: missing ')' before identifier 'dst' [C:\Users\LiKaiping\workspace\audio\audiomark-dev\platform\cmake\BUILD \audiomark.vcxproj] C:\Users\LiKaiping\workspace\audio\audiomark-dev\libraries\NN\Include\arm_nnsupportfunctions.h(1064,58): error C2061: s yntax error: identifier 'dst' [C:\Users\LiKaiping\workspace\audio\audiomark-dev\platform\cmake\BUILD\audiomark.vcxproj] C:\Users\LiKaiping\workspace\audio\audiomark-dev\libraries\NN\Include\arm_nnsupportfunctions.h(1064,58): error C2059: s yntax error: ';' [C:\Users\LiKaiping\workspace\audio\audiomark-dev\platform\cmake\BUILD\audiomark.vcxproj] C:\Users\LiKaiping\workspace\audio\audiomark-dev\libraries\NN\Include\arm_nnsupportfunctions.h(1064,61): error C2059: s yntax error: ',' [C:\Users\LiKaiping\workspace\audio\audiomark-dev\platform\cmake\BUILD\audiomark.vcxproj] C:\Users\LiKaiping\workspace\audio\audiomark-dev\libraries\NN\Include\arm_nnsupportfunctions.h(1064,110): error C2059: syntax error: ')' [C:\Users\LiKaiping\workspace\audio\audiomark-dev\platform\cmake\BUILD\audiomark.vcxproj] C:\Users\LiKaiping\workspace\audio\audiomark-dev\libraries\NN\Include\arm_nnsupportfunctions.h(1088,60): error C2146: s yntax error: missing ')' before identifier 'dst' [C:\Users\LiKaiping\workspace\audio\audiomark-dev\platform\cmake\BUILD \audiomark.vcxproj] C:\Users\LiKaiping\workspace\audio\audiomark-dev\libraries\NN\Include\arm_nnsupportfunctions.h(1088,60): error C2061: s yntax error: identifier 'dst' [C:\Users\LiKaiping\workspace\audio\audiomark-dev\platform\cmake\BUILD\audiomark.vcxproj] C:\Users\LiKaiping\workspace\audio\audiomark-dev\libraries\NN\Include\arm_nnsupportfunctions.h(1088,60): error C2059: s yntax error: ';' [C:\Users\LiKaiping\workspace\audio\audiomark-dev\platform\cmake\BUILD\audiomark.vcxproj] C:\Users\LiKaiping\workspace\audio\audiomark-dev\libraries\NN\Include\arm_nnsupportfunctions.h(1088,63): error C2059: s yntax error: ',' [C:\Users\LiKaiping\workspace\audio\audiomark-dev\platform\cmake\BUILD\audiomark.vcxproj] C:\Users\LiKaiping\workspace\audio\audiomark-dev\libraries\NN\Include\arm_nnsupportfunctions.h(1088,113): error C2059: syntax error: ')' [C:\Users\LiKaiping\workspace\audio\audiomark-dev\platform\cmake\BUILD\audiomark.vcxproj]

It looks like my MSVC somehow does not understand "__RESTRICT". My MSVC is Microsoft Visual Studio Professional 2019
Version 16.11.20

from audiomark.

petertorelli avatar petertorelli commented on August 19, 2024

That's very odd. What happens if you edit this code and add RESTRICT to the _MSC_VER define block?

#if defined(_MSC_VER)
#ifndef __STATIC_FORCEINLINE
#define __STATIC_FORCEINLINE static __forceinline
#endif
#ifndef __STATIC_INLINE
#define __STATIC_INLINE static __inline
#endif
#ifndef __ALIGNED
#define __ALIGNED(x) __declspec(align(x))
#endif


//ptorelli--start
#elif defined ( __APPLE_CC__ ) || defined ( __GNUC__ )
#include <stdint.h>
#define  __ALIGNED(x) __attribute__((aligned(x)))
#define __STATIC_FORCEINLINE static inline __attribute__((always_inline)) 
#define __STATIC_INLINE static inline
#ifndef   __RESTRICT
#define __RESTRICT                             __restrict
#endif
//ptorelli--end

from audiomark.

Kaipingli88 avatar Kaipingli88 commented on August 19, 2024

Yes, it builds fine with this change.

from audiomark.

petertorelli avatar petertorelli commented on August 19, 2024

Completely fixed as of bfe2a48.

Closing, but we can re-open if it happens again.

from audiomark.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.