Ansible playbook not working trying to run make & configure with complex switches

Solution is to change this:

shell: 'chdir={{ curl_dir }} "{{ item }}"'

to this:

shell: "{{ item }}"
args:
  chdir: "{{ curl_dir }}"

The documentation for the shell module now addresses this trickiness in the formatting. The complete working build task currently looks like this:

- name: Build CURL with openssl
  shell: "{{ item }}"
  args:
    chdir: "{{ curl_dir }}"
  with_items:
    - ./buildconf
    - ./configure --with-gssapi --with-libidn --with-libssh2 --prefix=/usr --without-nss
    - make
    - make install
    - ldconfig