The term agile evolved to encapsulated the principles behind software development practices such as extreme programming, scrum, DSDM and other iterative and incremental approaches. Lean has been around a lot longer, (possibly a great deal longer - Chinese Emperors) but has infrequently seemed to gather momentum in software development until recent years.
On the surface that there is a great deal of commonality between the two approaches. For example with Agile, teams focus on doing enough work to get the job done whilst leaving options open, to help managing the inevitable change with less pain and risk (eg. failing early). This agile practice could be viewed as minimising waste, a lean concept, but do most agile teams have the opportunity to understand that they are minimising waste and the implications of doing so?
Agile processes all seem to have a common plan-do-check-act core with there approach. This is interesting to me as that is exactly how I have started several personal Kanban boards. However, those personal Kanban boards just happened to fit that simple value stream and usually evolved in to a more continuous feedback system for work.
Also a scrum board and a Kanban board can visually look very similar, but have a different context and approach, usually have different values and different outcomes. I have seen (bad) scrum boards that look like a micro waterfall process to a prince2 project manager, with all the same problems. A good Kanban board has values derived from the wider organisation that subtly change how that board is used to bring about a very different outcome.
There are many shared or similar principles at play with both Lean and Agile, especially as we learn lessons from applying lean approaches to software development, perhaps the differences are most evident in the goals and the values driving the practices a lean/agile team adopts.
As the goals and values defined will vary depending on the organisation, the overarching principles of both lean and agile can be used as a common framework for guiding teams and organisations to become a leaner and more agile machine (within the limits of their capacity for organisational change).
Effecting organisational change with agile practices alone is a very difficult way to achieve a positive change, borrowing goals and values from Lean broadens the context of your practices so that the organisation moves closer to working as a whole and therefore sees the wider value of organisational change.
In summary, believing that Lean and Agile is the same when applied to software development seems to be a high level view and misses out on the deeper and richer aspects that lean system thinking helps promote.
Then you have the concepts behind a learning organisation that extends lean and agile even further.... but that's another discussion.