How do I program a non-Atmel chip with the Arduino IDE?
The question is actually very broad as there are many possible embedded processor to choose from.  Any answer would have to be presented using general terms.

As stated by @Majenko, your 1st step is to use a popular programming language that has been ported to many embedded processors (or the processor of interest).

The next step is not so clear.  When programming in the Arduino paradigm you have been using supporting C++ source code (which "Sketch" writers are calling "Libraries") that normally interact directly with the Arduino's hardware.

It is important to say this is an Arduino paradigm which has already been ported to a number of different processor.  Perhaps it is worth your time to discover which processors this paradigm has already extended to.

In the world outside of the Arduino paradigm, many embedded processor manufactures support sales of their hardware by supplying developers with tools.  Normally this includes a compiler and some software to abstract the hardware making it easier to use the more generic features.  If the processor comes on an "evaluation board" and the supporting software takes advantage of this the supporting software can be referred to a Board Support Package or BSP.

However, most will find the difference between Arduino Libraries and BSPs as vast.  Why?  Because most will write Arduino Libraries to mimic highly abstracted programming language features but in a very specific / inflexible way.  For example, a Sketch writer only has about a dozen ways to print something out.  Where as in real C, the print statement is very complex and flexible. Outside the Arduino paradigm (where the vast majority of embedded processors are used), the BSP approach is preferred as it exposes all the benefits the processor's hardware has to offer.

Where does this leave you?

The easiest approach is to find an Arduino platform which meets your needs.  Where someone has already done the work of porting all, most or some of the Arduino Libraries.

The next easiest approach would be to learn C++ and port the Arduino Library (which are really C++ classes) you are using in your program for the platform you are targeting.  Note that, in this case, it is suggested that creating an ordinary C / C++ program (abandoning the Arduino Sketch / Library paradigm) and using the supplied BSP (or other supporting software) would be easier than porting the entire Arduino Paradigm to the new platform.

The hardest approach (but the community would likely appreciate your efforts) is to port the entire Arduino paradigm to the new platform.