WelcomeWelcome | FAQFAQ | DownloadsDownloads | WikiWiki

Author Topic: RPi.GPIO under Python 3.5  (Read 2091 times)

Offline tohox

  • Newbie
  • *
  • Posts: 25
RPi.GPIO under Python 3.5
« on: August 04, 2016, 10:55:29 AM »
Hi,

The python-RPi.GPIO.tcz package installed through TCE didn't seem to work with Python 3.5 so I decided to install the package through PIP instead.

The PIP install always fails with gcc complaining that:
Code: [Select]
gcc -pthread -Wno-unused-result -Wsign-compare -DNDEBUG -g -fwrapv -O3 -Wall -Wstrict-prototypes -O3 -pipe -march=armv6zk -mtune=arm1176jzf-s -mfpu=vfp -fPIC -I/usr/local/include/python3.5m -c source/py_gpio.c -o build/temp.linux-armv7l-3.5/source/py_gpio.o
    gcc: error trying to exec 'as': execvp: No such file or directory
    In file included from /tmp/tcloop/gcc/usr/lib/gcc/armv7l-unknown-linux-gnueabihf/6.1.0/include-fixed/limits.h:168:0,
                     from /tmp/tcloop/gcc/usr/lib/gcc/armv7l-unknown-linux-gnueabihf/6.1.0/include-fixed/syslimits.h:7,
                     from /tmp/tcloop/gcc/usr/lib/gcc/armv7l-unknown-linux-gnueabihf/6.1.0/include-fixed/limits.h:34,
                     from /usr/local/include/python3.5m/Python.h:11,
                     from source/py_gpio.c:23:
    /usr/lib/gcc/armv7l-unknown-linux-gnueabihf/6.1.0/include-fixed/limits.h:168:61: fatal error: limits.h: No such file or directory
     #include_next <limits.h>  /* recurse down to the real one */
                                                                 ^
    compilation terminated.

I assume I'm missing something called AS but searching for a combination of GCC and AS on Google is like searching for a single Cheerios in a box full of Froot Loops...

Any help appreciated!

Offline bmarkus

  • Administrator
  • Hero Member
  • *****
  • Posts: 7183
    • My Community Forum
Re: RPi.GPIO under Python 3.5
« Reply #1 on: August 04, 2016, 12:27:35 PM »
Most probably you miss linux api headers file. Install it from the repo.
Béla
Ham Radio callsign: HA5DI

"Amateur Radio: The First Technology-Based Social Network."

Offline Rich

  • Administrator
  • Hero Member
  • *****
  • Posts: 11210
Re: RPi.GPIO under Python 3.5
« Reply #2 on: August 04, 2016, 01:53:48 PM »
Hi tohox
Quote
gcc: error trying to exec 'as': execvp: No such file or directory
Check if  binutils.tcz  is installed.

Offline bmarkus

  • Administrator
  • Hero Member
  • *****
  • Posts: 7183
    • My Community Forum
Re: RPi.GPIO under Python 3.5
« Reply #3 on: August 04, 2016, 11:38:00 PM »
Did you install gcc.tcz only or the development package, compile-essentials.tcz (piCore-7 or earlier) or compiletc.tcz (piCore-8)?
Béla
Ham Radio callsign: HA5DI

"Amateur Radio: The First Technology-Based Social Network."

Offline tohox

  • Newbie
  • *
  • Posts: 25
Re: RPi.GPIO under Python 3.5
« Reply #4 on: August 05, 2016, 06:06:44 AM »
Running 8 beta 3 and had only installed GCC... I installed compiletc.tcz and was then able to add RPi.GPIO without any issues.

Thanks a lot!