Arduino Nano R4 library

Hi all, I have just upgraded to a Nano R4 as they are just as capable as the original Nano (i.e. not an every). When I tried to compile (not upload) the code for a Pimeroni BMP280 the IDE gave an error with the Nano R4 selected but I switched back to a Nano and it worked fine. Any ideas?

This is where the zip is from: GitHub - orgua/iLib: Library for various I2C-Sensors with examples for Arduino

and this is the error:

In file included from C:\Users\ezzjt2\AppData\Local\Arduino15\packages\arduino\hardware\renesas_uno\1.5.1\cores\arduino/api/Interrupts.h:27:0,
from C:\Users\ezzjt2\AppData\Local\Arduino15\packages\arduino\hardware\renesas_uno\1.5.1\cores\arduino/api/ArduinoAPI.h:29,
from C:\Users\ezzjt2\AppData\Local\Arduino15\packages\arduino\hardware\renesas_uno\1.5.1\cores\arduino/Arduino.h:4,
from C:\Users\\AppData\Local\arduino\sketches\A14A06EDF009F3CB1717620A2CA88034\sketch\i2c_BMP280.ino.cpp:1:
C:\Users\\Documents\Arduino\libraries\I2C-Sensor-Lib_iLib\src/i2c.h: In constructor 'WirePlus::WirePlus()':
C:\Users\\Documents\Arduino\libraries\I2C-Sensor-Lib_iLib\src/i2c.h:70:12: error: 'PORTC' was not declared in this scope
bitSet(PORTC, 4); // deactivate internal pull-ups for twi
^
C:\Users\\AppData\Local\Arduino15\packages\arduino\hardware\renesas_uno\1.5.1\cores\arduino/api/Common.h:86:30: note: in definition of macro 'bitSet'
#define bitSet(value, bit) ((value) |= (1UL << (bit)))
^~~~~
C:\Users\\Documents\Arduino\libraries\I2C-Sensor-Lib_iLib\src/i2c.h:70:12: note: suggested alternative: 'R_RTC'
bitSet(PORTC, 4); // deactivate internal pull-ups for twi
^
C:\Users\AppData\Local\Arduino15\packages\arduino\hardware\renesas_uno\1.5.1\cores\arduino/api/Common.h:86:30: note: in definition of macro 'bitSet'
#define bitSet(value, bit) ((value) |= (1UL << (bit)))
^~~~~
In file included from C:\Users\\AppData\Local\Temp.arduinoIDE-unsaved2025913-23520-xlljg6.4e2s\i2c_BMP280\i2c_BMP280.ino:2:0:
C:\Users\\Documents\Arduino\libraries\I2C-Sensor-Lib_iLib\src/i2c.h:73:5: error: 'TWBR' was not declared in this scope
TWBR = ((F_CPU / 400000L) - 16) / 2; // see twi_init in Wire/utility/twi.c
^~~~

exit status 1

Compilation error: exit status 1

You have a library that is written for an ATmega board, such as an Uno R3 or a classic Nano.

It will not work with a board that uses another processor, such as any of the R4 boards.

The Nano R4 should have zero problems with a library actually targeting the common Arduino API (aka Arduino.h, Wire.h, SPI.h etc.), such as

Don't use a ""Arduino"" library that hardcode peripherals write for a ATMEGA328 on your Nano R4. It's actually a ATMEGA328 library in disguise with some elements of Arduino.h sprinkled in.

Be warned that Nano R4 is not an "upgraded Nano R3", it is a completely different board, with a different controller.
Many old codes, written to classic Nano, are not compatible with Nano R4.

I don't chase links, but it appears the library is not compatible with the board. I have been using the NANO R4 for a few weeks with no issues.
Start with these examples that are specifically for the NANO R4

Nice, thanks people, this helps a lot.