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

Got error when make in sip directory #2

Open
p1680 opened this issue Aug 4, 2019 · 4 comments
Open

Got error when make in sip directory #2

p1680 opened this issue Aug 4, 2019 · 4 comments

Comments

@p1680
Copy link

p1680 commented Aug 4, 2019

Hi Sir,

When I run'make' in sip directory, I got the error message as below.

g++ -c -g -O2 -fstack-protector-strong -Wformat -Werror=format-security -Wdate-time -D_FORTIFY_SOURCE=2 -fPIC -Wall -W -DNDEBUG -I. -I/usr/include/python2.7 -o sippciecmodule.o sippciecmodule.cpp

./sippciecmodule.cpp:70:1: error: braces around scalar initializer for type `_sipCharInstanceDef*'
};

@cospan
Copy link
Contributor

cospan commented Aug 7, 2019

The moment I read this I thought that there might be a python version issue. You might need to regenerate the sip files. Here are instructions:

You will need to install 'python-sip-dev' here's how to do it in Ubuntu:

sudo apt install python-sip-dev

Generate the makefile

cd sip/
make

You should be able to run the 'make install' after this.

Let me know how it turns out.

Dave

@p1680
Copy link
Author

p1680 commented Aug 12, 2019

I still got error after your suggestion as below message.

(test) aaron@eda:~/wrk/python-pci-master/sip$ sudo apt install python-sip-dev
Reading package lists... Done
Building dependency tree
Reading state information... Done
python-sip-dev is already the newest version (4.19.7+dfsg-1).
0 upgraded, 0 newly installed, 0 to remove and 220 not upgraded.
(test) aaron@eda:~/wrk/python-pci-master/sip$ make
g++ -c -g -O2 -fstack-protector-strong -Wformat -Werror=format-security -Wdate-time -D_FORTIFY_SOURCE=2 -fPIC -Wall -W -DNDEBUG -I. -I/usr/include/python2.7 -o sippciecmodule.o sippciecmodule.cpp
./sippciecmodule.cpp:70:1: error: braces around scalar initializer for type `_sipCharInstanceDef*'
};
^
Makefile:17: recipe for target 'sippciecmodule.o' failed
make: *** [sippciecmodule.o] Error 1

@cospan
Copy link
Contributor

cospan commented Aug 13, 2019

Within the 'sip' directory would you run the script './configure.py' This should regenerate all the .h and .cpp files. Let me know if that doesn't work.

Next run 'make' and then 'make install'

Would you also let me know what OS version you are running by running the command 'uname -a'

@joy-chauhan
Copy link

Within the 'sip' directory would you run the script './configure.py' This should regenerate all the .h and .cpp files. Let me know if that doesn't work.

Next run 'make' and then 'make install'

Would you also let me know what OS version you are running by running the command 'uname -a'

same issue !!
Detail : g++ -c -g -O2 -fstack-protector-strong -Wformat -Werror=format-security -Wdate-time -D_FORTIFY_SOURCE=2 -fPIC -Wall -W -DNDEBUG -I. -I/usr/include/python2.7 -o sippciecmodule.o sippciecmodule.cpp
In file included from sippciecmodule.cpp:7:0:
sipAPIpcie.h:167:8: error: \u2018sipClassTypeDef\u2019 does not name a type
extern sipClassTypeDef sipTypeDef_pcie_PythonPCIE;

Also, ./configure.py is not working. it's show like : /usr/bin/sip -c . -I . -b pypcie.sbf python-pcie.sip

OS version : 4.15.0-54-generic #58~16.04.1-Ubuntu SMP Mon Jun 24 13:21:41 UTC 2019 x86_64 x86_64 x86_64

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants